Skip to content

royg27/PAG-ROB

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation


Do Perceptually Aligned Gradients Imply Robustness?

Roy GanzBahjat KawarMichael Elad

[ICML 2023 - Oral] Official Code Repository of Do Perceptually Aligned Gradients Imply Robustness?

Installation

First, clone this repository:

git clone https://github.com/royg27/PAG-ROB.git
cd PAG-ROB

Next, to install the requirements in a new conda environment, run:

conda env create -f environment.yml

Preparing Perceptually Aligned Gradients Data

The Perceptually Aligned Gradients' realization for the Score-Based Gradients for the CIFAR-10 dataset is provided in the following table:

PAG realization Data Labels
Score-Based Gradients Download Download

The data should be placed in the data folder, forming the following structure:

PAG-ROB
├── configs
│   ├── ......
├── data
│   ├── c10_sbg_data.pt
│   ├── c10_sbg_label.pt
├── models
│   ├── ......
├── TRAIN_CIFAR10.py

Training

python TRAIN_CIFAR10.py --config_path <config>

where <config> specifies the desired training configuration (e.g., configs/cifar10_sbg_rn18.yaml)

Trained Checkpoints

We provide pretrained checkpoints on the CIFAR-10 dataset in the table below:

RN18 OI RN18 CM RN18 NN RN18 SBG ViT SBG
Download Download Download Download Download

Citation

If you find this code or data to be useful for your research, please consider citing it.

@misc{ganz2023perceptually,
      title={Do Perceptually Aligned Gradients Imply Adversarial Robustness?}, 
      author={Roy Ganz and Bahjat Kawar and Michael Elad},
      year={2023},
      eprint={2207.11378},
      archivePrefix={arXiv},
      primaryClass={cs.CV}
}

About

[ICML 2023 - Oral] Do Perceptually Aligned Gradients Imply Robustness? -- Official Code Repository

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages