Skip to main content

TEMPO_CONVENTION

Constant TEMPO_CONVENTION 

Source
pub const TEMPO_CONVENTION: &str = "onset strength: the rise of each third-octave band power \
from 30 Hz, compressed as ln(1 + P / knee) with the knee 60 dB below full scale, against the \
frame 10 ms earlier, in Hann frames of the power of two of samples nearest 46.4 ms (2048 at 44.1 \
and 48 kHz) on a 1 ms hop, low-passed at 20 Hz, less its \
100 ms mean, below 10 % of its largest rise set to 0; each tempo t with |given / t - 1| at \
most 3 % (2.91 % below to 3.09 % above the given one), in 0.01 BPM steps, scores the unbiased \
autocorrelation summed at 1 to 32 beats; the refined tempo is used when its score is at least \
1.5 times the median score (tempo_peak) and either 0.4 of the lag count times the zero-lag \
autocorrelation (beat_periodicity), or 0.75 of that on every second or fourth beat lag alone \
(sparse_periodicity) with at most 0.8 peaks of the onset strength per beat at the slowest \
tempo of the search (onsets_per_beat), \
and at least 0.9 of the energy of the rise before its low-pass lies within 25 ms of its peaks, \
each the largest within 30 ms (onset_sharpness); both shares stop at 1; cycles_in_span counts \
the whole beats of the stem at the slowest tempo of the search, given / 1.03, so the longest lag \
keeps 4 beats of overlap at every candidate; a stem of fewer than 8 keeps the given tempo";
Expand description

The convention of the refined tempo in layers.json.