It is an reimplement of DCGAN with pytorch.
Step 0: Download
git clone https://github.com/zhoulukuan/DCGAN-Pytorch
Step 1: Install Pytorch and other package
pip install -r requirements
Step 2: Dataset preparation
We use Celeb-A Faces dataset dataset. Download img_align_celeba.zip
and the resulting directory
structure should be:
/path/to/img
-> img_align_celeba
-> XXXXXX.jpg
-> XXXXXX.jpg
Train your model by running:
python train.py configs/dcgan.py --save_dir /path/to/save --images_dir /path/to/img
Results will be saved in save_dir
including models of G/D and some results for visualization.
Use setting in configs/dcgan.py
(lr=0.0002,bs=128,epochs=10,Adam optimizer).