Audio compression

X3 Audio compression

X3 is a simple and effective lossless audio compressor for underwater sound. It is based on Shorten and has some of the features of FLAC but is designed specifically for use in underwater sound recording tags and buoys. The name comes from the compression factor that it usually achieves, i.e., 3 times. The algorithm is described in a paper in the Journal of the Acoustical Society of America 133:1387-1398, 2013, available here and at http://link.aip.org/link/?JAS/133/1387. The article is Copyright 2013 Acoustical Society of America. It may be downloaded for personal use only. Any other use requires prior permission of the author and the Acoustical Society of America.

Archive files and metadata
A vast majority of underwater sound samples are stored in WAV format files. This format is relatively simple and reading software is freely-available on the internet. However it has two important limitations:

1. There is no convenient and standard way to add arbitrary metadata to a WAV file. Metadata like the location and depth of a recording, the equipment used and the precise time, are an integral component of the sound sample yet must be stored in a separate file from the audio data. Although enhanced WAV formats like Broadcast WAV do allow metadata to be embedded, we have not found any freely-available tools for working with these formats.

2. Underwater sound recorders can collect data from several sources simultaneously, each with a different data rate. For example, the recorder may sample a depth sensor every second or may have a low and a high frequency audio channel. WAV files do not conveniently support data with multiple rates within the same file and so these different data must be stored in separate files. Thus an archive of data from a sound recording ends up spread over several WAV and metadata files.

Because of the variable data rates produced by a lossless compressor such as X3, compressed audio data cannot be easily stored in a WAV file. To store X3 data and address the above limitations of WAV files, we have developed an integrated archive file format for sound recordings, the X3 Archive. This format allows metadata to be embedded throughout the file and allows data to be collected with different sampling rates and duty-cycles. The format provides strict timing and error checking and so is suitable for archiving and exchanging sound recordings. The format has been used since 2003 in DTAG sound recording tags

Software
A Gnu Public License implementation of the X3 compressor and archive file writer/reader is available in Matlab here: x3toolbox. A C implementation will be posted shortly. Please check back soon.

Sound samples
A set of sound samples used in testing the X3 compressor is available here.