Vanilla VAE Frey face generator.
Take pytorch samples in https://github.com/pytorch/examples and adapt the VAE example to learn the frey face manifold Code is the same except for additional hacks to process data, plotting and writing the generator
Heavily inspired by this version for Keras by Elvis Dohmatob: http://dohmatob.github.io/research/2016/10/22/VAE.html
Some notes are in my wordpress blog. https://pravn.wordpress.com/2017/06/04/the-objective-function-in-the-variational-autoencoder/