Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adversarial patch size for evaluating certified patch robustness on ImageNet #6

Open
HashmatShadab opened this issue Jun 11, 2023 · 2 comments

Comments

@HashmatShadab
Copy link

Hi

Can you please verify the adversarial patch size used for evaluating ImageNet trained models (b=19) in Table 1 of paper:
1% pixels: 23x23
2% pixels: 32x32
3% pixels: 39x39

@HashmatShadab
Copy link
Author

kindly provide an update on this when you get the time. And if you can specify the arguments used to reproduce results in Table using the pre-trained weights.

@Hadisalman
Copy link
Member

Apologies for late reply. Yes this is correct!

Here is an example script to evaluate ViT-B (b=19) against 32x32 patches (2% pixels):

python src/main.py \
      --dataset imagenet \
      --data /tmp \
      --arch deit_base_k19 \
      --out-dir OUTDIR \
      --exp-name demo \
      --batch-size 128 \
      --adv-train 0 \
      --freeze-level -1 \
      --resume \
      --eval-only 1 \
      --certify \
      --certify-out-dir OUTDIR_CERT \
      --certify-mode col \
      --certify-ablation-size 19 \
      --certify-patch-size 32

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants