Skip to content

PyTorch Implementation of "ZstGAN: An Adversarial Approach for Unsupervised Zero-Shot Image-to-Image Translation"

Notifications You must be signed in to change notification settings

linjx-ustc1106/ZstGAN-PyTorch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ZstGAN-PyTorch

PyTorch Implementation of "ZstGAN: An Adversarial Approach for Unsupervised Zero-Shot Image-to-Image Translation"

Dependency:

Python 3.6

PyTorch 0.4.0

Usage:

Unsupervised Zero-Shot Image-to-Image Transaltion

  1. Downloading CUB and FLO training and testing dataset following CUB and FLO with password n6qd. Or you can follow the StackGAN to prepare these two datasets.

  2. Unzip the Data.zip and organize the CUB and FLO training and testing sets as:

    Data
    ├── flowers
    |   ├── train
    |   ├── test
    |   └── ...
    ├── birds
        ├── train
        ├── test
        └── ...
    
  3. Train ZstGAN on seen domains of FLO:

    $ python main.py --mode train --model_dir flower --datadir Data/flowers/ --c_dim 102 --batch_size 8 --nz_num 312 --ft_num 2048 --lambda_mut 200

  4. Train ZstGAN on seen domains of CUB:

    $ python main.py --mode train --model_dir bird --datadir Data/birds/ --c_dim 200 --batch_size 8 --nz_num 312 --ft_num 2048 --lambda_mut 50

  5. Test ZstGAN on unseen domains of FLO at iteration 200000:

    $ python main.py --mode test --model_dir flower --datadir Data/flowers/ --c_dim 102 --test_iters 200000

  6. Test ZstGAN on unseen domains of CUB at iteration 200000:

    $ python main.py --mode test --model_dir bird --datadir Data/birds/ --c_dim 200 --test_iters 200000

Results:

1. Image translation on unseen domains of FLO at iterations 150000:

# Results of V-ZstGAN:

# Results of A-ZstGAN:

2. Image translation on unseen domains of CUB at iterations 150000:

# Results of V-ZstGAN:

# Results of A-ZstGAN:

About

PyTorch Implementation of "ZstGAN: An Adversarial Approach for Unsupervised Zero-Shot Image-to-Image Translation"

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages