Demucs-Torchcodec
Demucs-Torchcodec is a modernized fork of the Original Demucs.
While the original repository is no longer actively maintained, this fork continues the project by replacing the deprecated torchaudio decoding backends with the high-performance torchcodec library.
Why use this fork?
- Modern Backend: Uses
torchcodecfor faster and more robust audio decoding. - Dependency Lean: Removes reliance on older
torchaudioversions that often conflict with modern PyTorch installations. - Future Proof: Designed to work with Python 3.10+ and the latest PyTorch ecosystems.
Installation
1. Requirements
Before installing, ensure you have FFmpeg installed on your system (required by torchcodec):
- Ubuntu/Debian:
sudo apt-get install ffmpeg - macOS:
brew install ffmpeg - Windows:
choco install ffmpeg(or download from ffmpeg.org)
2. Install the Package
pip install -U demucs-torchcodec
Usage
The entry point for this version is demucs-torchcodec.
# Basic separation (defaults to htdemucs)
demucs-torchcodec test.mp3
# Separate into 2 stems (vocals and accompaniment)
demucs-torchcodec --two-stems=vocals test.mp3
# Use the high-quality fine-tuned model
demucs-torchcodec -n htdemucs_ft test.mp3
Supported Models
This fork supports all standard Demucs v4 models, including:
htdemucs: Hybrid Transformer Demucs (Default).htdemucs_ft: Fine-tuned version (Higher quality, slower).hdemucs_mmi: Hybrid Demucs v3 retrained.mdx_extra: Trained with extra data.
Credits & License
Original Author: Alexandre Défossez.
This project is licensed under the MIT License , exactly like the original Demucs. See the LICENSE file for details.
If you use this model in your research, please cite the original paper:
@inproceedings{rouard2022hybrid,
title={Hybrid Transformers for Music Source Separation},
author={Rouard, Simon and Massa, Francisco and D{\'e}fossez, Alexandre},
booktitle={ICASSP 23},
year={2023}
}
Metadata
Release files for demucs-torchcodec 0.2.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| demucs_torchcodec-0.2.0.tar.gz | 854.7 kB | Without provenance | Details for demucs_torchcodec-0.2.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| demucs_torchcodec-0.2.0-py3-none-any.whl | Python 3 | none | any | Details for demucs_torchcodec-0.2.0-py3-none-any.whl |
Total release size: 920.7 kB
Release files / demucs_torchcodec-0.2.0.tar.gz
| Download URL | demucs_torchcodec-0.2.0.tar.gz |
|---|---|
| Size | 854.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
bafd2163e07fe180641b3a36a82fa9fa66d960814b10ded835e74fc3f91b280a
|
|
BLAKE2b-256 checksum How to use checksums |
f2414bd173601d57bc82fa8c11174085fe904ce149d4f275dc0bdb84fc9eb479
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.15
|
Release files / demucs_torchcodec-0.2.0-py3-none-any.whl
| Download URL | demucs_torchcodec-0.2.0-py3-none-any.whl |
|---|---|
| Size | 66.1 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
8158835b511f8b569dcc4d643d14f02b7533ff1a8a9634bd0c4146751777b471
|
|
BLAKE2b-256 checksum How to use checksums |
4d7f31f2fe3ec9742e009ddcf7a2b4d74c508d68681dc4c6d98ff32aa6e16422
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.13.15
|
Security for demucs-torchcodec 0.2.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.