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

Stochastic Backpropagation and Approximate Inference in Deep Generative Models

Stochastic backpropagation lets deep generative models be trained with scalable approximate inference

  • Problem Deep directed generative models are easy to sample from but hard to fit, because the latent variables behind each observation need inference. Existing methods were slow or relied on approximations that fared poorly here.
  • Method Stochastic backpropagation trains a recognition model that acts as a stochastic encoder of the data. Gradient rules pass through random latent samples, so the generative and recognition parameters are optimised jointly.
  • Results The model generates realistic samples, gives accurate imputations of missing data, and works as a tool for high-dimensional visualisation on several real-world datasets.

Why inference in deep directed models stalls

Directed generative models are attractive because sampling is simple: one draws from the top of the hierarchy and passes the draws downward. Fitting them is the hard part, because the latent variables behind each observation must be inferred, and efficient algorithms for that have mostly been missing. The authors list mean-field variational EM, the wake-sleep algorithm and control-variate based stochastic variational methods as the existing answers.

Deterministic approximations fare poorly here: the authors note that the Laplace approximation is generally poor and expensive, and that INLA only fits models with fewer than 10 hyperparameters, while they need hundreds to thousands.

The authors therefore want gradient estimates that remain unbiased when only a small number of samples is drawn.

A deep Gaussian generator

The key idea is to stack latent layers, each a nonlinear map of the layer above plus fresh Gaussian noise, and to read the data off the bottom layer. Sampling starts from a Gaussian at the top, \( h_L = G_L\xi_L \), and each lower layer then takes \( h_l = T_l(h_{l+1}) + G_l\xi_l \). The bottom activation \( h_1 \) sets the parameters of the observation distribution through \( v \sim \pi(v \mid T_0(h_1)) \), so the likelihood family is a free choice.

The maps \( T_l \) are multi-layer perceptrons, and the matrices \( G_l \) scale and mix the noise in each layer.

Equation (6) gives an equivalent view: a complex nonlinear transform applied to a spherical Gaussian \( p(\xi)=\prod_l \mathcal N(\xi_l|0,I) \), trained so that the transformed distribution matches the data. The generative parameters \( \theta_g \) collect the maps \( T_l \) and the matrices \( G_l \), under a weak Gaussian prior \( p(\theta_g)=\mathcal N(\theta|0,\kappa I) \).

Special cases show the reach of the family: one layer with a linear map gives factor analysis, and element-wise nonlinearities give a non-linear Gaussian belief network.

Bounding the marginal likelihood with a recognition model

The marginal likelihood integrates out every latent variable, and that integral is intractable in general. The authors instead introduce an approximate posterior \( q(\xi) \) and apply Jensen's inequality, which gives \( \mathcal L(V) \le \mathcal F(V) \) for the negative log marginal likelihood \( \mathcal L(V) \). The bound is \( \mathcal F(V)=D_{KL}[q(\xi)\|p(\xi)] - E_q[\log p(V|\xi,\theta_g)p(\theta_g)] \), a KL regulariser toward the prior plus a reconstruction term.

The recognition model \( q(\xi|V,\theta_r) \) is Gaussian for each data point and each layer, with means and covariances produced by deep networks. Because one shared network serves every data point, a single forward pass gives the approximate posterior for a new observation, instead of an iterative inference run. The authors add bit-flip or dropout noise at the input and small Gaussian noise on the recognition samples, and they report that without this regularisation the model gives inaccurate inferences for unseen points.

This keeps the regulariser cheap, so the remaining cost is the reconstruction expectation, which the authors estimate with Monte Carlo samples.

Gradients through Gaussian samples

The first route uses Gaussian gradient identities: the gradient of a Gaussian expectation with respect to the mean equals the expectation of the gradient of the integrand. For the covariance, the gradient is one half times the expectation of the Hessian of the integrand, which is the result the authors attribute to Price. The authors therefore use an unbiased estimator with quadratic cost, which has higher variance.

The second route is a change of coordinates: any Gaussian can be written as \( \mu + R\epsilon \) with \( C = RR^\top \) and \( \epsilon \sim \mathcal N(0,I) \). The gradient with respect to \( R \) is then \( E_{\mathcal N(0,I)}[\epsilon g^\top] \), where \( g \) is the gradient of the integrand at the transformed point. The authors offer this as a lower-cost alternative to Price's theorem, and they use it for the factor matrix instead of the covariance.

The recognition gradients come from the mean gradient (15) and the factor gradient (16), and equation (17) chains them into the recognition parameters. The generative gradient (14) uses the same samples, so both sets of parameters are updated from one set of draws. Opper and Archambeau and later Graves had already used these Gaussian identities, while Kingma and Welling presented a related view at the same time.

Diagonal versus rank-one covariance

A diagonal covariance is linear to compute, but its posteriors can only be axis-aligned.

The log-determinant is \( \log|C| = \log\eta - \log|D| \), so the trace and log-determinant needed for the KL term are linear in K. The factor \( R \) with \( C = RR^\top \) can be applied to a vector without being formed, so sampling stays linear as well.

