This is the official repository of the paper: DiffProb: Data Pruning for Face Recognition (accepted at FG 2025)
You can request access to the files containing the indexes of the kept samples for each pruning strategy applied in this work here. Please share your name, affiliation, and official email in the request form.
You can download the CASIA-WebFace dataset here.
- Run
train_everything.pyto train the original model (setconfig.is_original_train=Trueinconfig/config.py), whose predictions will be used to perform the pruning (in the paper, ResNet-50 + CosFace loss). This script will automatically generate the files necessary to perform DynUnc pruning
- Run
coreset_dynunc.pyto generate the kept sample list for the selected pruning percentage - Run
label_mapping.pyif you want to confirm that the number of ids has not been altered (this step is not mandatory) - Run
train_everything.pyunder the desired settings
Note: keep in mind that Rand can be applied before performing step 1
2. Run coreset_rand.py to generate the kept sample list for the selected pruning percentage
3. Run label_mapping.py if you want to confirm that the number of ids has not been altered (this step is not mandatory)
4. Run train_everything.py under the desired settings
- Run
eval_trainset.pyto generate the ground truth prediction of the pre-trained FR model for each sample
Without Cleaning
- Run
eval_simprobs.pyto generate the kept sample list for the selected pruning percentage - Run
label_mapping.pyif you want to confirm that the number of ids has not been altered (this step is not mandatory) - Run
train_everything.pyunder the desired settings
With Cleaning
- Run
clean_trainset.pyto apply our auxiliary cleaning mechanism and generate the kept sample list for the selected pruning percentage - Run
generate_label_dict.pyto generate a dictionary associating each identity (class label) with the indexes of its samples - Run
label_mapping.pyif you want to confirm that the new number of ids and to generate a label map, as some identities might be eliminated (this step is mandatory) - Run
train_everything.pyunder the desired settings
Run eval_ijbc.py to perform IJB-C evaluation
If you use any of the code, pruned datasets or models provided in this repository, please cite the following paper:
@misc{caldeira2025diffprobdatapruningface,
title={DiffProb: Data Pruning for Face Recognition},
author={Eduarda Caldeira and Jan Niklas Kolf and Naser Damer and Fadi Boutros},
year={2025},
eprint={2505.15272},
archivePrefix={arXiv},
primaryClass={cs.CV},
url={https://arxiv.org/abs/2505.15272},
}
This project is licensed under the terms of the Attribution-NonCommercial 4.0 International (CC BY-NC 4.0) license. Copyright (c) 2025 Fraunhofer Institute for Computer Graphics Research IGD Darmstadt



