gitmyhub

rnnoise

C ★ 5.7k updated 1y ago

Recurrent neural network for audio noise reduction

A C library that removes background noise from audio in real time by combining traditional signal processing with a small neural network. Designed to be embedded inside other audio software.

CPythonsetup: hardcomplexity 4/5

RNNoise is a software library that removes background noise from audio in real time. If you have ever been on a call where keyboard clicks, room echo, or ambient sound leaked through, noise suppression is the process that cleans that up. RNNoise does this by combining traditional audio signal processing with a small neural network, which is a type of machine learning model trained on examples of speech and noise.

The library is written in C and is meant to be embedded inside other audio software. A command-line demo tool is included so you can test it directly: you feed it a raw audio file with noise and it outputs a cleaned version. The format it expects is 16-bit mono audio sampled at 48 kHz, in raw PCM format rather than the more common WAV format, which is something to be aware of if you try to use it.

For people who want to train their own noise suppression model rather than use the default one, the README walks through the full process. You need two sets of audio data: clean speech recordings and noise recordings. The training code mixes them together to simulate real-world conditions, extracts features, then runs the model training with Python. The result is a set of model weight files that you convert back into C source files and build into the library. The README notes that exact results vary depending on how much data you use and how long training runs.

The project comes from Xiph.Org, an open-source multimedia organization. The primary source repository is hosted on their own GitLab server; the GitHub copy is provided for convenience. An interactive online demo of an earlier version is available on the author's website if you want to hear the effect without building anything.

Where it fits