I’ve downloaded Audacity 2.0.3, running on Windows 7 Pro 64bit.
In *File *Edit *Preferences *Quality I noticed “Sample Rate Conversion” for “Real Time Conversion” was not set to ‘best quality - slowest’, so I changed it to best quality-slowest, is there any reason the default was not “best quality”?, I presume it’s OK to have now set it to “best quality-slowest”?, “Dither” was already set to “None” so I left that…
For “High Quality Conversion” it was already set to “best quality-slowest” so I have left that, however “Dither” was set to “shaped”, I think I need to set this to “none” ?, is that correct?
Thanks
PS - I’m wanting the most lossless high quality results as possible…
I know MP3 is lossy, I never use MP3 at all…
I use Audacity for “speed” (pitch/tempo) correcting WAV and FLAC files.
Just wanted to make sure those particular settings I asked about are for optimal quality?, and are there any other sneaky settings (like that incorrectly set “dither” setting) I need to change?
Thanks
“Best quality-slowest” and “Dither” set to “shaped” gives the best quality conversion from 32 bit (Audacity’s internal format to 16 bit (usually used for export) and for changing the sample rate. This is also the slowest and may be too demanding for real time playback, particularly if you have multiple tracks or a slow computer.
“Medium quality” and “Dither” set to “none” is a lot faster. The “Real time” settings are only used when playing back in Audacity and previewing - they have no effect on processing, mixing or exporting. They are not used if the audio in Audacity is 32 bit (default) and the sample rate of the track matches the Project rate (lower left corner of the main Audacity window).
Hi,
From what I have always understood “dither” is used when “downsampling”?
When “speed” (pitch/tempo) changing in Audacity I only ever export at the same sample rate as the original files eg. if originally is 16/44.1, I’ll export it as 16/44.1, the same goes for a file that is originally 24/48000, once I speed change it I’ll export it at 24/48000.
What I noticed was that when “dither” is set to “shaped”, if I change the speed of the same original file two different times by the same percentage, and compare the 2 different output files with “EAC Wav Compare”, the samples of the 2 different output files will be different to each other, however if I set “dither” to “none”, and change the same file 2 different times by the same percentage, the 2 different output files when compared in “EAC Wav Compare” will be identical, I know this is because “dither” is changing the sample rate when set to “shaped”, but does this need to be done when my speed changes are being exported at the same sample rate as the orignal file?, does it even matter?, and if so, is the difference between “shaped” and “none” going to be audible? (I ask this as I have dozens of speed changed files made with “dither” set to “none” - using an older version of Audacity).
Thanks
OK…
I just took a 16bit/44.1 file, applied a +2% speed increase, exported it as 16bit/44.1 with dither set to “shaped”, I then did the same process with dither set to “none”.
I compared the 2 output files and in the silent couple of seconds before and after the music starts in the one with dither set to “shaped” clearly has audible hiss which the one made with dither set to “none” does not…
On quick listen I can’t actually hear a difference in the musical content, but yeah the one with dither set to “shaped” definitely has a lot more hiss in the silence before and after the music…
So from what I can tell it sounds better with dither set to “none” ?, but from what I think I understand isn’t that the opposite of what you have recommended to me?
Thanks
Shaped dither is recommended when doing the final export of “music”. It is not recommended for exporting “silence”.
Dither is applied when converting from a high bit depth to a lower bit depth.
Without dither, such a conversion creates harmonic distortion.
With dither, such a conversion adds a little noise.
For “music” there is usually so much more naturally occurring background noise that the dither noise is completely inaudible, but the added harmonic distortion adds an unpleasant and unnatural harshness that is noticeable in very quiet passages.
For synthetic (generated) tones and suchlike, it may be better to use other types of dither (such as “rectangle” which does not add noise during absolute silence) or no dither at all.
The complete solution (avoid harmonic distortion without dither noise) is to keep the audio in 32 bit float format, but then there may be compatibility problems with other applications. 24 bit audio is sometimes used as a compromise solution because harmonic distortion without dither is much less, or noise when using dither is much less.
Attached is a very low level 440Hz sine tone (pure tone) that has been converted from 32 bit float to 16 bit, first with dither and then without dither. It has been greatly amplified to make the difference obvious.
And here is the same thing, but at its natural volume. In this sample it begins with a 0 dB (loud) tone so that you can set your playback system to a “normal” level.
At a “normal” playback level we are talking about quite subtle differences.
OK I think that’s where I am confused. I know dither is supposed to be used when downsampling (going from higher to lower bit depth), but when loading a 16bit file into Audacity (with the float point at 32bit), and I export that original 16bit file as 16bit, is that actually downsampling from 32bit?, or is it working with the file as the original 16bit file?
From what I just worked out, it’s actually working with it as a normal 16bit file, not 32bit eg.
I just took a 16bit/44.1 file and saved the first 2 minutes by exporting saved selection with dither “shaped” and another with dither set to “none”.
The file with dither “shaped” has different samples to the original file, but the one exported with dither set to “none” has exactly the same samples as the original file (EAC Wav Compare), so it seems dither set to “none” will export the file as it originally was without changing samples…
Maybe that’s what you meant when you said “They are not used if the audio in Audacity is 32 bit (default) and the sample rate of the track matches the Project rate (lower left corner of the main Audacity window).”, I wasn’t sure at first but I think thagt is what you meant there…?
“Resampling” is when you change the “sample rate” (for example, from 48000 to 44100 samples per second).
This is where the “Best quality-slowest” … setting applies.
“Dither” applies to changing the “sample format” (bit depth) to a lower format - for example from 32 bit to 16 bit.
Audacity always works internally in 32 bit float format.
All processing and mixing occurs in 32 bit float format, including “rendering to a file” (though it is contentious whether Audacity should work in 32 bit float format when rendering 16 bit audio to a 16 bit file).
If you are working purely with 16 bit and are not processing the audio then it is safe to turn dither off because all sample values will be exact 16 bit values and dither is unnecessary. “Cut, Delete, Paste, Copy and Truncate” are simple “editing” commands that do not “process” the sound. Virtually everything else that Audacity does is “processing”. “Processing” is anything that requires sample values to be recalculated. Audacity achieves extreme precision when recalculating sample values by working in 32 bit float, but then that leaves the problem that the 32 bit values need to be “rounded” in some way when exporting to 16 bit.
Ah so it does actually work with a file imported as 16bit at 32 bits (I was never sure if that just meant you could import a file of anything up to 32bits, but have it work with the file at it’s original bitrate (eg. 16, 24, 32), so it seems then that speed changing 16bit and 24bit files technically does require dither to be set to “shaped”, not “none”…
Thanks
Bit rates for uncompressed files are worked out by multiplying bit depth * number of channels * sample rate. That makes a stereo 16-bit file to be 1411 kbps bit rate.
This table lists the bit depths Audacity imports WAV files at:
Is the column you call “quality preference” on that list the same as what Audacity settings call the “default sample format”?
You mention specifically for non-compressed eg. WAV, can you please tell me what happens with FLAC, how does FLAC import/export?
PS - I remember 2-3 years ago I was told there was a bug with dither being turned on, and that I should have it set to off…, I guess anything I’ve speed corrected with Audacity in that time will have digital artefacts???
In this context FLAC can be thought of as “non-compressed”.
As I wrote earlier: “it is contentious whether Audacity should work in 32 bit float format when rendering 16 bit audio to a 16 bit file”. Depending on your point of view this could be seen as a “bug” or a “requested feature enhancement”, but either way the current behaviour is not ideal and is confusing to users. We log “bugs” and “enhancements” on the same bug tracking system, so in that sense it is a “bug” and is not yet resolved.
As to whether or not dither should be disabled please see my previous replies in this topic thread.
FLAC like other lossless formats has its export bit depth set by the export choice. The Default Sample Format in Quality Preferences plays no part .
Import of FLAC (using libflac) could be considered more “logical” than WAV in that you don’t import at a higher bit depth than the Preference bit depth or the file bit depth:
Default
Sample Format File bit depth Imports as
16 16 16
16 24 24
24 16 24
24 24 24
32 16 32
32 24 32
On Linux, FLAC is imported by the WAV importer (libsndfile) by default so I assume but I have not tested that the behaviour will be as for WAV.
OK I have Audacity at 32 bit float default sample format.
I just loaded a 16bit FLAC file, gave it a +0.1% speed increase, and exported using shaped dither as FLAC.
I then went through exactly the same process but exported as WAVE instead of FLAC.
The exported FLAC file has quiet hiss in the silence before the track, however the exported WAVE file has much louder hiss in the silence before the track…
Why does the exported WAVE have much louder hiss than the exported FLAC?, they were identical process’ apart from one being exported as WAVE and the other FLAC…
Probably because you exported as 24 bit FLAC.
If you exported as 16 bit FLAC the dither should have exactly the same level (note that because dither has a random element they will not be bit for bit identical.)
The amount of dither required when exporting in 24 bit is much lower than 16 bit.
To select 24 bit FLAC, set FLAC as the export format and then click the Options button.
For 24 bit WAV, select “Other uncompressed files” and then click the Options button.
Hello,
Yes I am familiar with how to export WAV and FLAC as 24bits…, so I am certain I did not export as 24bit FLAC as you suggested I might have done…
I am certain I did exactly the following:
Audacity is set at default 32bit float sample format.
Imported a 16bit/44.1 FLAC file, gave it a +0.1% speed increase, and exported using shaped dither as FLAC 16bit/44.1.
I then went through exactly the same process but exported as WAVE 16bit/44.1 instead of FLAC 16bit/44.1.
The exported FLAC file has quiet hiss in the silence before the track, however the exported WAVE file has much louder hiss in the silence before the track…
They were identical process’ apart from one being exported as WAVE and the other FLAC, seems odd to me that that the WAV has more hiss…
I’m sure if you try it you’ll get the same result…
No. I’m getting exactly the same amount of hiss whether I export as 16 bit WAV or 16 bit FLAC.
I’ve also tested on Windows and I get exactly the same result.
If you can give precise step-by-step instructions I will try to replicate your results.
Almost all special effects require some dither. If you have a voice singing three musical notes and you cut one of the notes, then the other two are completely unchanged and can go in and out of Audacity – 16-32-16 – without dither, but if you change the voices in any way, you’re stuck.
There’s a difference between 32 bit and 32-bit floating. Audacity uses floating internally because, for one example, if you apply an effect or filter that causes the show to overload or distort from high volume, 32-floating will allow you to simply reduce the volume with another effect and carry on. The non-float formats would permanently destroy the show.
This happens a lot. Photoshop doesn’t use simple 8-bit color internally.