Skip to content

v0.10.0

Latest

Choose a tag to compare

@robmorgan robmorgan released this 02 Aug 09:24
64bc4cd

v0.10.0

What's Changed

This release attacks beat-grid phase accuracy head-on — rigid grids for quantized material lift corpus beat F-measure from 71.5% to 93.8% — and adds a real-time-safe momentary loudness meter for live per-deck metering — now on crates.io.

Rigid Beat Grids for Quantized Material

  • analyze_for_dj now fits a constant-BPM rigid grid (small BPM search around the tracked tempo × full phase circle, scored by ≤150 Hz kick-band onset energy) and adopts it when the phase fit is decisive, replacing the tracked beats (#27)
  • Fixes the misaligned grids observed on hard tracks: the failure mode was gross phase misplacement (60–180 ms mean signed error on quantized material with weak or syncopated kick evidence), never a wrong BPM. Mean beat F (±70 ms) rises 71.5% → 93.8% and downbeat F 20.7% → 76.4% on the 13 beat-annotated corpus tracks; adopted grids align to the annotations at sub-millisecond mean offset. BPM acc1 (100%) and key detection are unchanged
  • Live/drifting material keeps the tracked grid — adoption is gated on the fit's own phase decisiveness (phase_lock ≥ 0.3), and a 120→132 BPM tempo ramp never adopts
  • Public API: fit_rigid_grid (callable directly for a manual "quantize grid" affordance), refine_grid_rigid, RigidGridFit; AnalysisReport::rigid_grid_adopted reports the decision and timestretch-cli analyze prints it
  • Analysis cost: about +0.4 s per track (~200× realtime overall)

Momentary Loudness Meter

  • MomentaryLoudness: a real-time-safe streaming BS.1770-4 momentary (400 ms) loudness meter (#26)
  • Construction allocates; the push_stereo/process/momentary_lufs/reset paths never allocate, lock, or panic, so the meter can live inside an audio callback — e.g. live per-deck LUFS meters in a DJ mixer
  • Silence and insufficient data report the finite floor MomentaryLoudness::SILENCE_LUFS (−100.0) instead of −inf, keeping downstream atomic/UI math finite
  • Oracle-tested: frame-by-frame streaming matches a one-shot measurement within 0.01 LU, rate-independent across 44.1k/48k

QA

  • Signed beat-offset diagnostics in the BPM accuracy harness (beat_offset_mean_ms, beat_offset_std_ms, beat_offset_drift_ms_per_min), distinguishing constant phase offset from jitter from period drift — the diagnostics that isolated the grid failure mode

Full Changelog: v0.9.1...v0.10.0