Giter Site home page Giter Site logo

distributed-music-processor's Introduction

CD 2023 Project

Here we have a sample code that loads one mp3 file and splits it into 4 tracks: vocals, drums, bass and other.

The codes uses one library named demucs, this library uses a deep learning model to separate the tracks. This library requires ffmpeg to work. It should be present in most Linux distributions.

Dependencies

For Ubuntu (and other debian based linux), run the following commands:

sudo apt install ffmpeg

Setup

Run the following commands to setup the environement:

mkdir tracks

python3 -m venv venv
source venv/bin/activate

pip install pip --upgrade
pip install -r requirements_torch.txt
pip install -r requirements_demucs.txt

It is important to install the requirements following the previous instructions. By default, PyTorch will install the CUDA version of the library (over 4G simple from the virtual environment). As such, the current instructions force the installation of the CPU version of PyTorch and then installs Demucs.

Usage

The sample main code only requires two parameters:

  • i the mp3 file used for input
  • o the folder for the output

Two audio tracks are given (download them from here):

  • test.mp3 a short sample (0:34) that allows for a quick validation
  • mudic.mp3 a long (59:04) sequence of royalty free rock musics that are the target of the work

Both audio files are royalty free.

To run test the sample code simple run:

python main.py -i test.mp3

Authors

License

This project is licensed under the MIT License - see the LICENSE file for details.

distributed-music-processor's People

Contributors

davidjosearaujo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.