Profile

Settings

Loading…

← Papers

Help

FAQ

Which features require signing in?

You can read the commentary, paper info, Model Structure and related papers of public papers without signing in. Sign in to manage your account or contact us about your inquiries.

Can I upload a PDF file?

Upload papers with an arXiv or DOI link; the commentary is public to everyone. Papers whose source and terms of use can't be verified, so the commentary can't be made public, can't be uploaded. Uploading PDF files and keeping papers private are for subscribers only, and a paper uploaded as a file is saved as private only. Searching for official info by title runs only when you press the button.

Are the figures and AI commentary accurate?

Figures come only from the original paper, and only those whose terms of use are verified are shown. The commentary is written by AI and may be wrong. Check important claims, numbers and figure context against the evidence in the original paper.

I want to report a copyright issue.

Terms of use and the source of the original paper are on the Paper info tab. If there's a problem, choose "Paper content, figures and copyright" under Contact us and send the paper link, the part in question, and evidence that you hold the rights. Receiving your report doesn't confirm any rights or remove anything right away. You can see the result of the review under My inquiries.

I forgot my password.

If you signed up with email, use Forgot password in the sign-in window to reset it with your verified email. If you signed up with Google, Naver or Kakao, change your password with that service.

What should I include in an inquiry?

Tell us which screen you were on and what you were doing when the problem happened, along with the paper link. Don't include personal information such as passwords, API keys, verification codes or phone numbers. Inquiries and replies are stored in Refivu and you can see them under My inquiries.

How do I delete my account?

In Settings, under My account, press Delete account. Review what will be deleted and complete identity verification to delete your account. For other requests, choose "Account" under Contact us.

Paper commentary

Variational Inference: A Review for Statisticians

Variational inference turns hard Bayesian computation into optimization

  • Problem Computing the posterior is often intractable because the evidence integral has no closed form. MCMC sampling can be too slow when the data set is large.
  • Method The authors pick a family of densities and keep the member closest to the posterior. Closeness is measured by KL divergence, so inference becomes a search over the family's parameters.
  • Results On image color histograms, CAVI fit a thirty-cluster Gaussian mixture to ten thousand images, running much faster than Hamiltonian Monte Carlo.

Why exact posterior inference stalls

Bayesian inference comes down to computing the posterior, which is the joint density divided by the evidence. The evidence is an integral over all latent variables, and for many models it has no closed form. Modern Bayesian models often sit exactly in this regime, where the posterior is not easy to compute.

In the Bayesian mixture of Gaussians, each mean appears in every factor of the integrand, so the integral does not split into simple pieces. Numerically evaluating it costs O(K^n) time, and summing over all cluster configurations leaves K^n terms. So even a small model becomes intractable as the number of data points grows.

MCMC has long been the default answer, building a Markov chain whose stationary distribution is the posterior. That gap is why the authors look for an approach that turns inference into optimization instead of sampling.

Turning inference into optimization

The key idea is to choose a family Q of densities over the latent variables and keep the member closest to the posterior. Closeness is measured by KL divergence, so the approximation is the member q*(z) that minimizes KL(q(z) || p(z|x)) within Q. Once the family is fixed, inference becomes a search problem over its parameters.

The family has to be flexible enough to hold a density near the posterior, yet simple enough to optimize efficiently. Its complexity sets the complexity of the optimization, so the design choice is a trade-off between fidelity and cost. Both the choice of family and the optimizer decide how good the final approximation can be.

The KL objective can't be computed directly, because it contains the log evidence. Expanding the KL shows that minimizing it is the same as maximizing a quantity that drops the log evidence, since that term is constant in q. This quantity is the evidence lower bound, and it is what the optimization maximizes in practice.

Mean-field factors and the CAVI update

The mean-field family makes every latent variable independent, with its own factor q_j(z_j). In principle each factor can take any parametric form suited to its variable, such as a Gaussian for a continuous variable. The paper's mixture example uses Gaussian factors for the means and categorical factors for the assignments.

CAVI, the coordinate ascent algorithm, updates one factor at a time while holding the others fixed. Because of the independence built into the family, that expectation doesn't depend on q_j itself, so the update is valid.

The algorithm loops over the factors, applies this update to each, and recomputes the ELBO until it stops changing. Each full pass climbs the ELBO, so the procedure settles at a local optimum rather than a guaranteed global one. The same complete conditional appears in the Gibbs sampler, but CAVI uses its expected log instead of drawing samples from it.

