Downloads · 30 days
0
elicwhite/linkseg-7c-onnx
linkseg-7c-onnx is a audio classification model from elicwhite. Use it for the audio classification task on the model card, and read the license before you ship it in a product. It is set up for onnx. The card lists the license as cc-by-4.0.
An onnxruntime-web-friendly port of the pretrained LinkSeg 7-class music-structure / section-labeling model, for running music structure analysis entirely in the browser (WebGPU-primary, WASM fallback).
Downloads · 30 days
0
Access
Public
Updated Aug 6, 2026
Repo size
1.6 MB
Likes
0
Public
Click a slice to open those files.
.onnx1.6 MB · 100%
From the Hugging Face model README
An onnxruntime-web-friendly port of the pretrained LinkSeg 7-class music-structure / section-labeling model, for running music structure analysis entirely in the browser (WebGPU-primary, WASM fallback).
linkseg-web —
LinkSeg.load() fetches this file (OPFS-cached) and runs the full pipeline.This model — architecture and learned weights — is the work of the LinkSeg authors and is licensed Creative Commons Attribution 4.0 International (CC-BY 4.0). If you use or redistribute it you must preserve this attribution:
M. Buisson, B. McFee, S. Essid — Using Pairwise Link Prediction and Graph Attention Networks for Music Structure Analysis, ISMIR 2024.
The ONNX port (DGL graph ops rewritten as dense-tensor equivalents; mel front-end, cdist,
GroupNorm, EMA adaptive-pool and batch-stat BatchNorm decomposed to ONNX-standard ops) does not
modify the learned parameters and was validated byte-exact against the original PyTorch/DGL model.
The port/glue code (the linkseg-web package) is MIT; the model weights remain CC-BY 4.0.
N. ~1.5 MB.mel: float32 (N, 1, 64, 64) — per-beat log-mel windows. torchaudio
MelSpectrogram(sr=22050, n_fft=1024, hop=256, n_mels=64, f_min=0, f_max=11025, power=2) +
AmplitudeToDB(power), computed on the client (STFT stays out of the graph). N = number of
(requantized) beats; needs ≥ 4.bound (N-1,) — per-adjacent-beat boundary activations (sigmoid).label (N, 7) — class logits over {silence, verse, chorus, intro, outro, inst, bridge}.apred (N, N, 3) — pairwise link logits (not used by the default decoder).It runs on the full mix — no source separation needed — plus beat times from any beat tracker (LinkSeg is robust to the beat source).
import {LinkSeg} from 'linkseg-web';
const model = await LinkSeg.load(); // downloads this ONNX, caches in OPFS; WebGPU→WASM
const sections = await model.analyze({
audio, // Float32Array, mono (resampled to 22050 internally if needed)
sampleRate, // e.g. 44100
beats, // number[] beat times in seconds (your beat tracker)
});
// → [{ start, end, label }, ...]
WebGPU computes this model in fp32 and tracks the PyTorch reference tightly; WebGPU and WASM decode identically, so auto-fallback to WASM is safe.