This repository explains selective implementation of train DCGAN with your own dataset. If you want to experience fully stable model, visit (https://github.com/carpedm20/DCGAN-tensorflow).
- Python 2.7 or Python 3.3+
- Tensorflow 0.12.1+
- SciPy
- pillow
This model supports both cpu and gpu training. First of all, checkout either python2 or python3 use gpu as default device or not. In writer's case, python3 uses gpu as training device, following usage will be written by python3 command
- Prepare dataset:
$ mkdir data/your-dataset-folder-name
- Train a model
$ python3 main.py --dataset your-dataset-folder-name --crop --train
or you can set the image demension: recomended 108
$ python3 main.py --dataset your-dataset-folder-name --input_height=108 --output_height=108 --train
based on image demension the training speed might be faster or slower
If you have decent gpu, make sure the gpu and cuda executed properly. You need to check following logs in your terminal.
StreamExecutor device (*): GeForce GTX **** **, Compute Capability *.*
successfully opened CUDA library libcublas.so.**.** locally
You can check result in directory /out/20******.****-data-your_dataset_folder_name-image_demension/samples/
My own dataset is a combination of style lookbook.
Looking for 8x8 neatly generated clothes but, around 15 epoch, it seems the result with high noise. Further modification required.
With given target dataset which is celebA from original repo, even up to the 1 epoch, it shows feasible result