Each training iteration runs a bottom-up pass that samples the recognition model, then a top-down pass that computes the generative activations. A backward pass then computes gradients with the matching rules, and the parameters move by a step \( \Delta\theta = -\Gamma\nabla F \) with a diagonal preconditioner from RMSprop.

Binarised MNIST likelihood comparison

The main number here is the test negative log-probability on binarised MNIST, where lower values are better. Within this table the deep Gaussian models sit well below Factor Analysis and the wake-sleep row, although the table mixes several training methods.

The rank-one covariance is the better of the two DLGM rows, so the correlation direction helps the likelihood in this experiment. The authors therefore call their approach competitive with some of the best models, rather than the best one.

Testing the recognition model against the true posterior

The authors fit a model with two Gaussian latent variables on MNIST and compute the true posterior by importance sampling on a grid from -5 to 5. The true posteriors look elliptical or spherical, which the authors take as a sign that a Gaussian approximation is reasonable. Samples from the prior are spread widely, so very few land where the posterior has mass, which explains why prior-based estimators are inefficient.

Samples from the recognition model concentrate on the posterior mass, which the authors read as learning the right posterior statistics. With the diagonal covariance these samples stay aligned to the axes and miss the posterior correlation. The rank-one covariance captures that correlation, and the authors note that not every posterior is Gaussian, so the recognition model places mass where it can.

The performance panel uses the same architecture for Factor Analysis, the wake-sleep algorithm and both DLGM variants, with 100 latent variables feeding a deterministic layer of 300 nodes. The text gives this comparison only as a figure, so it reports no numbers for the panel.

Samples, visualisation and imputation

The three-layer MNIST model has two deterministic layers of 200 hidden units and a stochastic layer of 200 latent variables, trained with mini-batches of 200 observations.

For NORB, the model uses one deterministic layer of 400 hidden units and a stochastic layer of 100 latent variables on 24,300 images of 96×96 pixels. CIFAR10 gives 50,000 RGB images of 32×32 pixels, which the authors cut into random 8×8 patches and model with the MNIST architecture. The Frey faces set has almost 2,000 images of size 28×20 pixels, and these samples are shown beside training data with no numeric score in the text.

For visualisation, MNIST is projected to a two-dimensional latent space, and the classes fall into different regions. The authors read this as a sign that such embeddings help show the structure of high-dimensional data.

The imputation test uses SVHN with 73,257 images of 32×32 pixels, along with Frey faces and MNIST. Two missingness types are tested: missing-at-random with 60% and 80% of pixels removed, and not-missing-at-random with a square region removed. Missing pixels are refilled by repeated resampling, and the imputations are shown over 15 iterations.

The authors do not integrate over the missing values, and they argue that the resampling chain converges to the true marginal. They call the completions very good, and the flips from digit 9 to 7 and from 8 to 6 reflect real uncertainty about the identity of the image.

How the gradient estimator and alternatives compare

The REINFORCE algorithm is simple and applies to discrete and continuous models, but its variance grows with the number of random variables. The authors argue that its variance scales as O(K), while the variance of Gaussian Backpropagation stays bounded at O(1). This is the authors' argument from scaling in the number of independent random variables, and the main text reports no experiment that measures gradient variance.

The wake-sleep algorithm can perform well, but the authors say it fails to optimise one consistent objective. So optimising it isn't guaranteed to lower the free energy, which is the bound the DLGM training uses.

Denoising auto-encoders corrupt their input and minimise the expected reconstruction error, and the authors read the recognition model as a stochastic encoder of that kind. The difference, they argue, is that their corruption and regularisation follow from the variational bound on a known directed model, which gives a strict bound and easy sampling.

Limitations

The authors state that NADE can't easily take deep representations or locally connected layers such as convolutions, which they see as limiting its scaling to high-dimensional data. The NADE comparison relies on numbers quoted from Uria et al. (2014), not on a controlled run by the authors.

The posterior covariance comparison is done only in a model with two latent variables. The NORB, CIFAR10 and Frey samples come with no numeric score, and the imputation completions are called very good without a metric in the text.

The text describes a covariance option that spans all layers jointly, but it reports no experiment with that option. The regularisation is presented as essential, and the text gives no experiment that isolates how much each noise source contributes.

Paper info

Authors
Danilo Jimenez Rezende, Shakir Mohamed, Daan Wierstra
Venue
arXiv · Preprint
First published
2014-1-16
Added
2026-11-6
Updated
2014-5-30
Version
v3
arXiv
1401.4082
Category
stat.ML · cs.AI · cs.LG · stat.CO · stat.ME
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

Danilo Jimenez Rezende, Shakir Mohamed, Daan Wierstra (2014). Stochastic Backpropagation and Approximate Inference in Deep Generative Models. arXiv:1401.4082v3. https://arxiv.org/abs/1401.4082v3

BibTeX
@misc{rezende2014stochastic,
  title = {{Stochastic Backpropagation and Approximate Inference in Deep Generative Models}},
  author = {Danilo Jimenez Rezende and Shakir Mohamed and Daan Wierstra},
  year = {2014},
  eprint = {1401.4082},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/1401.4082v3}
}

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