tensorflow-generative-model-collections
Tensorflow implementation of various GANs and VAEs.
Pytorch version of this repository is availabel at https://github.com/znxlwm/pytorch-generative-model-collections
https://github.com/google/compare_gan is the code that was used in the paper.
It provides IS/FID and rich experimental results for all gan-variants.
Network architecture of generator and discriminator is the exaclty sames as in infoGAN paper.
For fair comparison of core ideas in all gan variants, all
implementations for network architecture are kept same except EBGAN and
BEGAN. Small modification is made for EBGAN/BEGAN, since those adopt
auto-encoder strucutre for discriminator. But I tried to keep the
capacity of discirminator.
The following results can be reproduced with command:
python main.py --dataset mnist --gan_type <TYPE> --epoch 25 --batch_size 64
All results are randomly sampled.
Each row has the same noise vector and each column has the same label condition.
Comments on network architecture in mnist are also applied to here.
Fashion-mnist
is a recently proposed dataset consisting of a training set of 60,000
examples and a test set of 10,000 examples. Each example is a 28x28
grayscale image, associated with a label from 10 classes. (T-shirt/top,
Trouser, Pullover, Dress, Coat, Sandal, Shirt, Sneaker, Bag, Ankle boot)
The following results can be reproduced with command:
python main.py --dataset fashion-mnist --gan_type <TYPE> --epoch 40 --batch_size 64
All results are randomly sampled.
Each row has the same noise vector and each column has the same label condition.
Without hyper-parameter tuning from mnist-version, ACGAN/infoGAN does not work well as compared with CGAN.
ACGAN tends to fall into mode-collapse.
infoGAN tends to ignore noise-vector. It results in that various style within the same class can not be represented.
(to be added)
Network architecture of decoder(generator) and encoder(discriminator) is the exaclty sames as in infoGAN paper. The number of output nodes in encoder is different. (2x z_dim for VAE, 1 for GAN)
The following results can be reproduced with command:
python main.py --dataset mnist --gan_type <TYPE> --epoch 25 --batch_size 64
All results are randomly sampled.
Results of GAN is also given to compare images generated from VAE and GAN. The main difference (VAE generates smooth and blurry images, otherwise GAN generates sharp and artifact images) is cleary observed from the results.
Each row has the same noise vector and each column has the same label condition.
Results of CGAN is also given to compare images generated from CVAE and CGAN.
The following results can be reproduced with command:
python main.py --dataset mnist --gan_type VAE --epoch 25 --batch_size 64 --dim_z 2
Please notice that dimension of noise-vector z is 2.
Comments on network architecture in mnist are also applied to here.
The following results can be reproduced with command:
python main.py --dataset fashion-mnist --gan_type <TYPE> --epoch 40 --batch_size 64
All results are randomly sampled.
Results of GAN is also given to compare images generated from VAE and GAN.
Each row has the same noise vector and each column has the same label condition.
Results of CGAN is also given to compare images generated from CVAE and CGAN.
The following results can be reproduced with command:
python main.py --dataset fashion-mnist --gan_type VAE --epoch 25 --batch_size 64 --dim_z 2
Please notice that dimension of noise-vector z is 2.
(to be added)
The following shows basic folder structure.
├── main.py # gateway ├── data │ ├── mnist # mnist data (not included in this repo) │ | ├── t10k-images-idx3-ubyte.gz │ | ├── t10k-labels-idx1-ubyte.gz │ | ├── train-images-idx3-ubyte.gz │ | └── train-labels-idx1-ubyte.gz │ └── fashion-mnist # fashion-mnist data (not included in this repo) │ ├── t10k-images-idx3-ubyte.gz │ ├── t10k-labels-idx1-ubyte.gz │ ├── train-images-idx3-ubyte.gz │ └── train-labels-idx1-ubyte.gz ├── GAN.py # vanilla GAN ├── ops.py # some operations on layer ├── utils.py # utils ├── logs # log files for tensorboard to be saved here └── checkpoint # model files to be saved here
This implementation has been based on this repository and tested with Tensorflow over ver1.0 on Windows 10 and Ubuntu 14.04.
还没有评论,说两句吧!
热门资源
Keras-ResNeXt
Keras ResNeXt Implementation of ResNeXt models...
seetafaceJNI
项目介绍 基于中科院seetaface2进行封装的JAVA...
spark-corenlp
This package wraps Stanford CoreNLP annotators ...
capsnet-with-caps...
CapsNet with capsule-wise convolution Project ...
inferno-boilerplate
This is a very basic boilerplate example for pe...
智能在线
400-630-6780
聆听.建议反馈
E-mail: support@tusaishared.com