A Generative Framework for Self-Supervised Facial Representation Learning

Ruian He, Zhen Xing, Weimin Tan, Bo Yan

TL;DR

LatentFace is a novel self-supervised generative framework that disentangles facial identity and expression by combining 3D-aware autoencoding with latent diffusion models. By treating identity as a time-invariant component learned from unlabeled videos, it achieves state-of-the-art performance in facial expression recognition and face verification, significantly outperforming traditional contrastive learning methods.

What Problem Does This Paper Address?

Facial representation learning is a "coupling" nightmare. A single image of a face is a complex blend of identity, emotional expression, head pose, and environmental lighting. Standard supervised methods require massive, labor-intensively labeled datasets that often suffer from class imbalance.

Existing self-supervised approaches, like contrastive learning, try to solve this by clustering similar images, but they often lack interpretability and struggle with "spatial awareness"—they fail when a face turns sharply or when lighting changes drastically. Furthermore, they often fail to truly separate the who (identity) from the how (expression) at a deep semantic level.

Methods

The authors propose a two-stage generative framework that moves beyond simple 2D pixel-warping to a 3D-aware latent space.

  1. 3D Latent Autoencoding (Spatial Disentanglement): The model first decomposes a face image into four distinct 3D factors: Texture, Shape, Pose, and Light. Using a differentiable renderer, it learns to reconstruct the input image from these factors without any labels. This stage ensures the model understands the underlying 3D structure of the face, making it robust to rotations and shadows.
  2. Latent Space Disentangling via RDM (Temporal Disentanglement): To separate identity from expression, the authors introduce a Representation Diffusion Model (RDM). They leverage a clever observation: in a short video clip of a person, the identity is constant (time-invariant), while the expression changes.
  3. The model treats the average latent embedding of a video sequence as the "Identity" ($Z_{id}$).
  4. The RDM is trained to generate this clean identity latent from a noisy version, conditioned on the "Expression" latent ($Z_{exp}$) from a specific frame.
  5. During inference, the "Expression Bias" is simply the difference between the original latent and the generated identity latent.
Figure 1: Comparison of different learning paradigm. Our generative framework enables better spatial-temporal awareness and more thorough representation disentangling than previous contrastive learning methods.

Datasets

  • Training:
    • CelebA: Used for the first stage (3D autoencoding) to learn general face structures.
  • VoxCeleb: Used for the second stage (RDM) to leverage temporal information from video sequences.
  • Evaluation:
    • RAF-DB & AffectNet: Benchmarks for Facial Expression Recognition (FER).
  • LFW & SLLFW: Benchmarks for Face Verification (determining if two images are the same person).

Key Insights and Ideas

  • Generative > Contrastive: Instead of just saying "these two faces are similar," the model learns to construct the face. This makes the learned representations highly interpretable—you can literally visualize the "identity-only" version of a smiling face.
  • Identity as a Statistical Mean: By defining identity as the time-invariant part of a video, the model bypasses the need for identity labels entirely. It learns that whatever doesn't change across frames is the person's core appearance.
  • 3D Awareness for 2D Tasks: Explicitly modeling 3D shape and lighting allows the model to "normalize" faces (e.g., frontalizing a side-view face) far more effectively than 2D methods, leading to much better performance on "in-the-wild" images with varied poses.
Overview of the LatentFace framework

Key Results

LatentFace sets a new high-water mark for self-supervised facial analysis:

  • Facial Expression Recognition (FER): Achieved 75.26% accuracy on RAF-DB and 44.42% on AffectNet, representing a 3.75% and 3.35% improvement over previous state-of-the-art (SOTA) unsupervised methods, respectively.
  • Face Verification: Outperformed all unsupervised competitors on LFW (72.05%) and SLLFW (59.72%).
  • Qualitative Fidelity: As seen in Figure 4, LatentFace produces much cleaner and more detailed disentangled representations (texture vs. shape) compared to previous methods like FaceCycle.

Limitations and Future Work

  • Extreme Occlusion: While the model handles head rotations up to 60 degrees well, extreme "profile" views (near 90 degrees) remain a challenge due to the loss of visual information (occlusion).
  • Privacy Risks: The authors acknowledge that the high-fidelity reconstruction of facial shape and texture could be misused for deepfake generation. They suggest that for real-world privacy-sensitive applications, the decoder components of the model should be removed.
  • Future Directions: The authors suggest that balancing the downstream datasets (which are currently skewed toward "neutral" expressions) could further boost accuracy.

Summary updated

BibTeX
@misc{he2023generative,
  author = {Ruian He and Zhen Xing and Weimin Tan and Bo Yan},
  title = {{A Generative Framework for Self-Supervised Facial Representation Learning}},
  year = {2023},
  eprint = {2309.08273},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2309.08273},
}
Figure