Skip to content

Variational Autoencoder (VAE), Evidence Lower Bound (ELBO) Implementation (PyTorch)

Notifications You must be signed in to change notification settings

drawcodeboy/VAE

Repository files navigation

VAE Implementation with PyTorch

Description

  • Variational Autoencoder

Preview

(1) Reconstruction: Original > 10 > 20 > 30 > 100 (Epochs)

(2) Generation from random vector

$$ p_{\theta}(x\mid z), \ \ z \sim N(0, 1) $$

Setting

# Download
git clone https://github.com/drawcodeboy/VAE.git

# Virtual Environment
python venv -m .venv
.venv\Scripts\activate # Windows command

# Install packages
pip install -r requirements.txt

# !!when you train or inference, you should check config.yaml!!

# training
python train.py

# Inference (1) : Reconstruction
python infer.py --method=reconstruct --num=12 # Dataset sample num 

# Inference (2) : Generate
python infer.py --method=generate --num=1 # Figure save num

References

  1. VAE: Kingma, D. P. (2013). Auto-encoding variational bayes. arXiv preprint arXiv:1312.6114.

About

Variational Autoencoder (VAE), Evidence Lower Bound (ELBO) Implementation (PyTorch)

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages