Here are some standard examples about how to use this toolbox.
- run the attack method of C2FMI:
cd adapter_training
python c2f.py- run the attack method of C2FMI on high-resolution images:
cd adapter_training
python c2f_high.py- config the options in each attack script as instructed, such as in
brepmi.py:
experiment_dir = '<fill it>'
generator_ckpt_path = '<fill it>'
target_model_ckpt_path = '<fill it>'
eval_model_ckpt_path = '<fill it>'
eval_dataset_path = '<fill it>'- run the attack method of BREPMI, GMI, LOMMA, MIRROR, PLGMI, PPA, RLBMI, VIM:
cd attacks
python <ATTACK_METHOD_NAME>.py- config the options in each training script as instructed, such as in
celeba64.py:
train_dataset_path = '<fill it>'
test_dataset_path = '<fill it>'
experiment_dir = '<fill it>'
backbone_path = '<fill it, or set as None>'- run the training scripts of classifiers under various resolutions:
cd classifier_training
python <TRAIN_METHOD_NAME>.py- config the options in each preprocess script as instructed, such as in
afhqdogs256.py:
src_path = '<fill it>'
dst_path = '<fill it>'- run the preprocess scripts of datasets under various resolutions:
cd dataset_preprocess
python <PREPROCESS_METHOD_NAME>.py- config the options in each gan training script as instructed, such as in
gmi.py:
dataset_path = '<fill it>'
experiment_dir = '<fill it>'- run the preprocess scripts of datasets under various resolutions:
cd gan_training
python <GAN_TRAIN_METHOD_NAME>.py