A collection of Variational AutoEncoders (VAEs) implemented in pytorch with focus on reproducibility. The aim of this project is to provide a quick and simple working example for many of the cool VAE models out there. All the models are trained on the CelebA dataset for consistency and comparison.
- Python >= 3.5
- PyTorch >= 1.3
- Pytorch Lightning >= 0.6.0 (GitHub Repo)
- CUDA enabled computing device
$ git clone https://github.com/GauthierEd/DeepLearningProject.git
$ cd DeepLearningProject
$ pip install -r requirements.txt
$ cd DeepLearningProject
$ python run.py -c configs/<config-file-name.yaml>
Config file template
model:
load: false
path: "<path to the model save>"
model_params:
name: "<name of VAE model>"
in_channels: 3
latent_dim:
. # Other parameters required by the model
.
.
data_params:
data_path: "<path to the celebA dataset>"
train_batch_size: 64 # Better to have a square number
val_batch_size: 64
patch_size: 64 # Models are designed to work for this size
num_workers: 4
exp_params:
manual_seed: 1265
LR: 0.005
weight_decay:
. # Other arguments required for training, like scheduler etc.
.
.
trainer_params:
gpus: 1
max_epochs: 100
gradient_clip_val: 1.5
.
.
.
logging_params:
save_dir: "logs/"
name: "<experiment name>"
View TensorBoard Logs
$ cd logs/<experiment name>/version_<the version you want>
$ tensorboard --logdir .
Apache License 2.0
Permissions | Limitations | Conditions |
---|---|---|
✔️ Commercial use | ❌ Trademark use | ⓘ License and copyright notice |
✔️ Modification | ❌ Liability | ⓘ State changes |
✔️ Distribution | ❌ Warranty | |
✔️ Patent use | ||
✔️ Private use |
@misc{Subramanian2020,
author = {Subramanian, A.K},
title = {PyTorch-VAE},
year = {2020},
publisher = {GitHub},
journal = {GitHub repository},
howpublished = {\url{https://github.com/AntixK/PyTorch-VAE}}
}