<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: ResamplePolyPhase functions in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901274#M12792</link>
    <description>&lt;P&gt;Hi, Jimmy,&lt;/P&gt;
&lt;P&gt;The definition of the resampling factorthrough the number of input samples and the number of output samples works if only you take the whole input signal and resample it at once. But for an input stream the number of input samples is unknown and resampling can be done only via the ratio of input and output frequencies. &lt;/P&gt;
&lt;P&gt;So inRate/outRate is not the ratio of input and output samples (eg for &lt;FONT face="Courier New"&gt;inRate=3&lt;/FONT&gt;, &lt;FONT face="Courier New"&gt;outRate=1&lt;/FONT&gt;, an input sequence of 2 samples will be converted to the output sequence of length 1). The real number of output samples is the rounded number &lt;FONT face="Courier New"&gt;inLength*factor&lt;/FONT&gt;. To avoid details of rounding (itcould be flooring, to nearest integer or smth else) the calculated number of output sample is returned. &lt;/P&gt;
&lt;P&gt;If you resample the long sequence by portions that are not multiple to &lt;FONT face="Courier New"&gt;inRate&lt;/FONT&gt; the "right" number of output samples will be fractional. To enable the correct continuation of resampling the integr part &lt;FONT face="Courier New"&gt;&lt;FONT face="Times New Roman"&gt;(&lt;/FONT&gt;*pOutlen&lt;/FONT&gt;) and the fractional part (&lt;FONT face="Courier New"&gt;*pTime&lt;/FONT&gt;) are returned.&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Alexander&lt;/P&gt;</description>
    <pubDate>Thu, 23 Nov 2006 18:10:46 GMT</pubDate>
    <dc:creator>Intel_C_Intel</dc:creator>
    <dc:date>2006-11-23T18:10:46Z</dc:date>
    <item>
      <title>ResamplePolyPhase functions</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901272#M12790</link>
      <description>&lt;P&gt;In ippsResamplePolyphase() function, there is a parameter called "factor" which is defined as "The ratio of output and input frequencies". I wonder if it is actually the ratio of output and input samples? (ref to page 8-212 in ippsman). I've gone through the sample code and it seems like number of samples. Since we are doing 'resample', number of samplesis much easy to specify.&lt;/P&gt;
&lt;P&gt;On page 8-203, inRate and outRate parameters are defined as the input/output rate for fixed factor resampling. And it says "The function... with the factor equal to inrate/outRate without calculating the filter coefficients". It seems to me this "factor" is defined differently although on 8-213 I saw 'this ratio is defined during creation of the resampling structure".&lt;/P&gt;
&lt;P&gt;I feel these two 'factor" are the same, so may be the definition on 8-203 is not right.&lt;/P&gt;
&lt;P&gt;Anyone has any idea regarding this set of functions?&lt;/P&gt;
&lt;P&gt;Thank you in advance!&lt;/P&gt;
&lt;P&gt;Jimmy&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 08 Nov 2006 05:40:59 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901272#M12790</guid>
      <dc:creator>jimmyliu51</dc:creator>
      <dc:date>2006-11-08T05:40:59Z</dc:date>
    </item>
    <item>
      <title>Re: ResamplePolyPhase functions</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901273#M12791</link>
      <description>&lt;P&gt;ok. Looks like only one definition is correct, the factor=output rate/input rate.&lt;/P&gt;
