Skip to content

Latest commit

 

History

History
19 lines (14 loc) · 593 Bytes

File metadata and controls

19 lines (14 loc) · 593 Bytes

Basic Iterative Method (Targeted and Untargeted)

Paper: Adversarial examples in the physical world

Usage

  • Run the script
$ python3 iterative.py --img images/goldfish.jpg --model resnet18 --target 4
# If argument 'target' is not specified, it is untargeted attack
  • Control keys
    • use trackbar to change epsilon (max norm of perturbation) and iter (number of iterations)
    • esc close and space to pause
    • s save perturbation and adversarial image

Demo

iterative.gif