Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

# Doubt regarding the Hamiltonian calculations for RHVAE model.

See original GitHub issue

In the paper, Hamiltonian is defined as follows:

``````H(z, v) = U(z) + K(v)  = -0.5*log(det(G^-1(z)) + 0.5*v^T*v
``````

But in the code, I see extra terms like addition of a joint probability term and a G inverse multiplied in the term for kinetic energy. Are these 2 equations equivalent?

### Issue Analytics

• State:
• Created 2 years ago

1reaction

You’re welcome 😃. Not really, you can down-sample a bit your input data to deal with memory issues for instance but, in theory, the VAE can handle any kind of data regardless of the dimension. If you are referring to the paper, we only down-sampled the data by a factor 2 in each dimension when dealing with 3D MRIs.

1reaction
shikhar2333commented, Feb 11, 2022

So are M and G equivalent, since M is also defined as LL^T.

#### Top Results From Across the Web

A Geometric Perspective on Variational Autoencoders
In this paper, we propose a geometrical interpretation of the Variational Autoencoder framework. We show that VAEs naturally unveil a Riemannian structure ...
Hamiltonian Cycle -- from Wolfram MathWorld
A Hamiltonian cycle of a graph can be computed efficiently in the Wolfram ... Golovko (1972) gave a formula giving the number of...
Hamiltonian path - Wikipedia
In the mathematical field of graph theory, a Hamiltonian path (or traceable path) is a path in an undirected or directed graph that...
Benchmark VAE - Library for Variational Autoencoder ...
Doubt regarding the Hamiltonian calculations for RHVAE model. In the paper, Hamiltonian is defined as follows:

#### Troubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free