&lt;P&gt;After trying to use IPP's sample C++ code, I think I got some simple idea. Meanwhile, there area few questions I like to ask. And hope someone can help:&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;
&lt;P&gt;If I use 2000 data samples as input and down-sample to say 1400, I will get the correct result. However, if I use 3000 or more samples, the down sampled result is not correct.&lt;/P&gt;
&lt;P&gt;For example,I have a set of raw data arranged as&lt;/P&gt;
&lt;P&gt;100 zeros, 100 1s, ..., 100 29s. I don't add any noise data. If I downsample it by a factor 7/10, I should get 70 for each of0,1,...29 in my output data. However, the sample C++ code only get 70 0s,...70 23s, after that, it gives a series of 23,24,25, 23,24, etc, quite like a random sequence.&lt;/P&gt;
&lt;P&gt;I wonder if anyone has tested ippsResample() function with such data.&lt;/P&gt;
&lt;P&gt;I used window=1024, then find history=1025, length=2048. Buffer=4000(buffer should not affect result).&lt;/P&gt;
&lt;P&gt;In fact, this problem shows up for both fixed resample function and non-fixed version.&lt;/P&gt;
&lt;P&gt;Do I miss something?&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 14 Nov 2006 23:19:52 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901273#M12791</guid>
      <dc:creator>jimmyliu5</dc:creator>
      <dc:date>2006-11-14T23:19:52Z</dc:date>
    </item>
    <item>
      <title>Re: ResamplePolyPhase functions</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901274#M12792</link>
      <description>&lt;P&gt;Hi, Jimmy,&lt;/P&gt;
&lt;P&gt;The definition of the resampling factorthrough the number of input samples and the number of output samples works if only you take the whole input signal and resample it at once. But for an input stream the number of input samples is unknown and resampling can be done only via the ratio of input and output frequencies. &lt;/P&gt;
&lt;P&gt;So inRate/outRate is not the ratio of input and output samples (eg for &lt;FONT face="Courier New"&gt;inRate=3&lt;/FONT&gt;, &lt;FONT face="Courier New"&gt;outRate=1&lt;/FONT&gt;, an input sequence of 2 samples will be converted to the output sequence of length 1). The real number of output samples is the rounded number &lt;FONT face="Courier New"&gt;inLength*factor&lt;/FONT&gt;. To avoid details of rounding (itcould be flooring, to nearest integer or smth else) the calculated number of output sample is returned. &lt;/P&gt;
&lt;P&gt;If you resample the long sequence by portions that are not multiple to &lt;FONT face="Courier New"&gt;inRate&lt;/FONT&gt; the "right" number of output samples will be fractional. To enable the correct continuation of resampling the integr part &lt;FONT face="Courier New"&gt;&lt;FONT face="Times New Roman"&gt;(&lt;/FONT&gt;*pOutlen&lt;/FONT&gt;) and the fractional part (&lt;FONT face="Courier New"&gt;*pTime&lt;/FONT&gt;) are returned.&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Alexander&lt;/P&gt;</description>
      <pubDate>Thu, 23 Nov 2006 18:10:46 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901274#M12792</guid>
      <dc:creator>Intel_C_Intel</dc:creator>
      <dc:date>2006-11-23T18:10:46Z</dc:date>
    </item>
    <item>
      <title>Re: ResamplePolyPhase functions</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901275#M12793</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;The reason of "random" results is following:&lt;/P&gt;
&lt;P&gt;when you apply a filter to a sample you need &lt;FONT face="Courier New"&gt;history&lt;/FONT&gt; samples before and &lt;FONT face="Courier New"&gt;history&lt;/FONT&gt; samples after. So you have in the example &lt;FONT face="Courier New"&gt;history&lt;/FONT&gt; zeroes before for the first sample and &lt;FONT face="Courier New"&gt;history&lt;/FONT&gt; zeroes after the last sample. &lt;FONT face="Courier New"&gt;history=windows/2*10/7=732&lt;/FONT&gt;&lt;FONT face="Times New Roman"&gt; here.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;So, for&lt;FONT face="Courier New"&gt;history*factor-1=511&lt;/FONT&gt; first and &lt;FONT face="Courier New"&gt;511&lt;/FONT&gt; last samples outside zeroes participate in output sample calculation&lt;/P&gt;
&lt;P&gt;Thanks,&lt;/P&gt;
&lt;P&gt;Alexander&lt;/P&gt;</description>
      <pubDate>Thu, 23 Nov 2006 18:55:25 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/ResamplePolyPhase-functions/m-p/901275#M12793</guid>
      <dc:creator>Intel_C_Intel</dc:creator>
      <dc:date>2006-11-23T18:55:25Z</dc:date>
    </item>
  </channel>
</rss>

