<?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 Hi Bob, in Intel® Integrated Performance Primitives</title>
    <link>https://community.intel.com/t5/Intel-Integrated-Performance/Audio-Quality-Issues-using-ResamplePolyphaseFixed/m-p/957562#M19263</link>
    <description>&lt;P&gt;Hi Bob,&lt;/P&gt;
&lt;P&gt;you are trying to use functions from Speach Recognition Domain - so their quality is enough for their field of application - guess it is understandable that there always is a tradeoff between quality and performance. For better quality you can try this functionality with "Filter" suffix and set your own filter with better characteristics or use more complex algorithms.&lt;/P&gt;
&lt;P&gt;regards, Igor&lt;/P&gt;</description>
    <pubDate>Wed, 07 Aug 2013 14:27:24 GMT</pubDate>
    <dc:creator>Igor_A_Intel</dc:creator>
    <dc:date>2013-08-07T14:27:24Z</dc:date>
    <item>
      <title>Audio Quality Issues using ResamplePolyphaseFixed</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Audio-Quality-Issues-using-ResamplePolyphaseFixed/m-p/957561#M19262</link>
      <description>&lt;P&gt;I am trying to replace a sample rate conversion implementation limited to converting between 8000Hz and 16000Hz 16 bit linear PCM with some thing more flexible. &amp;nbsp;Using IPP 7.1, the ResamplePolyphaseFixed API's and the example code (&lt;A href="http://software.intel.com/sites/products/documentation/doclib/ipp_sa/71/ipp_manual/IPPS/ipps_ch6/functn_ResamplePolyphase.htm"&gt;http://software.intel.com/sites/products/documentation/doclib/ipp_sa/71/ipp_manual/IPPS/ipps_ch6/functn_ResamplePolyphase.htm&lt;/A&gt;) I have something which works but the audio quality is not great. &amp;nbsp;Using DTMF tones to test basic quality, the input is 8000Hz / 16bit linear PCM being processed in 10msec chunks. &amp;nbsp;Tested output is 11025Hz and 16000Hz / 16bit linear PCM with fair quality.&lt;/P&gt;
