[Numpy-discussion] Help Convolution with binaural filters(HRTFs)

David Cournapeau cournape at gmail.com
Thu May 27 07:23:41 EDT 2010


On Thu, May 27, 2010 at 8:00 PM, arthur de conihout
<arthurdeconihout at gmail.com> wrote:

> #i dont really understand the %dh and the s/2.0**15 but it might be my
> problem
>  original = [s / 2.0**15 for s in original]

This is done because wav file are (usually, not always) in fixed
point, with values in the unsigned  16 bits int range (~ [-32768,
32768]), but when you want to do processing in floating point (as does
numpy), you want the values normalized (in the [-1, 1] range). 2 * 15
gives you the normalization factor. But audiolab does this for you
automatically,

David



More information about the NumPy-Discussion mailing list