Beta Process Non-negative Matrix Factorization with Stochastic Structured Mean-Field Variational Inference

Dawen Liang, Matthew D. HoffmanarXiv 2014

Abstract

The Beta process is the standard nonparametric Bayesian prior for latent factor models. In this paper, we derive a structured mean-field variational inference algorithm for a beta process non-negative matrix factorization (NMF) model with Poisson likelihood. Unlike the linear Gaussian model, which is well-studied in the nonparametric Bayesian literature, the NMF model with a beta process prior does not enjoy conjugacy. We leverage recently developed stochastic structured mean-field variational inference to relax the conjugacy constraint and restore the dependencies among the latent variables in the approximating variational distribution. Preliminary results on both synthetic and real examples demonstrate that the proposed inference algorithm can reasonably recover the hidden structure of the data.

Introduction

Non-negative Matrix Factorization (NMF) is a fundamental tool for analyzing non-negative data, such as audio spectra or count-based recommendation systems. A persistent challenge in standard NMF is the "model selection" problem: manually determining the optimal number of latent components ($K$). Selecting too few components results in a loss of detail, while selecting too many leads to overfitting.

Nonparametric Bayesian methods, specifically the Beta Process, address this by treating $K$ as potentially infinite and allowing the data to determine the number of active components. However, combining a Beta Process prior with a Poisson likelihood—which is ideal for NMF—creates a non-conjugate model. This lack of conjugacy makes traditional fast inference algorithms difficult to implement. Previous approaches often relied on Gaussian approximations that fail to respect the inherent non-negativity of the data.

Methodology

We propose a Truncated Beta Process NMF model that decomposes an input matrix $X$ into three distinct parts:

  1. $W$: The latent components (the dictionary).
  2. $H$: The activations (the magnitude of each component).
  3. $S$: A binary mask (indicating which components are active for a specific data point).

To overcome the inference challenges of this non-conjugate model, we employ Stochastic Structured Mean-Field (SSMF) inference. Standard mean-field variational inference assumes all latent variables are independent, which often leads to poor local optima because the mask ($S$) and activations ($H$) are naturally coupled. Our SSMF approach restores these vital dependencies by using a Collapsed Gibbs sampler for local, highly dependent variables (the mask and auxiliary variables) while utilizing a stochastic gradient approach for global variables ($W$ and $H$). This hybrid method combines the accuracy of Markov Chain Monte Carlo (MCMC) with the scalability of variational inference.

Experimental Setup

The model was evaluated on two primary datasets:

  • Synthetic Audio: A mixture of piano and clarinet notes generated via the ChucK synthesis language. This setup allows for the verification of the model's ability to recover known harmonic structures.
  • Real-World Audio (BSS): The MIREX $F_0$ estimation data, featuring a woodwind quintet (bassoon, clarinet, flute, horn, and oboe). The goal was Blind Source Separation (BSS)—isolating individual instruments from a single mixed track.

Results and Discussion

On synthetic data, the model successfully identified the harmonic patterns of the instruments and correctly activated them only during the appropriate time frames.

Extracted figure from page 5 of Beta Process Non-negative Matrix Factorization with Stochastic Structured Mean-Field Variational Inference

In the Blind Source Separation task using the woodwind quintet, SSMF performed competitively against a full Gibbs sampler, which serves as the accuracy benchmark. While the Gibbs sampler achieved higher scores, SSMF provided a significantly more scalable solution, completing the task in half the time.

Quantitative performance comparison on the woodwind quintet dataset, showing Source-to-Distortion Ratio (SDR), Source-to-Interferences Ratio (SIR), and Source-to-Artifacts Ratio (SAR).

Key Insights

  • Dependency Restoration: By using SSMF to link the mask $S$ and activation $H$, the algorithm avoids the local optima that plague naive mean-field methods.
  • Poisson Likelihood: Maintaining a Poisson likelihood ensures the model respects the non-negative nature of audio data, avoiding the "negative energy" artifacts common in Gaussian-based models.
  • Automatic Sparsity: The Beta Process effectively pruned the potential component space, identifying a relevant subset (e.g., $K=37$ for SSMF on real audio) without manual tuning.

Conclusion and Future Work

While the proposed SSMF algorithm demonstrates robust structure recovery, it remains sensitive to hyperparameters, particularly the interaction between the sparsity priors on $S$ and $H$. Future work will explore using degenerate delta functions for the mask to perform Maximum A Posteriori (MAP) estimation, potentially further simplifying the numerical optimization process and improving stability.

Summary updated

BibTeX
@misc{liang2014beta,
  author = {Dawen Liang and Matthew D. Hoffman},
  title = {{Beta Process Non-negative Matrix Factorization with Stochastic Structured Mean-Field Variational Inference}},
  year = {2014},
  eprint = {1411.1804},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1411.1804},
}
Figure