&lt;P&gt;&lt;A href="&amp;lt;iframe src=&amp;quot;http://www.slideshare.net/slideshow/embed_code/24532139&amp;quot; width=&amp;quot;476&amp;quot; height=&amp;quot;400&amp;quot; frameborder=&amp;quot;0&amp;quot; marginwidth=&amp;quot;0&amp;quot; marginheight=&amp;quot;0&amp;quot; scrolling=&amp;quot;no&amp;quot;&amp;gt;&amp;lt;/iframe&amp;gt;"&gt;&amp;lt;iframe src="http://www.slideshare.net/slideshow/embed_code/24532139" width="476" height="400" frameborder="0" marginwidth="0" marginheight="0" scrolling="no"&amp;gt;&amp;lt;/iframe&amp;gt;&lt;/A&gt;&lt;/P&gt;
&lt;P&gt;I have tried tweaking the hardcoded parameters used in the example code but this has not yielded any noticable improvement. &amp;nbsp;My (abreviated) version of the example code . . .&amp;nbsp;&lt;/P&gt;
&lt;P&gt;static const IppHintAlgorithm g_IppHintAlgorithm = ippAlgHintAccurate;&lt;/P&gt;
&lt;P&gt;static void Create(int a_iSampleRateInp, int a_iSampleRateOut, Context* a_pResamplePCMContext)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp; int l_iSize = 0;&lt;BR /&gt;&amp;nbsp; int l_iBufferLength = 0;&lt;BR /&gt;&amp;nbsp; Context* p = a_pResamplePCMContext; //For code brevity&lt;BR /&gt;&amp;nbsp; int l_iLength = 0;&lt;BR /&gt;&amp;nbsp; float l_fWindow = 0.0;&lt;BR /&gt;&amp;nbsp; double l_dFactor = 0.0;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; p-&amp;gt;m_pState = NULL;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iBufferLength = 0;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_pBuffer = NULL;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iFilterLength = 0;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iNumberOfFilters = 0;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_dTime = 0.0;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iLastRead = 0;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iSampleRateInp = 0;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iSampleRateOut = 0;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; p-&amp;gt;m_iBufferLengthBase = 4096; //From intel example code&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iHistory = 128; //From intel example code&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_fFilterRollOff = 0.95f; //From intel example code&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_fKaiserWindowAlpha = 9.0f; //From intel example code&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_fNormFactor = 0.98f; //From intel example code&lt;/P&gt;
&lt;P&gt;&amp;nbsp; ippsResamplePolyphaseFixedGetSize_16s(a_iSampleRateInp, a_iSampleRateOut, 2*(p-&amp;gt;m_iHistory-1), &amp;amp;l_iSize, &amp;amp;p-&amp;gt;m_iFilterLength, &amp;amp;p-&amp;gt;m_iNumberOfFilters, g_IppHintAlgorithm);&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_pState = (IppsResamlingPolyphaseFixed_16s*)ippsMalloc_8u(l_iSize);&lt;BR /&gt;&amp;nbsp; if (NULL == a_pResamplePCMContext-&amp;gt;m_pState) return;&lt;BR /&gt;&amp;nbsp; ippsResamplePolyphaseFixedInit_16s(a_iSampleRateInp, a_iSampleRateOut, 2*(p-&amp;gt;m_iHistory-1), p-&amp;gt;m_fFilterRollOff, p-&amp;gt;m_fKaiserWindowAlpha, &amp;nbsp; p-&amp;gt;m_pState, g_IppHintAlgorithm);&lt;BR /&gt;&amp;nbsp; l_iBufferLength = (int)((p-&amp;gt;m_iBufferLengthBase-p-&amp;gt;m_iHistory)*a_iSampleRateOut/(float)a_iSampleRateInp+2);&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_pBuffer = ippsMalloc_16s(l_iBufferLength);&lt;BR /&gt;&amp;nbsp; if (NULL == p-&amp;gt;m_pBuffer) return;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iBufferLength = l_iBufferLength;&lt;BR /&gt;&amp;nbsp; //Initialy, the residual length is the history length and we must 0 this portion out.&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_dTime = (double)p-&amp;gt;m_iHistory;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iLastRead = p-&amp;gt;m_iHistory;&lt;BR /&gt;&amp;nbsp; ippsZero_16s(p-&amp;gt;m_pBuffer, p-&amp;gt;m_iBufferLength);&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iSampleRateInp = a_iSampleRateInp;&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iSampleRateOut = a_iSampleRateOut;&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;static void Resample(Context_16s* a_pResamplePCMContext, short* a_p16BitInp, short* a_p16BitOut, unsigned int a_iLengthInp, unsigned int* a_piLengthOut)&lt;BR /&gt;{&lt;BR /&gt;&amp;nbsp; IppStatus l_IppStatus = ippStsNoErr;&lt;BR /&gt;&amp;nbsp; Context* p = a_pResamplePCMContext; //For code brevity&lt;BR /&gt;&amp;nbsp; double l_dTime;&lt;/P&gt;
&lt;P&gt;&amp;nbsp; l_dTime = p-&amp;gt;m_dTime;&lt;BR /&gt;&amp;nbsp; //Copy the new input samples to proper position in residual buffer&lt;BR /&gt;&amp;nbsp; ippsCopy_16s(a_p16BitInp, p-&amp;gt;m_pBuffer+p-&amp;gt;m_iLastRead, a_iLengthInp);&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iLastRead += a_iLengthInp;&lt;BR /&gt;&amp;nbsp; l_IppStatus = ippsResamplePolyphaseFixed_16s(p-&amp;gt;m_pBuffer, a_iLengthInp, a_p16BitOut, p-&amp;gt;m_fNormFactor, &amp;amp;p-&amp;gt;m_dTime, (int*)a_piLengthOut, p-&amp;gt;m_pState);&lt;BR /&gt;&amp;nbsp; if (ippStsNoErr != l_IppStatus)&lt;BR /&gt;&amp;nbsp; {&lt;BR /&gt;&amp;nbsp; &amp;nbsp; return;&lt;BR /&gt;&amp;nbsp; }&lt;BR /&gt;&amp;nbsp; //Copy any residual input samples to head of residual / history buffer&lt;BR /&gt;&amp;nbsp; ippsMove_16s(a_p16BitInp+(int)p-&amp;gt;m_dTime-p-&amp;gt;m_iHistory, p-&amp;gt;m_pBuffer, p-&amp;gt;m_iLastRead+p-&amp;gt;m_iHistory-(int)p-&amp;gt;m_dTime);&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_iLastRead -= ((int)p-&amp;gt;m_dTime-p-&amp;gt;m_iHistory);&lt;BR /&gt;&amp;nbsp; p-&amp;gt;m_dTime -= (p-&amp;gt;m_dTime-p-&amp;gt;m_iHistory);&lt;BR /&gt;}&lt;/P&gt;
&lt;P&gt;&lt;/P&gt;</description>
      <pubDate>Tue, 23 Jul 2013 12:02:37 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Audio-Quality-Issues-using-ResamplePolyphaseFixed/m-p/957561#M19262</guid>
      <dc:creator>Bob_Kirnum</dc:creator>
      <dc:date>2013-07-23T12:02:37Z</dc:date>
    </item>
    <item>
      <title>Hi Bob,</title>
      <link>https://community.intel.com/t5/Intel-Integrated-Performance/Audio-Quality-Issues-using-ResamplePolyphaseFixed/m-p/957562#M19263</link>
      <description>&lt;P&gt;Hi Bob,&lt;/P&gt;
&lt;P&gt;you are trying to use functions from Speach Recognition Domain - so their quality is enough for their field of application - guess it is understandable that there always is a tradeoff between quality and performance. For better quality you can try this functionality with "Filter" suffix and set your own filter with better characteristics or use more complex algorithms.&lt;/P&gt;
&lt;P&gt;regards, Igor&lt;/P&gt;</description>
      <pubDate>Wed, 07 Aug 2013 14:27:24 GMT</pubDate>
      <guid>https://community.intel.com/t5/Intel-Integrated-Performance/Audio-Quality-Issues-using-ResamplePolyphaseFixed/m-p/957562#M19263</guid>
      <dc:creator>Igor_A_Intel</dc:creator>
      <dc:date>2013-08-07T14:27:24Z</dc:date>
    </item>
  </channel>
</rss>

