Re: dynamic range and sample bit depth (Kent Walker )


Subject: Re: dynamic range and sample bit depth
From:    Kent Walker  <kent.walker@xxxxxxxx>
Date:    Sat, 6 Dec 2014 10:28:16 +0000
List-Archive:<http://lists.mcgill.ca/scripts/wa.exe?LIST=AUDITORY>

--_000_0DB7E7B7C2FE764C8FAA0C7B78EF64A20C0ECA86EXMBX20103campu_ Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable I haven't seen this mentioned yet on this thread. Please forgive me if this= is obvious. Professional digital audio workstations, such as ProTools, do not have the = problem of "digital attenuation" that is being described. See, for example, the following white paper from the ProTools folks. Their 48-bit digital mixer i= s capable of attenuating a signal 90 dB while maintaining 24 bit audio qual= ity (and its full dynamic range) by using bit shifting. See: http://<http://akarchive.digidesign.com/support/docs/WhitePaper_48BitMixer.= pdf>akarchive.digidesign.com<http://akarchive.digidesign.com/support/docs/W= hitePaper_48BitMixer.pdf>/support/docs/<http://akarchive.digidesign.com/sup= port/docs/WhitePaper_48BitMixer.pdf>WhitePaper<http://akarchive.digidesign.= com/support/docs/WhitePaper_48BitMixer.pdf>_48BitMixer.pdf<http://akarchive= .digidesign.com/support/docs/WhitePaper_48BitMixer.pdf> A professional DAW for processing & playback (as opposed to Matlab) might b= e a convenient way to produce the highest quality stimuli for some experime= nts. 24bit 96kHz playback is commonly available in many DAWs, which some DA= C designers (such as Dan Lavry) consider to be the highest quality standard= ized digital audio format available. -Kent On Dec 6, 2014 12:13 AM, Eric Thompson <et_27@xxxxxxxx> wrote: I can add some insight into the problem with audible signals from Matlab wh= en the signals should not be audible. I discovered this as well, through so= me admittedly sloppy coding on my part. I even went through the exercise of= reporting a bug to the Mathworks, and after a lot of back and forth, and a= lot of testing, we determined that it was a "feature" not a "bug" in Matla= b. What I discovered was that very low level signals (i.e. levels << -100 d= B FS) were still audible to my ears using HD280pro headphones when played w= ith audioplayer at 16 bit depth, as Dan described, but the same signals wer= e not audible when played with wavplay (always 16-bit) or with audioplayer = at 24-bit. I finally figured out after looking at the signals output from t= he sound card on an oscilloscope that audioplayer uses mid-riser quantizati= on and wavplay uses mid-tread quantization (see http://en.wikipedia.org/wik= i/Quantization_(signal_processing)#Mid-riser_and_mid-tread_uniform_quantize= rs). This means that any signal that oscillates between very small positive= and negative values will get rounded up by audioplayer to oscillate betwee= n the quantization levels around 0, whereas wavplay will output 0. Ditherin= g should help avoid this problem, albeit by adding an audible noise floor (= at least audible with audioplayer). Also, Dan's solution of using 24-bit ou= tput also will work around this feature because the acoustic/electric noise= floor should be high enough with any system to mask this small signal, as = several others have already pointed out. -Eric On Friday, December 5, 2014 12:13 AM, Dan Goodman <d.goodman@xxxxxxxx= > wrote: Thanks to everyone who replied on and off list to my questions! So, several people seemed to agree that using dither is essential. What worries me about this is that if you do your sound presentations using Matlab on synthetic signals (generated using Matlab code rather than recorded), as far as I can tell it won't do this dithering, and so the dynamic range will be much worse than people might be expecting. I actually first came across this problem when helping to debug someone's threshold finding code that was failing for people with very good hearing. It turned out that this was because tones presented at low levels (substantially less than 0 dB SPL) were still audible. The reason in this case is that they were using 16 bit audio and switching to 24 bit solved the problem. (I guess Matlab was rounding up when converting from floats to integers, so no matter how low the level of the signal you were still getting some 1s in there and not just 0s.) However, my worry is that if your reference level was set higher than this (because you were testing normal and hearing impaired people with the same equipment) then even 24 bit might not be enough (without dithering). --------snip--------- Dan --_000_0DB7E7B7C2FE764C8FAA0C7B78EF64A20C0ECA86EXMBX20103campu_ Content-Type: text/html; charset="us-ascii" Content-Transfer-Encoding: quoted-printable <html> <head> <meta http-equiv=3D"Content-Type" content=3D"text/html; charset=3Dus-ascii"= > </head> <body> <p dir=3D"ltr">I haven't seen this mentioned yet on this thread. Please for= give me if this is obvious. </p> <p dir=3D"ltr">Professional digital audio workstations, such as ProTools, d= o not have the problem<br> of &quot;digital attenuation&quot; that is being described. See, for exampl= e, the<br> following white paper from the ProTools folks. Their 48-bit digital mixer i= s capable of attenuating a signal 90 dB while maintaining 24 bit audio qual= ity (and its full dynamic range) by using bit shifting. See:</p> <p dir=3D"ltr"><a href=3D"http://akarchive.digidesign.com/support/docs/Whit= ePaper_48BitMixer.pdf">http://</a><a href=3D"http://akarchive.digidesign.co= m/support/docs/WhitePaper_48BitMixer.pdf">akarchive.digidesign.com</a><a hr= ef=3D"http://akarchive.digidesign.com/support/docs/WhitePaper_48BitMixer.pd= f">/support/docs/</a><a href=3D"http://akarchive.digidesign.com/support/doc= s/WhitePaper_48BitMixer.pdf">WhitePaper</a><a href=3D"http://akarchive.digi= design.com/support/docs/WhitePaper_48BitMixer.pdf">_48BitMixer.pdf</a></p> <p dir=3D"ltr">A professional DAW for processing &amp; playback (as opposed= to Matlab) might be a convenient way to produce the highest quality stimul= i for some experiments. 24bit 96kHz playback is commonly available in many = DAWs, which some DAC designers (such as Dan Lavry) consider to be the highest quality standardized digital audio f= ormat available.</p> <p dir=3D"ltr">-Kent</p> <div class=3D"quote">On Dec 6, 2014 12:13 AM, Eric Thompson &lt;et_27@xxxxxxxx= .COM&gt; wrote:<br type=3D"attribution"> </div> <div> <div style=3D"color:#000; background-color:#fff; font-family:HelveticaNeue,= Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size:13px"> <div id=3D"yui_3_16_0_1_1417808388798_21901" dir=3D"ltr"><span id=3D"yui_3_= 16_0_1_1417808388798_21900">I can add some insight into the problem with au= dible signals from Matlab when the signals should not be audible. I discove= red this as well, through some admittedly sloppy coding on my part. I even went through the exercise of reporting a = bug to the Mathworks, and after a lot of back and forth, and a lot of testi= ng, we determined that it was a &quot;feature&quot; not a &quot;bug&quot; i= n Matlab. What I discovered was that very low level signals (i.e.&nbsp;levels &lt;&lt; -100 dB FS) were still audible to my ea= rs using HD280pro headphones&nbsp;when played with audioplayer at 16 bit de= pth, as Dan described, but the same signals were not audible when played wi= th wavplay (always 16-bit) or with audioplayer at 24-bit. I finally figured out after looking at the signals output from the= sound card&nbsp;on an oscilloscope that audioplayer uses mid-riser quantiz= ation and wavplay uses mid-tread quantization (see <a id=3D"yui_3_16_0_1_1417808388798_31530" href=3D"http://en.wikipedia.org/= wiki/Quantization_(signal_processing)#Mid-riser_and_mid-tread_uniform_quant= izers"> http://en.wikipedia.org/wiki/Quantization_(signal_processing)#Mid-riser_and= _mid-tread_uniform_quantizers</a>). This means that any signal that oscilla= tes between very small positive and negative values will get rounded up by = audioplayer to oscillate between the quantization levels around 0, whereas wavplay will output 0. Dithering= should help avoid this problem, albeit by adding an audible noise floor (a= t least audible with audioplayer). Also, Dan's solution of using 24-bit out= put also will work around this feature because the acoustic/electric noise floor&nbsp;should be&nbsp;high enough = with any system&nbsp;to mask this small signal, as several others have alre= ady pointed out.</span></div> <div class=3D"qtdSeparateBR" id=3D"yui_3_16_0_1_1417808388798_38875" dir=3D= "ltr">-Eric<br> <br> </div> <div class=3D"yahoo_quoted" id=3D"yui_3_16_0_1_1417808388798_38869" style= =3D"display:block"> <div id=3D"yui_3_16_0_1_1417808388798_38868" style=3D"font-family:Helvetica= Neue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size:13p= x"> <div id=3D"yui_3_16_0_1_1417808388798_38867" style=3D"font-family:Helvetica= Neue,Helvetica Neue,Helvetica,Arial,Lucida Grande,sans-serif; font-size:16p= x"> <div id=3D"yui_3_16_0_1_1417808388798_38874" dir=3D"ltr"><font id=3D"yui_3_= 16_0_1_1417808388798_38873" face=3D"Arial" size=3D"2">On Friday, December 5= , 2014 12:13 AM, Dan Goodman &lt;d.goodman@xxxxxxxx&gt; wrote:<br> </font></div> <br> <br> <div class=3D"y_msg_container" id=3D"yui_3_16_0_1_1417808388798_38872">Than= ks to everyone who replied on and off list to my questions!<br> <br> So, several people seemed to agree that using dither is essential. What <br= > worries me about this is that if you do your sound presentations using <br> Matlab on synthetic signals (generated using Matlab code rather than <br> recorded), as far as I can tell it won't do this dithering, and so the <br> dynamic range will be much worse than people might be expecting. I <br> actually first came across this problem when helping to debug someone's <br= > threshold finding code that was failing for people with very good <br> hearing. It turned out that this was because tones presented at low <br> levels (substantially less than 0 dB SPL) were still audible. The reason <b= r> in this case is that they were using 16 bit audio and switching to 24 <br> bit solved the problem. (I guess Matlab was rounding up when converting <br= > from floats to integers, so no matter how low the level of the signal <br> you were still getting some 1s in there and not just 0s.) However, my <br> worry is that if your reference level was set higher than this (because <br= > you were testing normal and hearing impaired people with the same <br> equipment) then even 24 bit might not be enough (without dithering).<br> <br> --------snip---------</div> <div class=3D"y_msg_container" id=3D"yui_3_16_0_1_1417808388798_47103"><br> Dan<br> <br> <br> </div> </div> </div> </div> </div> </div> </body> </html> --_000_0DB7E7B7C2FE764C8FAA0C7B78EF64A20C0ECA86EXMBX20103campu_--


This message came from the mail archive
http://www.auditory.org/postings/2014/
maintained by:
DAn Ellis <dpwe@ee.columbia.edu>
Electrical Engineering Dept., Columbia University