BPM detection

Status
Not open for further replies.

danixdj

Well-known member
Which is the best way for a perfect bpm detection?

I am using a teensy audio board...

Thanks

Dani
 
There is no perfect way. A sensor in a musician's shoe would probably be the best way. ;)

Many interesting academic papers have been published on this topic. They're on my bucket list.

In general, two broad categories of algorithmic beat detection exist. If you have access to all the material, like MP3 files stored on a PC, you can do a FFT or other time consuming analysis over the entire file or very large portions of the data. This is how DJ software like Traktor works.

The other much harder way is real-time analysis. Humans are amazingly good at this. It's remarkably difficult to do in software.
 
I have some techniques that don't take too much CPU but only work for specific circumstances.

What is your planned usage? I might be able to help.

Also, @PaulStoffregen is right and I might suggest an option in that light: "A sensor in a musicians shoe" Or rather, a tap tempo button. If you can simply tap the button a few times to the beat, you can use elapsedMillis to get the time between taps, and average if you like. you can even use the elapsedMillis variable with a modulo of the last valid tapped BPM to drive tempo synced events pretty easily.

But again, "the best way" is highly dependent on the details of what you plan to make.. The best way to detect tempo with a button is tap tempo, the best way to find the tempo on 4/4 techno is by lowpass filtering the kick into isolation, envelope following with an absolute value / another IIR filter and finding the rising edge of the amplitude from this. the best way to detect tempo in free jazz is to go do something else.
 
Status
Not open for further replies.
Back
Top