ferraus analyze tempo
Tempo, beat times, downbeats, and time signature
Synopsis
ferraus analyze tempo <input> [options] [-o <output>]
What it does
Onset strength (spectral flux on a log-mel spectrogram) is autocorrelated and scored on a comb of metrical levels with a perceptual prior around 120 BPM; beats are placed by dynamic programming (Ellis 2007) and the tempo is refined through the beat times. Downbeats are reported only when the bar accent pattern is clear.
Examples
BPM, confidence, and beat times
ferraus analyze tempo song.wav --json
Search only fast tempi
ferraus analyze tempo dnb.wav --range 140..190
Keep a slow ballad from being read at double time
ferraus analyze tempo ballad.wav --range 50..100 --json
Options
| Flag | Type | Default | Meaning |
|---|---|---|---|
--range | text | 60..200 | Tempo search range in BPM, low..high |
Global options
Every command also accepts the global options (-o, --json, --dry-run, --overwrite, --progress, ...). See Global options.
Exit codes
| Code | Meaning |
|---|---|
| 0 | Success |
| 1 | Processing failed |
| 2 | Usage or parameter error |
| 3 | Input missing or unreadable |
| 4 | Unsupported format or codec |
| 8 | Cancelled |
| 70 | Internal error (bug) |
Common mistakes
- Forgetting that outputs are never overwritten: pass
--overwriteor a new-opath when re-running.
For models
- MCP tool:
ferraus_analyze_tempo - Schema:
ferraus schema analyze tempo - Pipeline:
{ op: analyze tempo, args: { ... } }(flag names with_instead of-) - fx stage: no
{"command": "analyze tempo", "defaults": {"range": "60..200"}}