Export to flac bit-perfect?


I have the following behavior which I don’t understand:

Source is the wav file onechan.wav.

I convert this file to flac using sox:
sox onechan.wav onechan_sox.flac

I convert the same file to flac using Audacity Dialog “Export Audio…” to onechan_aud.flac

I use flac to convert back to wav
flac -d onechan_sox.flac (results in onechan_sox.wav)
flac -d onechan_aud.flac (results in onechan_aud.wav)

MD5 sums:
$ md5sum onechan.wav
3cecb261e6e6d5bee7f1e4557e04a1a0 onechan.wav
$ md5sum onechan_sox.wav
3cecb261e6e6d5bee7f1e4557e04a1a0 onechan_sox.wav
$ md5sum onechan_aud.wav
161a4222a42ab302b389dd22d225af4d onechan_aud.wav

I cannot understand why the exported flac cannot be converted back in a bit perfect way…

Any hints are very welcome.
I am using Audacity 2.1.2.

Best, René

Did you turn off dithering when you exported from Audacity?


I have now disabled dithering in Preferences|Quality|High-quality conversion.
In addition I have forced 16 bit in the export dialog.

And it works!

Thank you very much.


Please be aware that in the case of real-world audio work, in which the audio is not only being transcoded but is also being edited and processed, turning off dither will produce lower sound quality and less dynamic range than leaving dither enabled.

For further information, there is an article about “dither” in the Audacity wiki: http://wiki.audacityteam.org/wiki/Dither

Thank you for the link!