Suppressing Gradient Conflict for Generalizable Deepfake Detection

Ming-Hui Liu, Harry Cheng, Xin Luo, Xin-Shun Xu

TL;DR

Deepfake detection models often suffer from a counterintuitive "1+1 < 2" performance drop when trained jointly on original dataset forgeries and online synthesized data. This paper identifies this issue as a consequence of severe gradient conflicts during backpropagation and introduces the Conflict-Suppressed Deepfake Detection (CS-DFD) framework to resolve it. By dynamically aligning parameter updates and feature embeddings, CS-DFD achieves state-of-the-art accuracy across both source and completely unseen target domains.

What Problem Does This Paper Address?

Deepfake detection models typically excel when tested on the same dataset they were trained on (in-domain), but their performance plummets when encountering new, unseen manipulation techniques (cross-domain generalization). To improve robustness, a common strategy is to augment training data with online synthesized fake images (e.g., using self-blending techniques) that expose the model to more generalized forgery artifacts.

However, doing this introduces a frustrating paradox: if you replace the original fakes with synthesized ones, the model forgets how to detect the original dataset's forgeries. If you try to train on both types of fakes simultaneously, the model's performance degrades on either the source or target domain. The authors trace this "1+1 < 2" phenomenon to gradient conflicts. Because original forgeries and synthesized forgeries present fundamentally different artifact distributions, the model attempts to follow contradictory learning logics, leading to highly unstable optimization paths.

Different training strategies and their trade-offs.

Methods

The authors propose the Conflict-Suppressed Deepfake Detection (CS-DFD) framework, which mitigates gradient interference through two synergistic modules:

  1. Update Vector Search (UVS) Module: Instead of simply averaging or summing the conflicting gradients from the two data streams, UVS reformulates backpropagation as a constrained optimization problem. It searches the neighborhood of the initial gradient to find a single, conflict-free update vector that guarantees simultaneous loss reduction for both original and synthesized data streams.
  2. Conflict Gradient Reduction (CGR) Module: Optimization adjustments alone aren't always enough to prevent the loss of specific discriminative features. CGR introduces a novel Conflict Descent Loss ($L_\phi$) applied to a learnable feature projection layer right before the classifier. This loss penalizes misaligned gradient directions, guiding the network to map heterogeneous features into a shared, low-conflict embedding space.
Overall architecture of the proposed CS-DFD framework.

Datasets

  • Training Dataset: FaceForensics++ (FF++), a standard benchmark containing 1,000 real videos and 5,000 fake videos generated via five distinct manipulation methods (Deepfakes, FaceSwap, Face2Face, FaceShifter, and NeuralTextures).
  • Testing Datasets (Target Domains): To evaluate cross-domain generalization, the authors tested the model on four unseen datasets: Celeb-DF, DFDC, DFDCp, and UADFV.

Key Insights and Ideas

  • Internal Task Conflicts: While gradient conflict is a well-known hurdle in multi-task learning, this paper highlights that it can severely disrupt single-task learning when the training data is heterogeneous.
  • Visualizing the Tug-of-War: The authors empirically demonstrate the adversarial nature of joint training. As shown in their loss trend analysis, when the model successfully minimizes the loss for online synthesized fakes, the loss for original fakes simultaneously spikes, and vice versa.
  • Smoothing the Loss Landscape: By applying UVS and CGR, the chaotic, oscillatory optimization path of a standard backbone network is transformed into a smooth, stable descent toward a global optimum (visualized via vector fields in the paper).

Key Results

  • Best of Both Worlds: CS-DFD achieved an average Area Under the Curve (AUC) of 88.02% across the four unseen target datasets while maintaining a stellar 98.88% AUC on the source dataset (FF++).
  • Outperforming the Baselines: Traditional models trained only on original data overfit (e.g., EfficientNet drops to a 68.37% average target AUC). Conversely, models trained purely on synthesized data fail on the source domain (e.g., SBI drops to 85.16% on FF++). CS-DFD comfortably beats both paradigms.
  • Architecture Agnostic: The framework was validated using multiple backbones, including Xception, ViT-L, and ViT-B. In every case, CS-DFD eliminated the "1+1 < 2" degradation.
  • Stable Feature Attention: Feature activation heatmaps reveal that CS-DFD maintains highly stable and broader forensic attention regions across different domains, whereas standard joint training leads to confused, erratic attention patterns.
Heatmap comparison showing stable attention regions for CS-DFD across domains.

Limitations and Future Work

The authors demonstrate that CS-DFD is highly efficient, adding only a negligible 2% computational overhead to standard training times. However, the paper primarily focuses on spatial image-level blending artifacts. A potential limitation is how well this method scales to video-level temporal inconsistencies or highly advanced, full-frame generative models (like recent diffusion-based video generation). The authors suggest that exploring conflict suppression in multi-modal settings or temporal deepfake detection remains an open and promising direction.

Summary updated

BibTeX
@article{liu2026suppressing,
  author = {Ming-Hui Liu and Harry Cheng and Xin Luo and Xin-Shun Xu},
  title = {{Suppressing Gradient Conflict for Generalizable Deepfake Detection}},
  journal = {IEEE Trans. Pattern Anal. Mach. Intell.},
  year = {2026},
  doi = {10.1109/tpami.2026.3687009},
}
Figure