Flawless1202 / VGAE_pyG

An VGAE implementation using pytorch geometric.
43 stars 3 forks source link

KL loss Query #1

Open Yumlembam opened 3 years ago

Yumlembam commented 3 years ago

Can you please reply what is kl loss kl_loss = 1 / x.size(0) * self.kl_loss() in the loss function. It will be very helpful.

TommyGiak commented 1 year ago

It is the Kullback–Leibler divergence between the z distribution and a standard Normal distribution. For more details look at this: https://towardsdatascience.com/understanding-variational-autoencoders-vaes-f70510919f73