STA663 Class Project - Variational Auto-encoder
This repo contains final project of Duke STA663. A variational auto-encoder is implemented in this project. Our work includes:
- An implementation of Variational Auto-encoder using Tensorflow
- Using CPU parallel to optimize the code
- Discussion about using Numba and Cython for bottleneck in vae
- Comparison of two other frameworks: Auto-encoder and Generative Adversarial Nets
For demonstration purpose, we use MNIST Dataset to test our autoencoder.
Installation
Install Conda
It's hard to install Tensorflow in different OS, we highly recommend using Anaconda To install Anaconda, see instructions here
Pull Git Repo
git clone https://github.com/qingshuimonk/STA663.git
Install Conda Environment
cd STA663
conda env create
source activate vae-env (activate vae-env if using Windows)
Install Tensorflow Via Conda
conda install -c conda-forge tensorflow=1.0.0
Install Package
python setup.py install
Run Demo
Run an Variational Autoencoder that generate synthetic data from MNIST Dataset
python demo_vae.py
If you ran into a 'PyQt4' issue with matplotlib when running this, try uncomment line 7 in demo_vae.py:
matplotlib.use('PS')
Other Demos
- Implementation of VAE & Unit Tests
- Using CPU parallel to optimize the code 1, 2
- Optimize bottleneck using Numba and Cython
- A demo of using Auto-encoder
- A demo of using GAN
TO-DO
- Make code files for Variational Autoencoder
- Optimize reconstruct function
- Compare running time for raw vae and optimized vae
- Compare with other algorithms
- Wrap up codes
- Write Report