Worked example: Bayesian mixture of Gaussians

The model uses K unit-variance Gaussian components whose means have a Gaussian prior with variance sigma squared. Each observation first draws a cluster assignment from a categorical distribution, then draws from the Gaussian of its cluster. The latent variables are the K means and the n cluster assignments, so the mixture is a natural test of the method.

The variational family gives each mean a Gaussian factor with its own mean and variance. Each observation gets a categorical factor over the K clusters, described by its assignment probabilities.

With the family in place, the ELBO follows from the model and the mean-field family. Optimization then adjusts the Gaussian parameters for each component and the categorical parameters for each assignment. The result is a fully specified inference procedure for the mixture.

Image histograms: CAVI against sampling

The experiment groups images by their color profiles, using histograms of the red, green and blue channels. Each channel histogram has 192 entries, so each image is a 576-dimensional vector regardless of its pixel size. The authors fit a Gaussian mixture with thirty clusters to ten thousand training images and test on ten thousand held-out images.

The baseline is a Hamiltonian Monte Carlo sampler implemented in Stan.

The authors caution that this is not a definitive comparison between VI and MCMC. A collapsed Gibbs sampler may do better than the Hamiltonian Monte Carlo baseline used here. So the result shows a speed gap against one sampler, not a general ranking of the two families.

Convergence is monitored with the average log predictive on a small held-out set instead of the full ELBO. Different random initializations led to different ELBO values, so the optimum found depends on the start. Better local optima give variational densities closer to the exact posterior in KL(q||p).

Exponential families and stochastic updates

When each complete conditional is in the exponential family, each optimal factor is in the same family. Its natural parameter is set to the expected natural parameter of the complete conditional. This makes CAVI updates easier to derive for many models.

In conditionally conjugate models, the global variables govern all the data and each local variable governs one data point. The local update sets each local parameter from the expectation under the global parameter. The global update then combines the local statistics from all data points with the prior parameters.

CAVI needs a full pass over the data at every iteration, which gets expensive as the data set grows. Stochastic variational inference instead subsamples one data point, computes its local parameters, and moves the global parameters toward a fresh estimate. A step size that decreases over time blends the new estimate into the running global parameters.

The update direction is a natural gradient, which accounts for the geometry of probability parameters. In exponential families it is the ordinary gradient premultiplied by the inverse covariance of the sufficient statistic. This is what makes the stochastic step a valid way to climb the ELBO.

Limits of the approach

Variational inference doesn't carry the asymptotic exactness guarantees that MCMC provides. It can only find a density close to the target, not the target itself. The gap is harder to judge because statistical theory for variational inference is still thin.

The objective tends to underestimate the posterior variance, which the authors attribute to its form. In the two-dimensional Gaussian example, the mean-field approximation keeps the mean but decouples the covariance and shrinks the marginal variances. Whether that matters depends on the task, and the authors note that the variance may be acceptable in some uses.

The ELBO is generally non-convex, so CAVI only guarantees a local optimum that depends on initialization. Ten random initializations of CAVI for the Gaussian mixture reached different ELBO values, indicating many local optima. Structured and mixture-based families can improve fidelity, but they make the optimization harder.

Paper info

Authors
David M. Blei, Alp Kucukelbir, Jon D. McAuliffe
Venue
arXiv · Preprint
First published
2016-1-4
Added
2026-11-12
Updated
2018-5-9
Version
v9
arXiv
1601.00670
DOI
10.1080/01621459.2017.1285773
Category
stat.CO · cs.LG · stat.ML
Original paper terms
arXiv non-exclusive 1.0
What we show
Paper info and commentary

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

Quote from the paper

David M. Blei, Alp Kucukelbir, Jon D. McAuliffe (2016). Variational Inference: A Review for Statisticians. arXiv:1601.00670v9. https://doi.org/10.1080/01621459.2017.1285773

BibTeX
@article{blei2016variational,
  title = {{Variational Inference: A Review for Statisticians}},
  author = {David M. Blei and Alp Kucukelbir and Jon D. McAuliffe},
  year = {2016},
  eprint = {1601.00670},
  archivePrefix = {arXiv},
  doi = {10.1080/01621459.2017.1285773},
  url = {https://arxiv.org/abs/1601.00670v9}
}

See related papersBrowse other papers

Paper preview
Account security

Connect Google account

If you connect a Google account, you can sign in with it too.

Refivu

Delete account

Refivu
Refivu

Sign up