[Speex-dev] Delays estimation in Speex algorithms

John Ridges jridges at masque.com
Tue Jun 30 13:57:37 PDT 2009


Understood. Then I don't have to worry about you changing 
SPEEX_GET_LOOKAHEAD. BTW thanks for the delay info about the 
preprocessor, I wasn't aware of that.

John Ridges


Jean-Marc Valin wrote:
> Quoting John Ridges <jridges at masque.com>:
>
>   
>> Speex tells me that the decoder is always 5 ms, but it says that the
>> encoder is 5 ms for NB, 8.9375 ms for WB, and 10.90625 ms for UWB. Is
>> there an extra frame of delay in the encoder that isn't otherwise
>> accounted for?
>>     
>
> Oh, delay = frame_size + lookahead
>
> If you have a frame size of 20 ms, then there's no choice but to have 20 ms
> delay (you can't transmit the first sample until you've received the last).
> However, if you have many algorithms that work on the same frame size, you only
> pay for that delay once.
>
>     Jean-Marc
>
>   
>> John Ridges
>>
>> Jean-Marc Valin wrote:
>>     
>>> Quoting John Ridges <jridges at masque.com>:
>>>
>>>       
>>>> I also need to know the precise delays from Speex but I used the
>>>> SPEEX_GET_LOOKAHEAD control requests to determine them (plus the
>>>> "speex_resampler_get_output_latency" function from the resampler). The
>>>> returned values from the Speex lookahead request don't seem to match
>>>> with the values you gave Alexander. Am I doing this wrong? Thanks,
>>>>
>>>>         
>>> What's the difference between what I wrote and what you get from Speex?
>>>
>>>    Jean-Marc
>>>
>>>
>>>       
>>>> John Ridges
>>>>
>>>>
>>>> speex-dev-request at xiph.org wrote:
>>>>
>>>>         
>>>>> Alexander Chemeris a ?crit :
>>>>>
>>>>>
>>>>>           
>>>>>> I want to do a careful measure of mic-to-net and net-to-spkr delays
>>>>>> in sip media engine and to make it really precise I need to know
>>>>>> delays, introduced by Speex algorithms. In particular, I'm interested
>>>>>> in delays of:
>>>>>> 1) encoder in NB, WB and UWB modes,
>>>>>>
>>>>>>
>>>>>>             
>>>>> NB: 25 ms, WB: ~28 ms, UWB: ~30 ms
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>>> 2) decoder (I guess it should be 0?)
>>>>>>
>>>>>>
>>>>>>             
>>>>> 5 ms
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>>> 3) resampler. I think it varies depending on input rate to output rate
>>>>>> ratio. Any generic formula or at least values for specific ratios
>>>>>>
>>>>>>             
>>>> available?
>>>>
>>>>         
>>>>> The higher the quality, the higher the delay
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>>> 4) AEC
>>>>>>
>>>>>>
>>>>>>             
>>>>> 0 ms
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>>> 5) preprocessor
>>>>>>
>>>>>>
>>>>>>             
>>>>> 1 frame extra delay (i.e. you get back the last frame you sent the last
>>>>> time)
>>>>>
>>>>> 	Jean-Marc
>>>>>
>>>>>
>>>>> ------------------------------
>>>>>
>>>>>
>>>>>
>>>>>
>>>>>           
>>>>         
>>>
>>>
>>>
>>>       
>>
>>     
>
>
>
>
>   



More information about the Speex-dev mailing list