pytorch/examples

VAE reconstruction loss (BCE)

Open

#460 aberto em 1 de dez. de 2018

Ver no GitHub
 (2 comments) (3 reactions) (0 assignees)Python (9.429 forks)batch import
good first issue

Métricas do repositório

Stars
 (21.634 stars)
Métricas de merge de PR
 (Nenhuma PRs mesclada em 30d)

Description

The current implementation uses

F.binary_cross_entropy(recon_x, x.view(-1, 784), reduction='sum')

as the reconstruction loss. The image x has pixel values in [0,1]. This is not the same as Bernoulli log likelihood. The images would have to binarized.

In Ladder Variational Autoencoders by Sonderby et al, they binarize the images as a Bernoulli sample after each epoch.

Guia do colaborador