Dual-Granularity Contrastive Learning for DeepFake Detection
Abstract
In recent years, contrastive learning has made significant progress in DeepFake detection. However, existing methods emphasize class granularity, and it is difficult to distinguish between the real instance and its forgery counterparts effectively. Furthermore, the diversity of forgery cues produced by different manipulation methods cannot be effectively clustered by class granularity alone. Thus, the model’s generalization capability is limited. To tackle the above problems, a Dual-Granularity Contrastive Learning (DGCL) for DeepFake detection is proposed in this paper. Specifically, Class Granularity Contrastive Learning (CGCL) and Instance Granularity Contrastive Learning (IGCL) are designed. Firstly, for semantic aggregation at the class level, CGCL incorporates the class prototype, which encourages anchor approaches to the prototype of the positive class, thereby pulling the intra-class features closer. Secondly, for distinguishing between real and fake instances, Real Instance Granularity Contrastive Learning (RIGCL) and Fake Instance Granularity Contrastive Learning (FIGCL) are proposed based on the instance characteristics. RIGCL endeavors to distinguish fake instances from original real instances by expanding the differentiation in the feature space. Meanwhile, FIGCL extracts consistent forgery features from various manipulation methods using cosine similarity constraints. Finally, the superiority and generalizability of DGCL are validated by the experimental results on CELEBDF, DFD, and DFDC datasets.
Fields of Study & Subjects
Domain Adaptation and Few-Shot Learning
Adversarial Robustness in Machine Learning
Generative Adversarial Networks and Image Synthesis
Publication details
- Journal / source
- IEEE Transactions on Information Forensics and Security
- Publisher
- Institute of Electrical and Electronics Engineers (IEEE)
- Volume
- 21
- Pages
- 1552–1565
- Publication date
- 1 January 2026