Abstract
Facial alignment involves finding a set of landmark points on an image with a known semantic meaning. However, this semantic meaning of landmark points is often lost in 2D approaches where landmarks are either moved to visible boundaries or ignored as the pose of the face changes. In order to extract consistent alignment points across large poses, the 3D structure of the face must be considered in the alignment step. However, extracting a 3D structure from a single 2D image usually requires alignment in the first place. We present our novel approach to simultaneously extract the 3D shape of the face and the semantically consistent 2D alignment through a 3D Spatial Transformer Network (3DSTN) to model both the camera projection matrix and the warping parameters of a 3D model. By utilizing a generic 3D model and a Thin Plate Spline (TPS) warping function, we are able to generate subject specific 3D shapes without the need for a large 3D shape basis. In addition, our proposed network can be trained in an end-to-end frame-work on entirely synthetic data from the 300W-LP dataset. Unlike other 3D methods, our approach only requires one pass through the network resulting in a faster than real-time alignment. Evaluations of our model on the Annotated Facial Landmarks in the Wild (AFLW) and AFLW2000-3D datasets show our method achieves state-of-the-art performance over other 3D approaches to alignment.
Introduction
Facial alignment—the localization of semantic landmarks such as the eyes, nose, and mouth—is a fundamental task in computer vision. Traditional 2D approaches often fail in "in-the-wild" scenarios involving large yaw angles, where landmarks may merge into visible boundaries or disappear due to self-occlusion. While 3D modeling offers a solution by providing a consistent structural framework, it introduces a "chicken-and-egg" problem: 3D reconstruction typically requires pre-aligned points. Furthermore, existing 3D Morphable Models (3DMM) are often computationally intensive and constrained by the diversity of their underlying scan databases.
Methods
The proposed 3D Spatial Transformer Network (3DSTN) addresses these challenges by treating facial alignment as a joint 3D shape and camera pose estimation problem. The architecture enables a single-pass feed-forward estimation.
Key components of the 3DSTN include:
- Camera Projection Transformers: A differentiable module that estimates the 3x4 camera projection matrix (11 degrees of freedom), mapping 3D coordinates to 2D image space.
- 3D Thin Plate Spline (TPS) Warping: Instead of a rigid 3DMM basis, the model applies non-linear TPS warping to a generic 3D mean shape. This allows for the generation of subject-specific 3D shapes without a massive library of scans.
- 2D Landmark Regression: A refinement stage uses local CNN features to adjust the initial 3D-to-2D projected landmarks into their final positions.
- End-to-End Training: The entire pipeline is differentiable, allowing the model to be trained on synthetic data (300W-LP) to minimize the distance between predicted and ground-truth landmarks.
Experiments and Results
The model was evaluated on the Annotated Facial Landmarks in the Wild (AFLW) and AFLW2000-3D datasets. AFLW2000-3D provides ground truth for occluded points using a 3D model.
Performance and Accuracy
- Speed: The 3DSTN achieves faster than real-time performance. An AlexNet-based version runs at ~170 FPS, while a VGG-16 version runs at ~52 FPS, significantly outperforming the state-of-the-art 3DDFA (~13 FPS).
- Accuracy: On AFLW2000-3D, the VGG-16 model achieved a Normalized Mean Error (NME) of 4.49%, compared to 5.42% for 3DDFA and 6.12% for SDM.
- Robustness: The model maintains semantic consistency even in extreme poses (60° to 90° yaw), as it fits a 3D mesh that accounts for occluded features.
Conclusion
The 3DSTN provides a robust and efficient framework for facial alignment in unconstrained poses. By bypassing the limitations of 3DMM and utilizing a single-pass architecture, it achieves state-of-the-art accuracy with real-time speed. Future work may address expression neutralization accuracy and extend the model from sparse landmarks to dense 3D face reconstruction.
Summary updated