diff --git a/docs/experiments/2026-10-31-accuracy.md b/docs/experiments/2026-10-31-accuracy.md index 9029023..3683aca 100644 --- a/docs/experiments/2026-10-31-accuracy.md +++ b/docs/experiments/2026-10-31-accuracy.md @@ -15,6 +15,7 @@ t1a 0.43 · t1b 0.51 · t1c 0.39 · t1d 0.60; lnoe guitar F1 0.390. | E2 | Basic Pitch thresholds grid (onset 0.3–0.6, frame 0.2–0.4, min note 58/100 ms) | best ≈ default (0.5/0.3/58) | best 0.411 vs 0.403 | Not adopted — defaults are at the optimum on both. | | E3 | Error taxonomy | — | fp: 46% no reference note near, 16% octave, 21% 50–150 ms timing; fn: 47% different pitch at the onset (partial chords), 25% octave, 24% missed | Octave fixing upper bound only 0.40 → 0.46 (pitch-class F1) with no systematic direction. | | E4 | Complete partial strummed chords to standard guitar voicings (open + E/A-shape barres; maj/min/5/7/m7/sus/maj7) | −0.03…+0.03 | +0.016 (min 3 notes) | Not adopted yet — small, single-song evidence. | +| E5 | Repetition voting on the guitar transcription (`src/pipeline/repeat.ts`): bars of the estimated grid are repeats when their 16th-slot × pitch occupancy is similar (cosine ≥ 0.6, smoothed ±1 bar along the diagonal) **and** ≥ 30% of notes match exactly (pitch, ±50 ms); per bar, drop notes found in < 15% of its repeats, add notes found in ≥ 25% and ≥ 3 repeats | t1a 0.885 · t1b 0.840 · t1c 0.752 · t1d 0.737 (+0.016…+0.026) | **0.507** (P 0.45→0.53, R 0.37→0.49) | **Adopted** (commit 132659a), default on for guitar (`createPipeline(models, { repeatVote })`). | ## Learnings @@ -26,5 +27,18 @@ t1a 0.43 · t1b 0.51 · t1c 0.39 · t1d 0.60; lnoe guitar F1 0.390. - An undocumented MT3 ONNX export exists (HF `ModernMube/HTDemucs_onnx`, ~300 MB); not pursued — input/token format would need reverse-engineering and MT3 is weak on real recordings. +- E5 repetition voting: the two halves behave differently. Dropping non-recurring notes is what + helps synthetic (precision; t1 A-sections have only 2 repeats, so the add rule — which needs ≥ 3 — never + fires there). On lnoe adding is the big win (add-only, before the exact-match gate: recall 0.37 → 0.56, F1 0.500): Basic Pitch drops *different* + chord tones in each repeat of a strummed part, so the union across repeats completes chords (cf. E3/E4). + The add thresholds are therefore tuned on one real song — re-check when another trustworthy alignment exists. +- Controls: treating every bar as a repeat (no repetition detection) gives lnoe 0.440 and wrecks synthetic + (t1a 0.48), so the gain comes from the detected repeats, not from song-level note priors. +- Voting needs an accurate grid. With only the coarse (slot ±1) similarity, a 1% tempo error made distant bars + "similar" but 40 ms/bar misaligned and dropped lnoe to 0.23; the exact-match gate (≥ 0.3) turns that case into + a no-op (0.403). A per-pair time-shift search (±½ beat) to absorb drift picked spurious shifts and cost + 0.03 on lnoe — not used. Half/double/1.5× tempo errors and ¼–½ beat downbeat errors still gain (lnoe 0.44–0.51). +- Evaluated on cached transcriptions + estimated grids (`.scratch/exp/cases_full.ts`, baseline reproduces E1: 0.866 · 0.814 · 0.734 · 0.721); full pipeline spot check t1c/1 0.708 → 0.751 matches. +- Per-song effect is not uniformly positive (t1a/2 −0.011, t1d/5 −0.026); medians and lnoe improve. Experiment scripts live in the git-ignored `.scratch/exp/`.