Skip to content
/ FLM Public

Tensorflow implementation of Fast Geometrically-Perturbed Adversarial Faces

License

Notifications You must be signed in to change notification settings

alldbi/FLM

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

43 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FLM

Tensorflow implementation of "fast landmark manipulation method" (FLM) and "grouped fast landmark manipulation method" (GFLM) for generating adversarial faces, from our paper: Fast Geometrically-Perturbed Adversarial Faces.

Sample results

Setup

Prerequisites

  • Tensorflow 1.4.1
  • Python 2.7
  • CV2
  • Dlib
  • Matplotlib

Pretrained models

  • Download pretrained "Inception ResNet v1" model, trained on the "CASIA-WebFace" dataset provided by FaceNet.

  • Download the file and extract it to get the "shape_predictor_68_face_landmarks.dat" pretrained model for DLib landmark detector.

Getting Started

# clone this repo
git clone https://github.com/alldbi/FLM.git
cd FLM

# Generating adversarial faces by Grouped FLM:
python main.py \
  --method GFLM \
  --pretrained_model "path to the Inception ResNet v1 model trained on CASIA-WebFace" \
  --dlib_model "path to the pretrained model of the Dlib landmark detector" \
  --img "path to the input image" \
  --label "label of the input image" \
  --output_dir "path to the directory to save results"
  --epsilon "coefficient for a scaling the gradient sign for each single iteration of the attack"

# Generating adversarial faces by FLM:
python main.py \
  --method GFLM \
  --pretrained_model "path to the Inception ResNet v1 model trained on CASIA-WebFace" \
  --dlib_model "path to the pretrained model of the Dlib landmark detector" \
  --img "path to the input image" \
  --label "label of the input image" \
  --output_dir "path to the directory to save results"
  --epsilon "coefficient for a scaling the gradient sign for each single iteration of the attack"

Citation

If you use this code for your research, please cite the paper: Fast Geometrically-Perturbed Adversarial Faces:

@article{dabouei2018fast, title={Fast Geometrically-Perturbed Adversarial Faces}, author={Dabouei, Ali and Soleymani, Sobhan and Dawson, Jeremy and Nasrabadi, Nasser M}, journal={arXiv preprint arXiv:1809.08999}, year={2018} }

References

About

Tensorflow implementation of Fast Geometrically-Perturbed Adversarial Faces

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages