-
Notifications
You must be signed in to change notification settings - Fork 2
Home
The Generic Beat Detector (GBD) strives to deliver an industrial strength library and IoT framework for realtime beat detection (and soon other DSP analysis) for live music streams. It is designed with the IoT maker in mind who wishes to create events (e.g. light control) that are automatically synchronized with an arbitrary/random stream of playing music.
The music analysis library of the current GBD release, v0.21, performs the following realtime and generic beat detection:
- Bass beat detection in frequencies less than 200Hz
- Detection of snare-like hits in frequencies between around 3KHz and 10KHz
- Detection of cymbals-like sounds in frequencies above 15KHz.
This mode of beat detection is referred to as GBD Standard. An OpenGL LED emulation can be seen here.
Note that while GBD's realtime beat detection is sturdy, it still requires some "compliance" on the part of the user if it is to function in the most generic manner possible, i.e. across the variety of music genres. For the best results, the quality of the music should be that of professional studio CD recordings: preferably WAV PCM or, at least, an encoding by an industry-standard audio format converter. For example, pirated .mp3
downloads from the Internet (i.e. poorly encoded or transcoded formats) or amateur recordings are likely to produce unsatisfactory
results.
GBD's realtime beat prediction accuracy is decent. Nevertheless, with the current release expect the following:
-
For bass beats, while the algorithm has largely been calibrated/tuned for "crispy" kickdrum beat detection:
-
Extremely intense and prolonged basslines that effectively drown kickdrum beats may degrade crispy beat detection. This is true even for the human ear.
-
Once in a while, very intense basslines with sharp onsets (rising edges) get interpreted as kickdrum beats (especially since there is no decent way for the RT algorithm to look-ahead in time without introducing unacceptable latency). To mitigate this problem, the algorithm applies heuristics to "smooth-out" otherwise spurious/erratic kickdrum beat detection.
-
-
Snare Hits and Cymbals
Currently, the algorithm employs pattern recognition (i.e. a limited form of "AI") for the detection of both snare hits and cymbals-like sounds -- bass beat detection is purely based on first principles, i.e. physics.
Compared to bass beat detection, snare hit detection is still quite problematic and brittle. It is particularly sensitive to the quality of the recording. Thus, it works impeccably for some tracks while performing fairly to poorly for others. Notoriously, false positives are often due to signals containing samples that have been clipped (i.e. non-linear distortion), e.g. disproportionately loud and fricative vocals/instruments. These signals generate harmonics that confuse the pattern recognition algorithm. An experimental neural-network based is algorithm is still under development.
Detection of cymbals-like sounds is quite satisfactory.
See the documentation (right side bar) for details on getting started with the GBD framework.
(C) GBD, Generic Beat Detector