Multi-Scale Gradient GAN
This an implementation of MSG-GAN: Multi-Scale Gradient GAN for Stable Image Synthesis.
Notes
This implementation differs from the one in the original paper.
- To regularize the discriminator I use R1 penalty.
- To improve sample diversity I use PacGAN discriminator.
- I use a stylegan-like generator (or you could call it a self modulation):
latent vector injection with AdaIN layers.
How to train
- Put your images in a folder.
- Edit training config in the beginning of
train.py
file. - Run
python train.py
for training. - Run
tensorboard --logdir=summaries/run00/
to view losses. - Use
generation.ipynb
to generate samples with a trained model.
Example of generated samples
For training I used FEIDEGGER dataset. All hyperparameters that I used are in train.py
.
Note that the generated samples came from different epochs.
Requirements
- pytorch 1.2
- tqdm, Pillow 6.1
- tensorboard 1.14
Acknowledgments
This code is based on