Pytorch implementation of DCGAN, CDCGAN, LSGAN, WGAN and WGAN-GP for CelebA dataset.
1. Download the CelebA dataset, and aligned version is used in this repo.
$ git clone https://github.com/AndrewZhuZJU/Pytorch_GAN_CelebA.git
$ cd Pytorch_GAN_CelebA
To train any GAN please use main_**.py
. For example,
$ python main_DCGAN.py
Not that all the setting parameters for the modesl are in args.py
, please change properly.
DCGAN | LSGAN | CGAN(Up:Male, Bottom:Female) |
WGAN | WGAN-GP | |
DCGAN | LSGAN | CGAN(Up:Male, Bottom:Female) |
WGAN | WGAN-GP | |
- Inception score calculated in Epoch 40 (30K generated images)
DCGAN | LSGAN | WGAN | WGAN-GP |
2.10 |
2.08 |
2.20 |
1.97 |
- Inception score calculated in Epoch 20 (30K generated images)
DCGAN | LSGAN | WGAN | WGAN-GP |
2.07 |
1.95 |
2.05 |
2.00 |
Take DCGAN for example:
Generator Loss |
Discriminator Loss |
- Ubuntu 16.04 LTS
- NVIDIA GTX 1080 Ti
- CUDA 9.0
- pytorch 0.4
- python 2.7
- Others Dependencies: numpy, imageio, torchvision, tensorboard, etc.
1.Unsupervised Representation Learning with Deep Convolutional Generative Adversarial Networks
2.Conditional Generative Adversarial Nets