A variational autoencoder encodes each input as a distribution, then samples a latent code from it. Sampling blocks gradients, so the paper rewrites the sample as a deterministic function of the parameters plus independent noise.
Implement reparameterize(mu, logvar, eps), returning mu + exp(0.5 logvar) * eps.
logvar, not the variance, for numerical stability.The standard deviation is exp(0.5 * logvar). Scale the noise by it and add the mean.
No results yet
Run your code to check it against the examples, or submit to run every test.