Bpm

Bpm is a simple program written in c which tries to calculate the beats per minute of an audio stream. It handles Mp3, Ogg, Wav, and Raw streams, and can be piped to via stdin. Bpm is highly configurable, allowing you to specify how it looks for beats.

http://upload.wikimedia.org/wikipedia/commons/6/64/Phase_shift.pngBpm uses a phase shifting (image property of Wikipedia) algorithm to approximate the tempo of an audio stream. The stream is downsampled for performance reasons. A phase shift is then applied iteratively throughout the desired tempo range. Aggregate PCM differences are calculated at each shift. The shift with the smallest aggregate difference yields the best tempo approximation. Electronic music generally lends itself to analysis better than rock and other organic sound.

The latest version is 1.0. It may be downloaded here. The man page can be read here.

Subversion: svn://jdolan.dyndns.org/bpm