A Cascade Face Spoofing Detector Based on Face Anti-Spoofing R-CNN and Improved Retinex LBP

Haonan Chen, Yaowu Chen, Xiang Tian, Rongxin Jiang

Introduction

Face biometric systems are increasingly integrated into daily life, yet they remain susceptible to "presentation attacks" (PAs), such as high-resolution photos, digital displays, or video replays. Existing research often suffers from two primary limitations: pipeline fragmentation, where face detection and spoof detection are treated as isolated tasks, and illumination sensitivity, where models fail under varying lighting conditions.

This paper introduces a robust, two-stage cascaded framework designed to address these gaps. By combining a specialized deep learning model, FARCNN, with an illumination-resistant texture descriptor, Improved Retinex LBP, the system achieves state-of-the-art performance across major industry benchmarks.

Proposed Methodology: The Cascade Framework

The core of the proposed system is a cascade strategy that leverages the strengths of both deep learning and hand-crafted texture features to ensure reliability even in adverse conditions.

The proposed cascade detector framework (a) and the detailed Improved Retinex LBP pipeline (b).

As illustrated in the framework above, the system first processes an image through the FARCNN. If the confidence score exceeds a pre-set threshold (e.g., 0.9), the result is output immediately. For ambiguous cases where the score falls below the threshold, the system triggers the Improved Retinex LBP detector. The final decision is reached through a late fusion of both scores, which is particularly effective for handling "reverse light" or low-quality inputs.

1. Face Anti-Spoofing R-CNN (FARCNN)

FARCNN is built upon the Faster R-CNN framework but is specifically optimized for anti-spoofing. It treats the problem as a three-way classification task—Real Face, Fake Face, and Background—rather than a simple binary choice. This allows the model to learn contextual clues from the background, such as the edges of a handheld photo or a screen bezel, which are vital for identifying spoofs.

Architecture of the Face Anti-Spoofing R-CNN (FARCNN) featuring attention-based fusion and hypersphere constraints for Crystal Loss.

Key innovations within FARCNN include:

  • Attention-Based Fusion: The model adaptively fuses features from multiple convolutional layers (conv3, conv4, conv5). This mechanism ensures that both high-level semantic information and fine-grained texture details are captured simultaneously.
  • Crystal Loss: To better distinguish "hard negatives," the authors introduce Crystal Loss. This function constrains feature vectors to a hypersphere with a fixed radius, forcing the network to minimize intra-class variation and maximize the distance between real and fake face clusters more effectively than standard Softmax.

2. Improved Retinex LBP

The second stage of the cascade serves as a standby detector for difficult lighting scenarios. Unlike traditional Retinex algorithms that use Gaussian filters (often resulting in halo artifacts), this method employs Iterative Guided Filtering to estimate illumination while preserving sharp edges. Local Binary Patterns (LBP) are then extracted from the luminance components of three color spaces (YCbCr, HSL, and LAB), providing a comprehensive and light-resistant texture signature.

Experimental Results

The model was evaluated on three gold-standard datasets: CASIA-FASD, REPLAY-ATTACK, and OULU-NPU.

  • REPLAY-ATTACK: The system achieved a near-perfect Equal Error Rate (EER) of 0.062% and a Half Total Error Rate (HTER) of 0.183%.
  • CASIA-FASD: The cascaded approach achieved an EER of 2.359%, a significant improvement over the standalone FARCNN baseline (3.049%).
  • Generalization: Cross-database testing demonstrated that the proposed method maintains high accuracy across different camera types and environments, proving its robustness against overfitting to specific training setups.

Conclusion

The proposed cascade detector effectively bridges the gap between deep learning accuracy and texture-based robustness. By incorporating background context through three-way classification and refining feature separation with Crystal Loss, the framework sets a new standard for face anti-spoofing systems. Future work will explore the system's efficacy against 3D mask attacks and further optimize the multi-task loss functions to balance detection and classification efficiency.

Summary updated

Abstract

In consideration of secure and convenient, face gains increasing attention in variety of fields during the past decades. Since human face is most accessible from our daily life and preserves the richest information, face based biometric systems are widely used in person authentication applications. However, face recognition systems are always challenged by face spoofing attacks. Although, researchers have proposed many face spoofing detection methods, which have achieved great performances, we aim to develop a method to counter face spoofing, which combines the face detection stage and face spoofing detection stage together. In this paper, we design face anti-spoofing region-based convolutional neural network (FARCNN), based on improved Faster region-based convolutional neural network (R-CNN) framework. Motivated by face detection, we regard the face spoofing detection as a three-way classification to distinguish real face, fake face and background. We extend the typical Faster R-CNN scheme by optimizing several important strategies, including roi-pooling feature fusion and adding Crystal Loss function to the original multi-task loss function. In addition, an improved Retinex based LBP is presented to handle the different illumination conditions in face spoofing detection. Finally, these two detectors are further cascaded and achieve promising performances on the benchmark databases: CASIA-FASD, REPLAY-ATTACK and OULU-NPU. Besides, for the purpose of verifying the generalization capacity of the proposed cascade detector, we perform experiments on cross-databases and the results testify the effectiveness of our proposed method.
BibTeX
@article{chen2019cascade,
  author = {Haonan Chen and Yaowu Chen and Xiang Tian and Rongxin Jiang},
  title = {{A Cascade Face Spoofing Detector Based on Face Anti-Spoofing R-CNN and Improved Retinex LBP}},
  journal = {IEEE Access},
  year = {2019},
  doi = {10.1109/access.2019.2955383},
}
Figure