Skip to content

Commit 1fc9359

Browse files
authored
Update README.md
1 parent 902bb8a commit 1fc9359

File tree

1 file changed

+45
-17
lines changed

1 file changed

+45
-17
lines changed

README.md

Lines changed: 45 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -306,8 +306,38 @@ CUDA_VISIBLE_DEVICES=0,...,N python3 src/main.py -sefa -sefa_axis SEFA_AXIS -sef
306306
# Training GANs
307307

308308
StudioGAN supports the training of 30 representative GANs from DCGAN to StyleGAN3-r.
309+
309310
We used different scripts depending on the dataset and model, and it is as follows:
310311

312+
### CIFAR10
313+
```bash
314+
CUDA_VISIBLE_DEVICES=0 python3 src/main.py -t -hdf5 -l -std_stat -std_max STD_MAX -std_step STD_STEP -metrics is fid prdc -ref "train" -cfg CONFIG_PATH -data DATA_PATH -save SAVE_PATH -mpc --post_resizer "friendly" --eval_backbone "InceptionV3_tf"
315+
```
316+
317+
### CIFAR10 using StyleGAN2/3
318+
```bash
319+
CUDA_VISIBLE_DEVICES=0 python3 src/main.py -t -hdf5 -l -metrics is fid prdc -ref "train" -cfg CONFIG_PATH -data DATA_PATH -save SAVE_PATH -mpc --post_resizer "friendly" --eval_backbone "InceptionV3_tf"
320+
```
321+
322+
### Baby/Papa/Grandpa ImageNet and ImageNet
323+
```bash
324+
CUDA_VISIBLE_DEVICES=0,1,2,3 python3 src/main.py -t -hdf5 -l -sync_bn -std_stat -std_max STD_MAX -std_step STD_STEP -metrics is fid prdc -ref "train" -cfg CONFIG_PATH -data DATA_PATH -save SAVE_PATH -mpc --pre_resizer "lanczos" --post_resizer "friendly" --eval_backbone "InceptionV3_tf"
325+
```
326+
327+
### AFHQv2
328+
```bash
329+
export MASTER_ADDR="localhost"
330+
export MASTER_PORT=8888
331+
CUDA_VISIBLE_DEVICES=0,1,2,3 python3 src/main.py -t -metrics is fid prdc -ref "train" -cfg CONFIG_PATH -data DATA_PATH -save SAVE_PATH -mpc --pre_resizer "lanczos" --post_resizer "friendly" --eval_backbone "InceptionV3_tf"
332+
```
333+
334+
### FFHQ
335+
```bash
336+
export MASTER_ADDR="localhost"
337+
export MASTER_PORT=8888
338+
CUDA_VISIBLE_DEVICES=0,1,2,3,4,5,6,7 python3 src/main.py -t -metrics is fid prdc -ref "train" -cfg CONFIG_PATH -data DATA_PATH -save SAVE_PATH -mpc --pre_resizer "lanczos" --post_resizer "friendly" --eval_backbone "InceptionV3_tf"
339+
```
340+
311341
# Metrics
312342

313343
StudioGAN supports Inception Score, Frechet Inception Distance, Improved Precision and Recall, Density and Coverage, Intra-Class FID, Classifier Accuracy Score. Users can get ``Intra-Class FID, Classifier Accuracy Score`` scores using ``-iFID, -GAN_train, and -GAN_test`` options, respectively.
@@ -382,38 +412,36 @@ CUDA_VISIBLE_DEVICES=0,...,N python3 src/evaluate.py -metrics is fid prdc --post
382412

383413
## StudioGAN thanks the following Repos for the code sharing
384414

