ogbabydiesal commited on
Commit
bfb5964
·
verified ·
1 Parent(s): 4dcbee8

Add HT-Demucs ONNX (fp16 weights), re-hosted from StemSplitio@d54ed9eb with MIT notice and attribution

Browse files
Files changed (3) hide show
  1. LICENSE +21 -0
  2. README.md +114 -0
  3. htdemucs_fp16.onnx +3 -0
LICENSE ADDED
@@ -0,0 +1,21 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ MIT License
2
+
3
+ Copyright (c) Meta Platforms, Inc. and affiliates.
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
README.md ADDED
@@ -0,0 +1,114 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ ---
2
+ license: mit
3
+ pipeline_tag: audio-to-audio
4
+ tags:
5
+ - music-source-separation
6
+ - stem-separation
7
+ - demucs
8
+ - htdemucs
9
+ - onnx
10
+ - onnxruntime-web
11
+ library_name: onnx
12
+ ---
13
+
14
+ # htdemucs-onnx (fp16 weights)
15
+
16
+ An ONNX export of **HT-Demucs** (Hybrid Transformer Demucs, `htdemucs`) for
17
+ 4-stem music source separation — drums, bass, other, vocals.
18
+
19
+ This repository is a **re-host, not a new model**. It exists so that
20
+ [Audio Magic](https://audiomagic.studio) has a stable, pinned copy of a
21
+ browser-loadable Demucs export rather than depending on a third-party repo that
22
+ could move or change. Nothing has been modified.
23
+
24
+ ## Provenance
25
+
26
+ | | |
27
+ |---|---|
28
+ | Original model | [Demucs v4 / HT-Demucs](https://github.com/adefossez/demucs) — Meta Platforms, MIT |
29
+ | ONNX conversion | [`StemSplitio/htdemucs-onnx`](https://huggingface.co/StemSplitio/htdemucs-onnx), revision `d54ed9eb60e258ea82131c6ee14578628816456a` |
30
+ | File | `htdemucs_fp16weights.onnx` → `htdemucs_fp16.onnx` |
31
+ | Size | 165,612,636 bytes |
32
+ | SHA-256 | `d05c269d0178d2a72ad484b10b11dd370193fc923201c3b27a99f848745db70a` |
33
+
34
+ The file is byte-identical to the upstream conversion at that revision. Verify with:
35
+
36
+ ```bash
37
+ shasum -a 256 htdemucs_fp16.onnx
38
+ ```
39
+
40
+ ## Inputs and outputs
41
+
42
+ | | Name | Shape | Dtype |
43
+ |---|---|---|---|
44
+ | Input | `mix` | `(1, 2, 343980)` | float32 |
45
+ | Output | `stems` | `(1, 4, 2, 343980)` | float32 |
46
+
47
+ - Stereo, 44.1 kHz, 7.8-second segments (343,980 samples), samples in `[-1, 1]`.
48
+ - Output stem order: **`[drums, bass, other, vocals]`**.
49
+ - For longer audio, process in overlapping segments and overlap-add.
50
+
51
+ ## Verification
52
+
53
+ Checked with `onnxruntime-node` on CPU against a synthetic four-source mixture
54
+ with known ground truth:
55
+
56
+ - **Reconstruction: 37.0 dB SNR** — the four stems sum back to the input, the
57
+ property Demucs is built to have, which is the strongest available evidence
58
+ that the conversion is faithful.
59
+ - **Drums** correlate 0.99 and **bass** 1.00 with their ground-truth sources,
60
+ with negligible cross-leakage.
61
+ - Vocals were not meaningfully testable this way: a synthetic harmonic tone is
62
+ not singing, and the model reasonably classified it as an instrument. Vocal
63
+ quality should be judged on real recordings.
64
+ - Speed: 1.1 s per 7.8 s segment on native CPU — a realtime factor of ~0.14×.
65
+
66
+ ## Licence
67
+
68
+ Demucs and its pretrained weights are released by Meta under the MIT licence,
69
+ which permits redistribution provided the copyright notice travels with it. The
70
+ full notice is included in this repository as `LICENSE` and reproduced here:
71
+
72
+ ```
73
+ MIT License
74
+
75
+ Copyright (c) Meta Platforms, Inc. and affiliates.
76
+
77
+ Permission is hereby granted, free of charge, to any person obtaining a copy
78
+ of this software and associated documentation files (the "Software"), to deal
79
+ in the Software without restriction, including without limitation the rights
80
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
81
+ copies of the Software, and to permit persons to whom the Software is
82
+ furnished to do so, subject to the following conditions:
83
+
84
+ The above copyright notice and this permission notice shall be included in all
85
+ copies or substantial portions of the Software.
86
+
87
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
88
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
89
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
90
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
91
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
92
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
93
+ SOFTWARE.
94
+ ```
95
+
96
+ ## Citation
97
+
98
+ If you use this, cite the original authors — the work is theirs:
99
+
100
+ ```bibtex
101
+ @inproceedings{rouard2023hybrid,
102
+ title = {Hybrid Transformers for Music Source Separation},
103
+ author = {Rouard, Simon and Massa, Francisco and D{\'e}fossez, Alexandre},
104
+ booktitle = {ICASSP 23},
105
+ year = {2023}
106
+ }
107
+
108
+ @inproceedings{defossez2021hybrid,
109
+ title = {Hybrid Spectrogram and Waveform Source Separation},
110
+ author = {D{\'e}fossez, Alexandre},
111
+ booktitle = {Proceedings of the ISMIR 2021 Workshop on Music Source Separation},
112
+ year = {2021}
113
+ }
114
+ ```
htdemucs_fp16.onnx ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:d05c269d0178d2a72ad484b10b11dd370193fc923201c3b27a99f848745db70a
3
+ size 165612636