ODDN: Addressing Unpaired Data Challenges in Open-World Deepfake Detection on Online Social Networks

Renshuai Tao, Manyi Le, Chuangchuang Tan, Huan Liu, Haotong Qin, Yao Zhao

Introduction

Deepfake detection faces a significant hurdle on Online Social Networks (OSNs). When AI-generated images are uploaded to platforms like Twitter or WeChat, they undergo heavy compression. This process degrades image quality and obscures the subtle digital artifacts that detectors rely on. Most current state-of-the-art methods depend on paired data—datasets where every compressed image has a corresponding raw original. However, in real-world "open-world" scenarios, such pairs are virtually non-existent.

Conceptual overview of the open-world deepfake detection challenge and the performance advantage of ODDN.

The Open-World Challenge

The scarcity of high-quality originals for compressed social media images creates a massive data imbalance. While compressed images are abundant (unpaired data), their raw counterparts are rare. Traditional models trained primarily on paired data struggle when faced with the diverse and unknown compression levels found in the wild. The Open-world Deepfake Detection Network (ODDN) is designed to bridge this gap by effectively utilizing the vast amount of available unpaired data.

Methodology: The ODDN Framework

ODDN introduces two core modules to handle the complexities of open-world data:

1. Open-world Data Aggregation (ODA)

The ODA module is designed to train on a mixture of 20% paired and 80% unpaired data. For paired data, it employs the Hilbert-Schmidt Independence Criterion (HSIC) to identify fine-grained correlations between raw and compressed versions. For the more abundant unpaired data, ODA uses a "coarse-grained" clustering approach. It calculates aggregation centers for four categories: real, compressed-real, fake, and compressed-fake. A specialized distance loss is then applied to maximize the separation between "real" and "fake" clusters, ensuring the model remains robust regardless of compression state.

2. Compression-discard Gradient Correction (CGC)

The CGC module utilizes adversarial learning to force the model to ignore compression-related features, which often act as a bias. By treating compression as a "fingerprint" to be discarded, the model can focus exclusively on forgery artifacts. To manage the potential conflict between the detection task and the compression-discarding task, ODDN incorporates PCGrad (Projected Conflicting Gradients). This ensures that training directions for these two goals are aligned, preventing model confusion and promoting stable convergence.

The ODDN architecture, highlighting the Compression-discard Gradient Correction (CGC) and Open-world Data Aggregation (ODA) modules.

Experimental Results

ODDN was evaluated against 17 popular deepfake datasets, including ForenSynths and various GAN-based generators like StyleGAN and CycleGAN. The framework consistently outperformed state-of-the-art baselines such as QAD and SBIs.

  • Quality-Aware Inference: When test compression matched training conditions, ODDN achieved a mean accuracy between 71.4% and 72.6%.
  • Quality-Agnostic Inference: In unpredictable open-world scenarios with random compression levels, ODDN maintained a high mean accuracy of 70.7% to 72.1%.

Visual analysis using t-SNE confirmed that ODDN produces a much clearer separation between real and fake features in latent space compared to baseline models, which often fail to distinguish between compressed real and compressed fake images.

Conclusion

ODDN represents a significant step forward in making deepfake detection practical for social media. By leveraging unpaired data and explicitly correcting for compression bias, it achieves superior robustness in open-world environments. Future work will look into extending this framework to handle temporal compression in video deepfakes and other social media distortions like resizing and blurring.

Summary updated

Abstract

Despite significant advances in deepfake detection, handling varying image quality, especially due to different compressions on online social networks (OSNs), remains challenging. Current methods succeed by leveraging correlations between paired images, whether raw or compressed. However, in open-world scenarios, paired data is scarce, with compressed images readily available but corresponding raw versions difficult to obtain. This imbalance, where unpaired data vastly outnumbers paired data, often leads to reduced detection performance, as existing methods struggle without corresponding raw images. To overcome this issue, we propose a novel approach named the open-world deepfake detection network (ODDN), which comprises two core modules: open-world data aggregation (ODA) and compression-discard gradient correction (CGC). ODA effectively aggregates correlations between compressed and raw samples through both fine-grained and coarse-grained analyses for paired and unpaired data, respectively. CGC incorporates a compression-discard gradient correction to further enhance performance across diverse compression methods in OSN. This technique optimizes the training gradient to ensure the model remains insensitive to compression variations. Extensive experiments conducted on 17 popular deepfake datasets demonstrate the superiority of the ODDN over SOTA baselines.
BibTeX
@inproceedings{tao2025oddn,
  author = {Renshuai Tao and Manyi Le and Chuangchuang Tan and Huan Liu and Haotong Qin and Yao Zhao},
  title = {{ODDN: Addressing Unpaired Data Challenges in Open-World Deepfake Detection on Online Social Networks}},
  booktitle = {AAAI Conference on Artificial Intelligence},
  year = {2025},
  doi = {10.1609/aaai.v39i1.32063},
}
Figure