use case · multi-model · Basic Pitch (0.3 MB) × DistilHuBERT Genre (24 MB)

Two-Stage Music Intelligence

Run two distinct audio neural networks on the exact same clip in two separate Web Workers — completely offline after first download. Stage 1 (Basic Pitch, ~0.3 MB, ONNX Runtime Web) listens at 22.05 kHz to extract polyphonic MIDI notes, musical key, chord progression, and pitch range. Stage 2 (DistilHuBERT Music Genre, ~24 MB, Transformers.js) listens at 16 kHz to tag the musical genre across the 10 GTZAN classes.

1 · Load both on-device models

Stage 1 · Basic Pitch (Polyphonic MIDI)

spotify/basic-pitch · onnxruntime-web · fp32 · ~0.3 MB

Stage 2 · DistilHuBERT (Music Genre)

onnx-community/Musical-genres-Classification-Hubert-V1-ONNX · transformers.js · q8 · ~24 MB

2 · Select or drop a musical clip

Presets are synthesized live in JS and resampled cleanly to 22.05 kHz (Stage 1) and 16 kHz (Stage 2). Upload a real song clip for the full 10-genre GTZAN range.

Drop an audio file (WAV/MP3/M4A/OGG) here, or click to browse

Load both Stage 1 and Stage 2 models above to run the full two-stage pipeline.

3 · Combined Music Intelligence Report

Combined summary: Waiting for both models to finish…
Top Genre (Stage 2)–
Musical Key (Stage 1)–
MIDI Notes & Range–
Stage 1 · Stage 2 ms–

Stage 1 · Polyphonic Piano Roll & Chords

Chord sequence appears after Stage 1 completes.

Stage 2 · 10-Genre GTZAN Classification

DistilHuBERT probabilities over the exact same audio clip (resampled to 16 kHz mono):

Genre distribution appears after Stage 2 completes.

← Wild Back to Basic Pitch overview