On audio enhancement via online non-negative matrix factorization

Andrew Sack, Wenzhao Jiang, Michael Perlmutter, Palina Salanevich, Deanna Needell

Abstract

Traditional Non-negative Matrix Factorization (NMF) for audio denoising is limited by high memory requirements and batch-processing latency. This paper introduces an Online NMF (ONMF) framework that processes audio spectrograms in incremental time-slice batches. This approach enables real-time streaming applications and significantly reduces memory overhead. Experimental results show that ONMF achieves superior signal-to-noise separation compared to standard batch NMF, particularly in Signal-to-Distortion Ratio (SDR) and Signal-to-Interference Ratio (SIR) metrics.

Introduction

Speech enhancement—the removal of background noise from audio—is a fundamental challenge in signal processing. Non-negative Matrix Factorization (NMF) has emerged as a powerful tool for this task, decomposing an audio spectrogram into a dictionary of recurring spectral patterns and an activation matrix. However, standard NMF requires the entire recording to be loaded into memory, creating a significant bottleneck for long recordings and precluding real-time use in devices like hearing aids or live broadcast systems. This work addresses these limitations by transitioning to an online learning framework.

Methodology

The proposed method leverages Online Non-negative Matrix Factorization (ONMF) to process audio data incrementally.

NMF Framework

In standard NMF, a non-negative spectrogram matrix $X$ is approximated as $X \approx WH$, where $W$ is the dictionary and $H$ is the code matrix. For denoising, pre-trained dictionaries for clean speech ($W_S$) and noise ($W_N$) are concatenated. The algorithm then estimates the activations to separate the signal from the noise.

Online Implementation

Unlike batch NMF, ONMF samples small "time-slice" batches of the spectrogram. For each batch at time $t$, the algorithm updates the activation codes $H_t$ and refines the dictionary $W$ using aggregation matrices $A_t$ and $B_t$. These aggregation matrices summarize historical data, allowing the model to learn from past segments without retaining the full raw data in RAM. A final masking step uses the ratio of estimated signal to noise to filter the original spectrogram, ensuring reconstruction fidelity.

Experimental Results

The performance of ONMF was evaluated against traditional NMF using clean speech mixed with both synthetic Gaussian white noise and real-world noise.

Comparison of denoising performance across different methods: (a) Original clean speech, (b) Noisy speech, (c) NMF-based denoising, and (d) ONMF-based denoising.

As shown in the spectrograms above, ONMF effectively recovers the spectral structure of the original speech. Quantitatively, ONMF demonstrated significant improvements over traditional methods:

  • White Noise: ONMF achieved an SDR of 22.70 dB and an SIR of 53.45 dB, compared to 19.43 dB and 31.42 dB for batch NMF.
  • Real-World Noise: ONMF maintained superior performance with an SDR of 10.41 dB and an SAR of 13.95 dB.

Discussion and Conclusion

A key insight of this work is that processing audio as a time-series allows the dictionary to better capture temporal features like phonemes. Furthermore, the non-negativity constraint ensures that the learned dictionary atoms represent physically meaningful audio features rather than abstract mathematical components. While both methods introduce some audible artifacts, ONMF provides a more scalable and efficient solution for modern audio processing needs. Future work will explore more sophisticated loss functions, such as Kullback-Leibler divergence, to further improve audio quality.

Summary updated

BibTeX
@inproceedings{sack2022audio,
  author = {Andrew Sack and Wenzhao Jiang and Michael Perlmutter and Palina Salanevich and Deanna Needell},
  title = {{On audio enhancement via online non-negative matrix factorization}},
  booktitle = {CISS},
  year = {2022},
  doi = {10.1109/ciss53076.2022.9751157},
}
Figure