Back to paper library
WACV Workshops 2022Face anti-spoofingPaper notes

Personalized-FAS

Personalized Attempt

Original paper

A Personalized Benchmark for Face Anti-Spoofing

Paper authors

Davide Belli · Debasmit Das · Bence Major · Fatih Porikli

Publication
WACV Workshops 2022Workshop
Cite this paper · BibTeX

The citation identifies the linked source version. It cites the original paper and its authors.

@inproceedings{faceantispoofingpersonalizedfas2022,
  title = {{A Personalized Benchmark for Face Anti-Spoofing}},
  author = {Davide Belli and Debasmit Das and Bence Major and Fatih Porikli},
  year = {2022},
  booktitle = {WACV Workshops},
  url = {https://openaccess.thecvf.com/content/WACV2022W/MAP-A/html/Belli_A_Personalized_Benchmark_for_Face_Anti-Spoofing_WACVW_2022_paper.html}
}
On this page

This paper leans toward applications and has not drawn many citations.

But it proposes a personalized benchmark for existing FAS models, an idea that also resonates with today's attention to privacy. Let's take a look.

Defining the Problem

We have already reviewed several FAS papers.

The general approach is to input a new image into a pre-trained FAS model, and the model tells you whether the image is live or spoofed. In this process, the model makes its determination based on the features of the image.

The authors of this paper, however, focused on the “user enrollment images.”

Face recognition systems commonly use metric learning. In practice, a user supplies one or more photos at enrollment, and later verification compares a new image with those registered photos.

So, why not use these enrolled photos as references for the FAS model?

The authors of this paper proposed this idea and demonstrated its effectiveness in experiments.

Solving the Problem

Model Architecture

This research presents a compact yet scalable personalized FAS architecture. The core idea is to treat the images from the user enrollment phase (Enrollment Set) as "personal liveness references" and use feature aggregation mechanisms to compare them with the current query image (Query), enhancing the reliability of liveness detection. The overall process, as shown in the image above, can be broken down into the following three stages:

  1. Dual-path Feature Extraction Module:

    The model uses two independent CNN encoders, one for query images and one for enrollment images. The authors let these paths learn their own representations, then test whether sharing weights would work in an ablation.

    • The query image IqI_q is encoded by encoder ϕq\phi_q into a feature vector fq∈RDf_q \in \mathbb{R}^D
    • The enrollment images {Iei}i=1N\{I^i_e\}_{i=1}^N are encoded by another encoder ϕe\phi_e into {fei}i=1N\{f^i_e\}_{i=1}^N
  2. Enrollment Feature Aggregation Module:

    The model needs to integrate the features of multiple enrollment images into a single latent vector feaggf^{agg}_e, representing the personalized reference for the user. The authors explored several aggregation strategies, including:

    • Non-parametric Methods

      • Concatenation

        • Concatenate the NN enrollment features into a vector of length N⋅DN \cdot D
        • Retain full information but is order-sensitive and lacks permutation invariance
      • Mean

        • Average the NN features: feagg=1N∑i=1Nfeif^{agg}_e = \frac{1}{N} \sum_{i=1}^N f^i_e
        • Highly compressed into a single vector, with order invariance
        • Model the correspondence between the query and enrollment using an MLP

    • Sequence Modeling (GRU)

      • Treat enrollment features as a time sequence (particularly suitable for SiW video frames)
      • Use the GRU algorithm for recursive aggregation: hli=GRU(fli,hli−1)h_l^i = \text{GRU}(f_l^i, h_l^{i-1})
      • The hidden state of the last layer serves as the aggregated feature feagg=hLNf^{agg}_e = h_L^N

      This approach can model enrollment features sampled in video order. Whether it outperforms non-sequential aggregation is decided by the experiments.


    • Attention-based Learning

      Use key-query-value attention on query and enrollment features:

      feagg=Softmax(QKTM)Vf^{agg}_e = \text{Softmax} \left( \frac{QK^T}{\sqrt{M}} \right)V

      Specifically:

      • Q=AQ(fq)Q = A_Q(f_q)
      • Ki=AK(fei)K_i = A_K(f^i_e), Vi=AV(fei)V_i = A_V(f^i_e)
      • AQ,AK,AVA_Q, A_K, A_V are all linear layers

      This method models the similarity between query and enrollment features, strengthening their correspondence.


    • Graph Neural Network (GNN)

      Treat the query + enrollment features as nodes in a graph:

      • N+1N + 1 nodes: the query + NN enrollment images

      Each GNN layer performs:

      1. Calculate the adjacency matrix AlA_l: based on the distance function ψl(fli,flj)\psi_l(f^i_l, f^j_l) between node features
      2. Perform graph convolution to update node features: Fl+1=ρ(∑Al∈AlAlFlWl)F_{l+1} = \rho \left( \sum_{A_l \in \mathcal{A}_l} A_l F_l W_l \right)

      Here Fl∈R(N+1)×dlF_l\in\mathbb{R}^{(N+1)\times d_l} denotes the full node-feature matrix, avoiding the paper’s ambiguous use of a single-node symbol in matrix multiplication. The query node supplies the prediction; the GNN variant replaces the usual MLP classifier.

      This method is suitable for modeling the relative relationships between enrollment features, capturing the similarities and differences between different enrollment images.


    In these experiments, the simple mean operator instead performs consistently well. Even without changing the main backbone, a simple aggregation strategy can introduce personalization.

  3. Feature Fusion and Classification Module:

    Except for the GNN variant, which predicts directly from the query node, the aggregation methods concatenate fqf_q and feaggf^{agg}_e and pass them to an MLP classifier. The model is trained end to end with cross-entropy to predict whether the query is live or spoof.

The architecture can be evaluated with different backbones, but deployment cost and security still need separate verification.

Enrollment features do not depend on the current query and can be computed during registration. Each query still needs its own processing, followed by aggregation and classification. The experiments use RGB images; the paper does not test privacy protection for stored embeddings or multimodal deployment.

Dataset Construction

To validate the effectiveness of the proposed model architecture, the authors modified existing public FAS datasets to create the first batch of personalized versions with "user enrollment correspondence," as follows:

  • CASp-Enroll (modified from CelebA-Spoof)
  • SiW-Enroll (modified from SiW)

This conversion can be applied to anti-spoofing datasets that contain subject metadata and enough live samples for each retained user. Its core logic is as follows:

  • In the original dataset, each data point consists of a query image and its spoof label: di=(Iq(i),tq(i))d_i = (I_q^{(i)}, t_q^{(i)})
  • The personalized dataset adds the corresponding enrollment set, which includes N live images from the same user: di=(Iq(i),tq(i),e(i)),where e(i)=(Ie1,...,IeN)d_i = (I_q^{(i)}, t_q^{(i)}, \mathbf{e}^{(i)}), \quad \text{where } \mathbf{e}^{(i)} = (I^1_e, ..., I^N_e)
  • An enrollment set is created for each user and applied to that user's retained query samples.

CelebA-Spoof-Enroll (CASp-EnrollN)

CelebA-Spoof is one of the largest liveness detection datasets, covering over 10,000 users and 600,000 images. To create CASp-Enroll, the authors devised the following strategy:

  • Set a fixed enrollment size N (e.g., N=5) to ensure each user has a standardized reference set.
  • Exclude users with at most N genuine images so at least one genuine query remains after selecting N enrollment images.
  • The first N live images are designated as the enrollment set, with the remaining live and spoof images used as queries.
  • Select enrollment images by filename order rather than randomly.

This data partitioning logic not only maintains data standardization but also aligns with the practical "enrollment first, subsequent verification" process.

SiW-Enroll (SiW-EnrollN)

SiW is a high-quality video-based anti-spoofing dataset originally from 165 subjects who filmed 4,478 short clips. To personalize the dataset:

  • Split train and test according to Protocol 1, sample every 10 frames, then construct two folds with different attack types used in training and testing.
  • For each user × device combination, choose one video and extract N equally spaced frames as enrollment; sampling is not random.
  • To simulate real-world device operation scenarios, the video must meet these conditions:
    • No lighting changes
    • Pose changes (to increase diversity in the enrollment representation)
  • All frames from the video are excluded from the query set to prevent information leakage.

This design gives each subject a separate enrollment for each capture device while preventing frames from the enrollment video from leaking into the query set.

Discussion

Is Personalization Really Better?

The paper defines AUC10 as ROC area up to the 10% false-negative-rate operating point, rather than a 10% false-positive-rate cutoff.

The table shows that on both personalized datasets (CASp-Enroll5 and SiW-Enroll5) and all three backbones, the retrained personalized model with mean aggregation improves AUC, AUC10, and EER over its corresponding baseline.

  • On CASp-Enroll5, the largest AUC10 increase is 2.3 percentage points for ResNet18 (94.1% → 96.4%); VGG16 and FeatherNet improve as well. The paper's prose says 2.2%, while its table yields 2.3 for ResNet18.
  • FeatherNet is a lightweight FAS model and still improves with personalization, suggesting that the approach can also be used with smaller backbones. Mobile deployment was not tested.

In contrast, the improvement in SiW-Enroll5 was smaller, likely due to the less diverse and lower variability of the enrollment composition, which resulted in less informative personalized references compared to CASp-Enroll5.

This directly answers the first research question:

Can adding personalized reference data truly improve FAS performance?

The answer is affirmative.

On the tested datasets and models, adding an enrollment branch and retraining improves classification. The paper does not test whether merely supplying images to an existing, unchanged model would help.

Is the Simplest Method the Best?

The authors evaluated five different enrollment feature aggregation methods.

From the experimental results shown in the figure:

Mean performs consistently well on the tested metrics, although it does not lead on every one.

A closer look shows:

  • On CASp-Enroll5, the Mean aggregation achieved the highest AUC and AUC10 (98.6 / 94.1), while also reducing the EER to the lowest overall (5.9), demonstrating extremely high overall performance.
  • On SiW-Enroll5, Concatenation beats Mean on AUC, AUC10, and EER (98.2 / 94.3 / 6.0 versus 98.1 / 93.3 / 6.2). Mean still ranks in the top three on each metric.
  • In contrast, the Attention method surprisingly performed worse, not only failing to outperform the baseline but even slightly regressing in SiW (EER increased to 7.1).
  • While GNN showed some expressive ability, it lagged behind non-parametric methods in CASp, suggesting that its complexity did not bring commensurate benefits.

These results echo a common phenomenon in model design: more complex mechanisms are not necessarily more effective. Especially when the quality and scale of enrollment data are limited, simpler methods are often better at learning stable matching logic.

Can’t Share the Encoder?

This ablation experiment attempts to answer a critical question: Can the query image and the enrollment image share the same feature extractor?

Intuitively, both are facial images with the same input format, so they could theoretically be processed by the same CNN encoder. However, the experimental results provide a clear and unexpected conclusion:

In this VGG16 ablation, sharing the encoder performs worse than using separate encoders.

As shown in the table, when we use the same encoder to extract features for both query and enrollment images:

  • On CASp-Enroll5, the AUC10 significantly dropped (from 94.1 to 90.8), and the EER surged to 13.7%, even falling below the baseline without personalization.
  • On SiW-Enroll5, sharing raises EER to 20.6%, compared with 6.2% for separate encoders and 6.8% for the baseline.

In contrast, using independent encoders maintained the high performance.

Conclusion

This study presents a novel approach for personalized FAS by incorporating user enrollment images as references, allowing the model to incorporate individual characteristics in the recognition process and effectively improving spoof attack detection. From creating the benchmark, conversion process, to evaluating aggregation strategies and model designs, the overall work is clear and insightful, providing a starting point for future FAS systems that account for user differences.