From 5e1b8fd2fcc19ba9d25bdd7b89d9dee98d385df5 Mon Sep 17 00:00:00 2001 From: Shawn-Shan Date: Mon, 20 Jul 2020 13:47:51 -0500 Subject: [PATCH] add eval readme --- evaluation/README.md | 20 ++++++++++++++++++++ fawkes/protection.py | 2 -- 2 files changed, 20 insertions(+), 2 deletions(-) create mode 100644 evaluation/README.md diff --git a/evaluation/README.md b/evaluation/README.md new file mode 100644 index 0000000..a85612e --- /dev/null +++ b/evaluation/README.md @@ -0,0 +1,20 @@ +Fawkes Evaluation +----------------- + + +We offer two ways to test the protection is effective, 1) train a local face recognition model using transfer learning, 2) use Microsoft Azure API. +Note that we can't guarantee the protection is always successful due to new development in face recognition technique. + +Evaluation with Local Model +--------------------------- +To evaluate using local model, you are highly recommended to have a GPU device and train the model on it. Otherwise, the evaluation will be extremely slow and might even damage the CPUs on some machine. + +To evaluate, run `python3 eval_local.py -d IMAGE_DIR`. Where `IMAGE_DIR` is the image directory send to Fawkes protection code, and it must contain both original images (testing) and cloaked image (training). +All images in the directory must belong to the same person and have at least 10 images in them. Also, you cannot turn on `--seperate-target` during the protection. (We are working on reducing some of these limitations.) +The script will output the protection success rate at the end. + + +Evaluation with Microsoft Azure +--------------------------- +forthcoming... + diff --git a/fawkes/protection.py b/fawkes/protection.py index 999db10..188bae3 100644 --- a/fawkes/protection.py +++ b/fawkes/protection.py @@ -113,8 +113,6 @@ class Fawkes(object): image_paths, loaded_images = filter_image_paths(image_paths) - start_time = time.time() - if not image_paths: raise Exception("No images in the directory") with graph.as_default():