385-
Exponential Moving Average: https://github.com/ajbrock/BigGAN-PyTorch
415+
[[MIT license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/sync_batchnorm/LICENSE) Synchronized BatchNorm: https://github.com/vacancy/Synchronized-BatchNorm-PyTorch
386416

387-
Synchronized BatchNorm: https://github.com/vacancy/Synchronized-BatchNorm-PyTorch
417+
[[MIT license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/utils/ops.py) Self-Attention module: https://github.com/voletiv/self-attention-GAN-pytorch
388418

389-
Self-Attention module: https://github.com/voletiv/self-attention-GAN-pytorch
419+
[[MIT license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/utils/diffaug.py) DiffAugment: https://github.com/mit-han-lab/data-efficient-gans
390420

391-
Implementation Details: https://github.com/ajbrock/BigGAN-PyTorch
421+
[[MIT_license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/metrics/prdc.py) PyTorch Improved Precision and Recall: https://github.com/clovaai/generative-evaluation-prdc
392422

393-
Architecture Details: https://github.com/google/compare_gan
394-
395-
StyleGAN2: https://github.com/NVlabs/stylegan2
423+
[[MIT_license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/metrics/prdc.py) PyTorch Density and Coverage: https://github.com/clovaai/generative-evaluation-prdc
396424

397-
DiffAugment: https://github.com/mit-han-lab/data-efficient-gans
425+
[[MIT license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/utils/resize.py) PyTorch clean-FID: https://github.com/GaParmar/clean-fid
398426

399-
Adaptive Discriminator Augmentation: https://github.com/NVlabs/stylegan2
427+
[[NVIDIA source code license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/LICENSE-NVIDIA) StyleGAN2: https://github.com/NVlabs/stylegan2
400428

401-
Tensorflow IS: https://github.com/openai/improved-gan
429+
[[NVIDIA source code license]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/LICENSE-NVIDIA) Adaptive Discriminator Augmentation: https://github.com/NVlabs/stylegan2
402430

403-
Tensorflow FID: https://github.com/bioinf-jku/TTUR
431+
[[Apache License]](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/metrics/fid.py) Pytorch FID: https://github.com/mseitzer/pytorch-fid
404432

405-
Pytorch FID: https://github.com/mseitzer/pytorch-fid
433+
Implementation Details: https://github.com/ajbrock/BigGAN-PyTorch
406434

407-
Tensorflow Precision and Recall: https://github.com/msmsajjadi/precision-recall-distributions
435+
Architecture Details: https://github.com/google/compare_gan
408436

409-
PyTorch Improved Precision and Recall: https://github.com/clovaai/generative-evaluation-prdc
437+
Tensorflow IS: https://github.com/openai/improved-gan
410438

411-
PyTorch Density and Coverage: https://github.com/clovaai/generative-evaluation-prdc
439+
Tensorflow FID: https://github.com/bioinf-jku/TTUR
412440

413-
PyTorch clean-FID: https://github.com/GaParmar/clean-fid
441+
Tensorflow Precision and Recall: https://github.com/msmsajjadi/precision-recall-distributions
414442

415443
## License
416-
PyTorch-StudioGAN is an open-source library under the MIT license (MIT). However, portions of the library are avaiiable under distinct license terms: StyleGAN2, StyleGAN2-ADA, and StyleGAN3 are licensed under [NVIDIA source code license](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/LICENSE-NVIDIA), Synchronized batch normalization is licensed under [MIT license](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/sync_batchnorm/LICENSE), HDF5 generator is licensed under [MIT license](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/utils/hdf5.py), differentiable SimCLR-style augmentations is licensed under [MIT license](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/utils/simclr_aug.py), and clean-FID is licensed under [MIT license](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/utils/resize.py).
444+
PyTorch-StudioGAN is an open-source library under the MIT license (MIT). However, portions of the library are avaiiable under distinct license terms: StyleGAN2, StyleGAN2-ADA, and StyleGAN3 are licensed under [NVIDIA source code license](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/LICENSE-NVIDIA), and PyTorch-FID is licensed under [Apache License](https://github.com/POSTECH-CVLab/PyTorch-StudioGAN/blob/master/src/metrics/fid.py).
417445

418446
## Citation
419447
StudioGAN is established for the following research projects. Please cite our work if you use StudioGAN.

0 commit comments

Comments
 (0)