This repository is an implementation of the ICCV 2023 paper "Hiding Visual Information via Obfuscating Adversarial Perturbations".
This project is tested under the following environment settings:
- OS: Ubuntu 18.04.6
- Cuda: 11.1, Cudnn: v8.05
- Python: 3.7.12
- TensorFlow: 1.9.0
- PyTorch: >= 1.10.2
- Torchvision: >= 0.11.3
- Align and crop the face image to
$112 \times 112$ and put it underdata/align
. - Put the pre-trained generative model (key model) under the
checkpoints
. We provide a pre-trained model for testing in face recognition tasks.
Running command to encrypt the image:
python main.py --model pix2pix --task face_recognition
Running command to encrypt the image:
python main.py --model pix2pix --task classification --src_model Resnet18 --batch_size 10 --root ./data/cif
This code is built on CycleGAN, TIP-IM and MS-SSIM. We thank the authors for sharing the codes.