Deepfakes Detection with Automatic Face Weighting

Daniel Mas Montserrat, Hanxiang Hao, Sri Kalyan Yarlagadda, Sriram Baireddy, Ruiting Shao, János Horváth, Emily R. Bartusiak, Justin Yang, David Guera, Fengqing Zhu, Edward J. Delp · DOI

Researchers at Purdue University’s VIPER lab have developed a robust pipeline for identifying AI-generated facial manipulations. Created for the Deepfake Detection Challenge (DFDC), this method moves beyond simple frame-by-frame classification by intelligently weighting the reliability of detected faces and modeling temporal inconsistencies.

Abstract

As deepfake generation tools like Generative Adversarial Networks (GANs) and Auto-Encoders become more sophisticated, the "arms race" between creators and detectors intensifies. This paper addresses the technical bottleneck of frame aggregation in video detection. By introducing Automatic Face Weighting (AFW) and a Boosting Network, the proposed system prioritizes informative frames and ignores low-quality data, achieving a top 6% ranking on the global DFDC leaderboard.

Introduction

Most existing deepfake detection models perform well on controlled research datasets but struggle with "in-the-wild" data characterized by varying lighting, low resolution, or heavy compression. A significant challenge is that most detectors analyze individual frames and then simply average the results. In a typical video, many frames may be blurry or contain false face detections. Simple averaging allows these "noisy" frames to degrade the final score.

Comparison between an original video frame and its deepfake counterpart.

Methodology

The proposed multi-stage pipeline is designed to automatically prioritize the most informative frames while capturing temporal artifacts.

1. Face Detection and Feature Extraction

The system uses MTCNN to locate and crop faces, including a 20-pixel margin to capture artifacts near the hairline. Features are extracted using EfficientNet-b5 trained with ArcFace loss (Additive Angular Margin Loss). This loss function forces the model to map "real" and "fake" faces into highly distinct clusters in a hypersphere, enhancing separability.

2. Automatic Face Weighting (AFW)

The "secret sauce" of this approach is an attention-like layer that learns to assign a weight ($w_j$) to every detected face. If a frame is blurry or the detection confidence is low, the AFW layer down-weights its contribution to the final video-level prediction.

3. Temporal Modeling and Boosting

Features are fed into a Gated Recurrent Unit (GRU) to detect flickering or unnatural movements across frames. During testing, a secondary "replica" network (the Boosting Network) estimates the potential error of the main network, acting as a "second opinion" to smooth out overconfident but incorrect predictions.

The complete detection pipeline architecture, including the AFW mechanism and the Boosting Network.

Experimental Results

The model was evaluated on the Deepfake Detection Challenge (DFDC) dataset, which contains over 123,000 videos with diverse backgrounds and manipulation types.

  • Accuracy: The final model achieved a 91.88% balanced accuracy on the DFDC test set.
  • Ablation Study: Moving from raw logits (85.51%) to the full GRU-based pipeline (92.61%) demonstrated the critical importance of temporal modeling.
  • Competition Standing: The method achieved a log-likelihood score of 0.321, placing the team at position 117 out of 2,275 teams (top 6%) in the public DFDC leaderboard.
  • Efficiency: The system processes a video in less than eight seconds on a single GPU.

Conclusion and Future Work

The AFW mechanism proves that learning which frames to trust is as vital as the classification itself. While highly effective, the authors note that future iterations could be improved by incorporating audio analysis to detect cloned voices. Additionally, as forgery techniques evolve, the modular nature of this pipeline allows for the integration of newer CNN backbones to maintain detection efficacy.

Summary updated

BibTeX
@inproceedings{montserrat2020deepfakes,
  author = {Daniel Mas Montserrat and Hanxiang Hao and Sri Kalyan Yarlagadda and Sriram Baireddy and Ruiting Shao and János Horváth and Emily R. Bartusiak and Justin Yang and David Guera and Fengqing Zhu and Edward J. Delp},
  title = {{Deepfakes Detection with Automatic Face Weighting}},
  booktitle = {Workshops @ CVPR},
  year = {2020},
  doi = {10.1109/cvprw50498.2020.00342},
}
Figure