On the Theory of Variance Reduction for Stochastic Gradient Monte Carlo

Niladri S. Chatterji, Nicolas Flammarion, Yi-An Ma, Peter L. Bartlett, Michael I. Jordan

Abstract

We provide convergence guarantees in Wasserstein distance for a variety of variance-reduction methods: SAGA Langevin diffusion, SVRG Langevin diffusion and control-variate underdamped Langevin diffusion. We analyze these methods under a uniform set of assumptions on the log-posterior distribution, assuming it to be smooth, strongly convex and Hessian Lipschitz. This is achieved by a new proof technique combining ideas from finite-sum optimization and the analysis of sampling methods. Our sharp theoretical bounds allow us to identify regimes of interest where each method performs better than the others. Our theory is verified with experiments on real-world and synthetic datasets.

Introduction

In Bayesian machine learning, the central challenge often involves sampling from complex posterior distributions. While Langevin Markov Chain Monte Carlo (MCMC) methods provide a robust framework for this task, their scalability is limited by the need to compute the full gradient of the log-posterior over the entire dataset at every iteration. To address this, Stochastic Gradient Langevin Dynamics (SGLD) utilizes mini-batches to estimate gradients. However, this stochasticity introduces variance (noise) that can significantly slow convergence or necessitate extremely small step sizes.

While variance reduction (VR) techniques like SAGA and SVRG have revolutionized finite-sum optimization, their application to sampling has remained theoretically contentious. Previous analyses often relied on the unrealistic assumption that the gradient of the log-posterior is globally bounded. This paper provides a unified theoretical framework for variance-reduced Stochastic Gradient MCMC (SG-MCMC), establishing sharp convergence guarantees under realistic conditions.

Methods and Theoretical Framework

The authors analyze three primary variance-reduced sampling algorithms:

  1. SAGA-LD (SAGA Langevin Diffusion): This method incorporates the SAGA technique, which maintains a table of historical gradients for each data point to incrementally reduce estimator variance.
  2. SVRG-LD (SVRG Langevin Diffusion): This approach periodically computes a full-batch gradient to "anchor" mini-batch estimates, reducing noise between full passes.
  3. CV-ULD (Control-Variate Underdamped Langevin Diffusion): This method applies control variates to a second-order (underdamped) Langevin process. By modeling momentum, underdamped methods typically exhibit lower discretization error than standard overdamped Langevin dynamics.

A New Proof Technique

The core innovation of this work is a proof technique that adapts Lyapunov functions—traditionally used to track convergence in finite-sum optimization—to the analysis of sampling methods. This allows the authors to establish non-asymptotic convergence rates in the Wasserstein distance ($W_2$) under much weaker assumptions: the log-posteriors need only be smooth, strongly convex, and Hessian Lipschitz. This approach avoids the "bounded gradient" pitfall and provides a clearer picture of how variance reduction interacts with the diffusion process.

Key Insights: The Accuracy Divide

A primary contribution of this research is the identification of two distinct performance regimes based on the target accuracy ($\epsilon$):

  • The High-Accuracy Regime: When a high-fidelity estimate of the posterior is required (small $\epsilon$), variance-reduced methods are theoretically and empirically superior. For example, to reach a target accuracy of $\epsilon$, standard SGLD requires $\mathcal{ ilde{O}}(d/\epsilon^2)$ iterations, whereas SAGA-LD requires only $\mathcal{ ilde{O}}(N + \sqrt{d}/\epsilon)$ steps. As $\epsilon$ decreases, the efficiency of VR methods becomes increasingly apparent.
  • The Low-Accuracy Regime: For quick, low-fidelity estimates where the user intends to perform less than one full pass over the data, standard SGLD remains the better choice. This is because VR methods require at least one full gradient computation (initialization) before they can begin their accelerated convergence.

Empirical Validation

The authors tested their framework using both real-world and synthetic datasets:

  • Real-World Data: Using UCI datasets such as Heart ($N=100$), PIMA diabetes, and SUSY ($N=100,000$), the authors demonstrated that on smaller datasets where high accuracy is targeted, SAGA-LD and CV-ULD converge in significantly fewer passes than SGLD. On the massive SUSY dataset, SGLD was faster for low-accuracy targets, confirming the "accuracy divide."
  • Synthetic Data and the CLT: A critical finding emerged from a synthetic Log-Normal dataset designed to violate the Central Limit Theorem (CLT). Standard SGLD relies on the assumption that mini-batch noise is Gaussian; when faced with heavy-tailed data, SGLD failed to converge. In contrast, SAGA-LD and SVRG-LD remained robust, successfully converging by maintaining a gradient history that accounts for tail data over time.

Conclusion and Future Work

This work provides a rigorous theoretical foundation for variance reduction in SG-MCMC, proving that these methods are not just heuristic improvements but offer fundamental speedups in the high-accuracy regime. Furthermore, the combination of control variates with underdamped Langevin dynamics (CV-ULD) offers a quadratic improvement in accuracy dependence compared to overdamped methods.

Future research directions include extending this analysis to non-convex log-posteriors, such as those found in deep neural networks, and exploring the potential for "single-pass" variance reduction or accelerated gradient techniques in the sampling context. Establishing theoretical lower bounds for sampling remains an open and essential challenge to complement these upper bound guarantees.

Summary updated

BibTeX
@inproceedings{chatterji2018theory,
  author = {Niladri S. Chatterji and Nicolas Flammarion and Yi-An Ma and Peter L. Bartlett and Michael I. Jordan},
  title = {{On the Theory of Variance Reduction for Stochastic Gradient Monte Carlo}},
  booktitle = {International Conference on Machine Learning},
  year = {2018},
  url = {https://openreview.net/forum?id=ry-k1sZObB},
}
Figure