Help - Search - Members - Calendar
Full Version: WAV differential evaluation of MP3
Hydrogenaudio Forums > Hydrogenaudio Forum > Listening Tests
mike anon
To produce an audible comparison of various MP3 files to the original, I am trying to find software that will produce a WAV file that is the difference between the best match between two sample WAV files.

If File1.WAV is the original, and is converted to File2.MP3 and then reconverted to File3.WAV, the difference between File1.WAV and File3.WAV should reveal the sound lost in compression, provided that one can match the sync and levels appropriately.

I have found FLAC software that will do sync and amplitude matching and produce a FLAC file of the difference, but I haven’t found any references a similar WAV file comparator.

EAC and foobar only tell you that files are different and where. They don’t generate a file of the differentials as far as I can tell.

Anyone know of appropriate software?
Nick.C
The difference between 1 and 3 is meaningless. You cannot determine the quality of an MP3 file from the difference.

To produce an "audible comparison" start an ABX test between the original and the MP3. That will determine whether you can hear a difference - which is infinitely more important than listening to a difference signal that will just confuse the listener.
Mike Giacomelli
QUOTE (mike anon @ May 23 2009, 14:55) *
If File1.WAV is the original, and is converted to File2.MP3 and then reconverted to File3.WAV, the difference between File1.WAV and File3.WAV should reveal the sound lost in compression, provided that one can match the sync and levels appropriately.


While it'd make testing easy if that really worked, it'd also mean lossy audio compression would be pretty useless, so maybe its a good thing it doesn't smile.gif
RadioGiant
This can be done with some difficulty in a program like Adobe Audition. Rip a file as an uncompressed .wav file. Invert the phase of the file (polarity, actually...must invert BOTH CHANNELS!), then save the resultant file in a lossy format like mp3.

Open both files in the multitrack view, each in it's own "track", making certain that they are time aligned. Hit play. What comes from the speakers is what mp3 encoding removed...the difference between the two. And at high bitrates is's very, very little. The result usually sounds like a very, VERY quiet whisper, vaguely related to the music having been recorded. Pretty interesting.

By the way, if you get a HUGE, LOUD sound...you did it wrong. You didn't invert the phase, or didn't get the two files exactly aligned in time.
muaddib
QUOTE (RadioGiant @ Aug 15 2009, 09:02) *
This can be done with some difficulty in a program like Adobe Audition. Rip a file as an uncompressed .wav file. Invert the phase of the file (polarity, actually...must invert BOTH CHANNELS!), then save the resultant file in a lossy format like mp3.

This is not good way of testing. If you really want to hear a difference between mp3 and original, then invert decoded mp3 not the source of encoding. And even then it is bad test, because you can turn up the volume, enough to be able to hear differences. This volume would be too loud for normal listening in many cases.
2Bdecided
I wouldn't describe the difference as a "whisper" - in fact, given that the original and encoded files sound (virtually) identical, it's amazing that the mathematical difference is so large (loud).

Sample accurate time alignment is a pre-requisite for making this work.

Be aware that invert-mix-paste in many applications will introduce small errors (or in some cases huge errors!) if the signal contains samples at digital full scale, because positive digital full scale is +32767 and negative digital full scale is -32768 - and hence can't be inverted correctly (i.e. there's no +32768 value available).


The amplitude or loudness of this difference signal is not an indication of the perceived quality of the encoding - where the noise is all masked by the original signal, the difference can be quite loud yet the encoded file sounds identical to the original. Where the noise is just pure uncorrelated white noise, it could have a much lower amplitude, and sound much quieter on its own, and yet still be easily audible in the presence of music or speech (e.g. cassette hiss!).

Cheers,
David.
krabapple
QUOTE (2Bdecided @ Aug 17 2009, 06:42) *
Be aware that invert-mix-paste in many applications will introduce small errors (or in some cases huge errors!) if the signal contains samples at digital full scale, because positive digital full scale is +32767 and negative digital full scale is -32768 - and hence can't be inverted correctly (i.e. there's no +32768 value available).



Interesting! Thanks. Underr what conditions will this introduce huge errors, though?
lvqcl
for 16-bit integer, -(-32768) = -32768.
Arnold B. Krueger
QUOTE (2Bdecided @ Aug 17 2009, 06:42) *
I wouldn't describe the difference as a "whisper" - in fact, given that the original and encoded files sound (virtually) identical, it's amazing that the mathematical difference is so large (loud).

Sample accurate time alignment is a pre-requisite for making this work.


It is true that there are cases where the sources are seemingly identical, but perfect time alignment is not possible. For example, the same analog source encoded to digital with any error at all in start time or clock frequency.

I've been known to upsample two sources to unbelievably high frequencies (up in the MHz range) to get the time-alignment good enough.
Arnold B. Krueger
QUOTE (RadioGiant @ Aug 15 2009, 03:02) *
This can be done with some difficulty in a program like Adobe Audition. Rip a file as an uncompressed .wav file. Invert the phase of the file (polarity, actually...must invert BOTH CHANNELS!), then save the resultant file in a lossy format like mp3.

Open both files in the multitrack view, each in it's own "track", making certain that they are time aligned. Hit play. What comes from the speakers is what mp3 encoding removed...the difference between the two. And at high bitrates is's very, very little. The result usually sounds like a very, VERY quiet whisper, vaguely related to the music having been recorded. Pretty interesting.

By the way, if you get a HUGE, LOUD sound...you did it wrong. You didn't invert the phase, or didn't get the two files exactly aligned in time.


That all said, analysis of the difference between wav files often tells us little or nothing about whether they sound the same or different.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Invision Power Board © 2001-2009 Invision Power Services, Inc.