Set up env for FDFR and ISM. Firstly, we need to cd evalutions
and install the following library:
cd deepface
pip install -e .
cd retinaface
pip install -e .
Note: You should follow the tensorflow instruction from https://www.tensorflow.org/install/pip
to accelerate evaluation process (without tensorflow, the eval code will run on cpu which is slow)
To compute FDFR and ISM. If you get block by proxy, manually download weight of DeepFace from https://github.com/serengil/deepface_models/releases/download/v1.0/arcface_weights.h5 and download weight from https://github.com/serengil/deepface_models/releases/download/v1.0/retinaface.h5, place it in folder "{home}/.deepface/weights/".
We run the following command to compute FDFR and ISM soore: python evaluations/ism_fdfr.py --data_dir <path_to__perturb_image_dir> --emb_dirs <paths_to_id_emb_file>
cd FaceImageQuality
- download the model files and place them in the
insightface/model
and install environment by commandpip install -r requirements.txt
(Note: should use numpy==1.22.0) - Run
python evaluations/ser_fiq.py --prompt_path <path_to_perturb_images_of_prompts> --gpu 0
wheregpu
is the cuda device id
pip install brisque
- Run
python evaluations/brisque.py --prompt_path <path_to_perturb_images_of_prompts>