变分编码器
This is a tensorflow VAE implementation on MNIST data set, containing three networks:
- Basic VAE: generate digit images from random noise, could also use to remove noise or occlusion removal
- Conditional VAE to generate digits CVAE: generate digit images from certain label.
- Conditional VAE to remove occlusion CVAE_occlusion: has special decoder part to remove Image occlusion.
For example, random digits generated:
Following is generated images for number 3:
For example:
original:
occluded:
infered:
(has inferred shape in the occluded area)
But it generally works not so good, using Basic VAE could even perform better, I need to experiment more on the network.
In each network dir, there is for example VAE/results/save dir. This is the saved tensorflow model, copy it to VAE, and run python test_generation.py
. You will get generated images in VAE/save. The other two networks are similarly used.