Abstract
The performance of face detection has been largely improved with the development of convolutional neural networks. However, the occlusion issue due to masks and sunglasses remains a challenging problem. Improving the recall of these occluded cases usually brings the risk of high false positives. In this paper, we present a novel face detector called Face Attention Network (FAN), which significantly improves the recall of face detection in occluded cases without compromising speed. More specifically, we propose a new anchor-level attention mechanism that highlights features from the face region. Integrated with our anchor assignment strategy and data augmentation techniques, we obtain state-of-the-art results on public face detection benchmarks like WiderFace and MAFA.
Introduction
While modern Convolutional Neural Networks (CNNs) have made face detection look easy in ideal conditions, occlusion remains a significant hurdle. When a face is partially covered—by a surgical mask, a pair of dark glasses, or even another person's head—detectors often fail.
The core challenge is a double-edged sword: if you tune a model to be sensitive enough to catch a face based only on a visible chin or forehead, you drastically increase the risk of "false positives" (e.g., mistaking a hand or a patch of skin-colored background for a face). The authors set out to build a detector that can maintain high recall for occluded faces while keeping false alarms to a minimum.
Methodology
FAN is built upon the RetinaNet architecture, a popular one-stage detector that uses a Feature Pyramid Network (FPN) with a ResNet-50 backbone. The authors introduce three key innovations:
1. Anchor-Level Attention
This is the paper's primary contribution. The researchers added a "segment-like" side branch to the network. This branch generates hierarchical attention maps that are supervised by ground-truth face regions. Unlike standard attention, these maps undergo an exponential operation before being multiplied by the feature maps. This effectively "highlights" facial features and "dims" background noise that might cause false positives.
2. Specialized Anchor Strategy
Most object detectors use generic anchor boxes. FAN uses anchors specifically scaled (16 to 406 pixels) and shaped (ratios of 1:1 and 1:1.5) to match the statistics of human faces. They use a dense anchor assignment to ensure that even small or oddly shaped face fragments are captured.
3. Random Crop Augmentation
Recognizing that standard datasets lack enough examples of occluded faces, the authors used a random cropping strategy during training. By cropping images so that only parts of a face remain, they forced the network to learn how to identify a person from partial visual cues.
Key Insights: Attention as a Spatial Filter
The "aha moment" here is using attention not just to find objects, but to suppress the "skin-like" distractors (like hands or arms) that typically confuse detectors when they are looking for partial faces.
Because the attention maps are hierarchical, the network learns to look for different types of features at different scales. Larger faces get more detailed attention, while smaller faces focus on more robust, global features. This scale-aware supervision allows the model to maintain high precision even in crowded environments.
Key Results
FAN demonstrated impressive gains over previous state-of-the-art (SOTA) models:
- WiderFace: On the "Hard" subset (which contains the most occlusions), FAN achieved an AP of 88.5%, outperforming previous leaders like SFD (85.8%) and SSH (84.4%).
- MAFA: FAN achieved a Mean Average Precision (mAP) of 88.3%, a significant jump over the previous best of 77.3%.
- Efficiency: Despite the added attention layers, the model remains fast. On an NVIDIA Titan Xp, it can process a 1000-pixel image in approximately 67.9ms, making it viable for near-real-time applications.
Conclusion
While FAN performs exceptionally well, the "Hard" subset of WiderFace still shows a performance gap compared to the "Easy" subset (88.5% vs 94.6%), suggesting that extremely small or heavily blurred faces remain a challenge. The authors suggest that the anchor-level attention mechanism is a general-purpose tool that could potentially be integrated into two-stage detectors (like Faster R-CNN) or applied to other specific object detection tasks where occlusion is a primary concern, such as pedestrian detection in crowded city streets.
Summary updated