Implicit Density Estimation by Local Moment Matching to Sample from Auto-Encoders

Yoshua Bengio, Guillaume Alain, Salah RifaiarXiv 2012

Abstract

Traditionally, auto-encoders were viewed primarily as tools for feature extraction and dimensionality reduction, lacking the rigorous probabilistic foundations of generative models like Restricted Boltzmann Machines (RBMs). This paper establishes a formal mathematical bridge between these two paradigms. By introducing the framework of "Local Moment Matching," the authors demonstrate that Contractive and Denoising Auto-Encoders implicitly perform density estimation. This theoretical insight allows for the derivation of a Markov Chain Monte Carlo (MCMC) sampling algorithm, enabling auto-encoders to function as generative models without the need for an explicit partition function.

Introduction

In the landscape of unsupervised learning circa 2012, a clear divide existed. Models like RBMs were explicitly designed to capture probability densities but suffered from computational intractability due to the partition function. Conversely, Auto-Encoders (AEs)—specifically Denoising (DAE) and Contractive (CAE) variants—showed remarkable empirical success in learning representations and even generating samples, yet they lacked a formal probabilistic justification.

This research addresses the fundamental question: What are these auto-encoders actually learning about the underlying data distribution? The authors propose that instead of modeling the global density directly, these models learn the local geometric properties—the local moments—of the data manifold.

Theoretical Framework: Local Moment Matching

The core contribution of the paper is the "Local Moment Matching" framework. Rather than maximizing the global likelihood of the dataset, the model focuses on the local neighborhood of a point $x$.

The Reconstruction Function as a Vector Field

The authors prove that the reconstruction function $r(x)$ of a trained auto-encoder acts as a vector field. Specifically, the difference $r(x) - x$ points toward the nearest high-density region on the data manifold. In the non-parametric limit (infinite data and capacity), $r(x)$ corresponds to the local mean of the density.

The Jacobian and Manifold Geometry

Beyond the mean, the model captures the local covariance structure through the Jacobian matrix of the reconstruction function. The Jacobian identifies the tangent plane of the data manifold, distinguishing between "flat" directions (moving along the data) and "steep" directions (moving away from the data). This allows the model to understand the local dimensionality and orientation of the data distribution.

Unifying DAEs and CAEs

A significant theoretical result of this work is the unification of two popular architectures. The authors demonstrate that a Denoising Auto-Encoder trained with small Gaussian noise is mathematically equivalent to a Contractive Auto-Encoder. This suggests that both regularization techniques—adding noise to inputs or penalizing the Frobenius norm of the Jacobian—lead the model to perform the same underlying task: estimating local moments to capture the data manifold.

Generative Sampling via MCMC

By treating the auto-encoder as an estimator of local moments, the authors justify a simple yet effective MCMC algorithm for sampling:

  1. Step: Given a current point $x_t$, the next point $x_{t+1}$ is sampled from a Gaussian distribution.
  2. Mean: The mean of this Gaussian is the reconstruction $r(x_t)$.
  3. Covariance: The variance is determined by the local covariance structure derived from the model's parameters.

This approach bypasses the need for a partition function entirely, as the density is defined implicitly through the transition operator of the Markov Chain.

Experimental Validation

The theory was validated using two benchmark datasets:

  • MNIST: The model successfully generated realistic handwritten digits, confirming that the MCMC chain could navigate the manifold of digit shapes.
  • Toronto Face Dataset (TFD): The model captured the complex, high-dimensional manifold of human faces, producing plausible synthetic images.

Key Insights and Implications

  • Implicit Density: The paper proves that a model does not need an explicit probability density function to be a valid generative model; a consistent transition operator is sufficient.
  • Geometric Interpretation: Auto-encoders are shown to be "manifold learners" in a very literal sense, using the Jacobian to map the local geometry of the data.
  • Non-parametric Consistency: The authors provide a proof of consistency, showing that with sufficient capacity, these models perfectly recover the target density's local moments.

Limitations and Future Directions

While the paper provides a robust foundation, it notes certain practical constraints. The mathematical proofs often rely on the "tiny step" assumption (infinitesimal noise/steps), whereas practical implementations use larger steps for efficiency. Additionally, the transition from the non-parametric theoretical ideal to fixed-capacity neural networks remains an area for further refinement. Finally, the authors observed that sampling in the latent (hidden) space often yields superior results, a phenomenon that warrants further mathematical exploration.

Summary updated

BibTeX
@misc{bengio2012implicit,
  author = {Yoshua Bengio and Guillaume Alain and Salah Rifai},
  title = {{Implicit Density Estimation by Local Moment Matching to Sample from Auto-Encoders}},
  year = {2012},
  eprint = {1207.0057},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1207.0057},
}
Figure