Our Machine Learning in Linux series focuses on apps that make it easy to experiment with machine learning. All the apps covered in the series can be self-hosted.
DiffRhythm is billed as a blazingly fast and embarrassingly simple end-to-end full-length song generation with latent diffusion.
This is free and open source software written in Python.
Installation
We evaluated DiffRhythm using the Ubuntu 24.10 distro.
We recently reviewed Pinokio, a utility that aims to make installing AI apps a breeze. We tried installing DiffRhythm with Pinokio but it bailed out with the error:
ENOENT: no such file or directory, stat '/home/sde/pinokio/api/diffrhythm.git/{{input.event[0]}}'
Rather than investigating the issue we chose to proceed with a manual installation. Old-school is sometimes the best.
Clone the project’s GitHub repository with the command:
$ git clone https://github.com/ASLP-lab/DiffRhythm.git
Change into the newly created directory.
$ cd DiffRhythm
Install the environment. You may already have espeak-ng installed, but if not, install it:
$ sudo apt install espeak-ng
We’re going to use pip to install DiffRhythm’s dependencies. But to avoid polluting our system, we’ll use a conda environment.
$ conda create -n diffrhythm python=3.10
Activate the environment:
$ conda activate diffrhythm
Install the dependencies using pip inside our environment.
$ pip install -r requirements.txt
Everything appeared fine, but we got an error:
ImportError: /home/sde/anaconda3/envs/diffrhythm/bin/../lib/libstdc++.so.6: version `GLIBCXX_3.4.32' not found
which was fixed by installing the missing library:
$ conda install -c conda-forge libstdcxx-ng
Next page: Page 2 – In Operation and Summary
Pages in this article:
Page 1 – Introduction and Installation
Page 2 – In Operation and Summary