Audio Check
Beyond the bitrate
By Evan Tanner
Skills
I have been an avid collector of music and audio for many years. One of the goals I had for my collection was to be able to identify which files in it were of lesser quality than other files. The format of each file, along with the reported bit-rate of each file, does not provide enough information regarding whether or not the file has been compressed by some type of lossy compression technique. Lossy compression removes information from the original file, so even though the original file can be converted back into a non-lossy format, the lost information cannot be restored. Therefore, I decided to create Audio Checker as a relatively simple Python program to go beyond simply identifying files based upon the label and inspect the actual file contents.
This script analyzes the frequency content of a song by combining three types of analysis: spectral edge detection, multi-window sampling, and shelf analysis. This script is designed to determine when there are rapid drops in the frequency content of a song, such as when the high-frequency content of a lossy encoded file abruptly disappears. To accomplish this goal, the script samples several areas within each song instead of analyzing only one point in time. The script then uses the cutoff frequency data gathered from all of these sampling points to calculate an estimate of the overall quality of the original file and identify potential issues with songs that have been labeled as "lossless" but may actually exhibit audio characteristics that do not match up with what would be expected from a lossless file, regardless of whether the file container used is a WAV or FLAC file, or if the header indicates a high bit rate.
I developed Audio Checker to be a simple, easy-to-use tool to evaluate my own personal library. The analysis provided by Audio Checker offers me another method to determine whether a given audio file's meta data is correct, even though the file has had a prior lossy conversion. The analysis results are indicative of the source of the audio file, not necessarily the original format used during the encoding process. This helps me to identify those files that require further investigation, or are worthy of replacement with higher quality versions.