
This is the official code for Adversarial Feature Desensitization (AFD). 

You can run training procedure by calling ```afd_train.py```. It currently supports MNIST, CIFAR10, and CIFAR100 datasets. 
We have tested the code with ResNet5 (a shallow ResNet model with 5 layers) on MNIST and ResNet18 on CIFAR10 and CIFAR100. 

**Example**: 
```
python afd_train.py --dataset=cifar10 --enc_model=resnet18 --save_path=[SAVE_PATH]
```

You can use ```notebooks/test.ipynb``` to run attacks on the pretrained models.  
