AntixK / PyTorch-VAE

A Collection of Variational Autoencoders (VAE) in PyTorch.
Apache License 2.0
6.44k stars 1.05k forks source link

Question about whether to sample #62

Open ShellingFord221 opened 2 years ago

ShellingFord221 commented 2 years ago

Hi, I have two questions about VAE. Firstly, when training a VAE, we should sample from N(\mu, \sigma^2) to approximate the latent distribution. Should MSE be the average over these samples? Secondly, when testing a VAE, should we also sample from the distribution or just use \mu to get generated picture? Thanks!