alldbi / FLM

Tensorflow implementation of Fast Geometrically-Perturbed Adversarial Faces
MIT License
24 stars 5 forks source link
adversarial faces fast geometrically-perturbed

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

Pretrained models

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