forked from djsutherland/opt-mmd
/
cifar10.sh
executable file
·49 lines (42 loc) · 1.47 KB
/
cifar10.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!/usr/bin/env bash
MODEL=MMD
SAVEPATH=./
DATAPATH=./data
export TF_MIN_GPU_MULTIPROCESSOR_COUNT=3;
#export CUDA_VISIBLE_DEVICES=0;
if [[${MODEL} == 'MMD']] || [[${MODEL} == 'ALL']]; then
python ./gan/main.py \
--checkpoint_dir=${SAVEPATH}checkpoint \
--sample_dir=${SAVEPATH}samples \
--log_dir=${SAVEPATH}logs \
--data_dir={DATAPATH} \
--model=mmd --name=mmd --kernel=mix_rq_1dot \
--architecture=dcgan --output_size=32 --dof_dim=16 \
--gradient_penalty=1. --L2_discriminator_penalty=1. \
--dataset=cifar10 \
--MMD_lr_scheduler \
fi
if [[${MODEL} == 'WGAN-GP']] || [[${MODEL} == 'ALL']]; then
python ./gan/main.py \
--checkpoint_dir=${SAVEPATH}checkpoint \
--sample_dir=${SAVEPATH}samples \
--log_dir=${SAVEPATH}logs \
--data_dir={DATAPATH} \
--model=wgan_gp --name=wgan_gp \
--architecture=dcgan --output_size=32 --dof_dim=1 \
--gradient_penalty=10. \
--dataset=cifar10 \
--MMD_lr_scheduler \
fi
if [[${MODEL} == 'CRAMER']] || [[${MODEL} == 'ALL']]; then
python ./gan/main.py \
--checkpoint_dir=${SAVEPATH}checkpoint \
--sample_dir=${SAVEPATH}samples \
--log_dir=${SAVEPATH}logs \
--data_dir={DATAPATH} \
--model=cramer --name=cramer_gan \
--architecture=dcgan --output_size=32 --dof_dim=256 \
--gradient_penalty=10. \
--dataset=cifar10 \
--MMD_lr_scheduler \
fi