Towards Universal Fake Image Detectors that Generalize Across Generative Models
Utkarsh Ojha, Yuheng Li, Yong Jae Lee
Abstract
With generative models proliferating at a rapid rate, there is a growing need for general purpose fake image detectors. In this work, we first show that the existing paradigm, which consists of training a deep network for real-vs-fake classification, fails to detect fake images from newer breeds of generative models when trained to detect GAN fake images. Upon analysis, we find that the resulting classifier is asymmetrically tuned to detect patterns that make an image fake. The real class becomes a 'sink' class holding anything that is not fake, including generated images from models not accessible during training. Building upon this discovery, we propose to perform real-vs-fake classification without learning; i.e., using a feature space not explicitly trained to distinguish real from fake images. We use nearest neighbor and linear probing as instantiations of this idea. When given access to the feature space of a large pretrained vision-language model, the very simple baseline of nearest neighbor classification has surprisingly good generalization ability in detecting fake images from a wide variety of generative models; e.g., it improves upon the SoTA [50] by +15.07 mAP and +25.90% acc when tested on unseen diffusion and autoregressive models. Our code, models, and data can be found at https://github .
Ask Lune
Know this paper in minutes, not an afternoon.
Lune can read every page of it and the top-tier papers that cite it, and gives you its claims, its evidence and its limits, each one cited to the paper it comes from. No skimming, no AI slop.
173 top-tier papers have cited it since. Know what they found before your reviewers do.
Lune can draw on
the full paper · the top-tier papers that cite it · related work
Free to start. No credit card required.
Lineage
- High-Resolution Image Synthesis with Latent Diffusion Models cites Diffusion Models Beat GANs on Image Synthesis
- High-Resolution Image Synthesis with Latent Diffusion Models cites Zero-Shot Text-to-Image Generation
- GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models cites Diffusion Models Beat GANs on Image Synthesis
- GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models cites Zero-Shot Text-to-Image Generation
- GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models cites Learning Transferable Visual Models From Natural Language Supervision
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites Frequency-Aware Deepfake Detection: Improving Generalizability through Frequency Space Domain Learning
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites High-Resolution Image Synthesis with Latent Diffusion Models
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites Diffusion Models Beat GANs on Image Synthesis
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites Zero-Shot Text-to-Image Generation
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake Detection
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake Detection cites Learning Transferable Visual Models From Natural Language Supervision
- Diffusion Models Beat GANs on Image Synthesis cites Zero-Shot Text-to-Image Generation
- Diffusion Models Beat GANs on Image Synthesis cites Learning Transferable Visual Models From Natural Language Supervision
- Zero-Shot Text-to-Image Generation cites Learning Transferable Visual Models From Natural Language Supervision
- Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake Detection cites High-Resolution Image Synthesis with Latent Diffusion Models
- Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake Detection cites GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models
- Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake Detection cites Diffusion Models Beat GANs on Image Synthesis
- Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake Detection cites Zero-Shot Text-to-Image Generation
- Spot the Fake: Large Multimodal Model-Based Synthetic Image Detection with Artifact Explanation cites Frequency-Aware Deepfake Detection: Improving Generalizability through Frequency Space Domain Learning
- Spot the Fake: Large Multimodal Model-Based Synthetic Image Detection with Artifact Explanation cites High-Resolution Image Synthesis with Latent Diffusion Models
- Spot the Fake: Large Multimodal Model-Based Synthetic Image Detection with Artifact Explanation cites Diffusion Models Beat GANs on Image Synthesis
- Spot the Fake: Large Multimodal Model-Based Synthetic Image Detection with Artifact Explanation cites Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake Detection
- Spot the Fake: Large Multimodal Model-Based Synthetic Image Detection with Artifact Explanation cites Learning Transferable Visual Models From Natural Language Supervision
- DRCT: Diffusion Reconstruction Contrastive Training towards Universal Detection of Diffusion Generated Images cites High-Resolution Image Synthesis with Latent Diffusion Models
- DRCT: Diffusion Reconstruction Contrastive Training towards Universal Detection of Diffusion Generated Images cites GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion Models
- DRCT: Diffusion Reconstruction Contrastive Training towards Universal Detection of Diffusion Generated Images cites Diffusion Models Beat GANs on Image Synthesis
- DRCT: Diffusion Reconstruction Contrastive Training towards Universal Detection of Diffusion Generated Images cites Learning Transferable Visual Models From Natural Language Supervision
Cited by top-tier papers173
- Frequency-Aware Deepfake Detection: Improving Generalizability through Frequency Space Domain LearningChuangchuang Tan, Yao Zhao, Shikui Wei, Guanghua Gu et al.AAAI 2024 · 232 citations
- Rethinking the Up-Sampling Operations in CNN-Based Generative Network for Generalizable Deepfake DetectionChuangchuang Tan, Huan Liu, Yao Zhao, Shikui Wei et al.CVPR 2024 · 126 citations
- DRCT: Diffusion Reconstruction Contrastive Training towards Universal Detection of Diffusion Generated ImagesBaoying Chen, Jishen Zeng, Jianquan Yang, Rui YangICML 2024 · 124 citations
- C2P-CLIP: Injecting Category Common Prompt in CLIP to Enhance Generalization in Deepfake DetectionChuangchuang Tan, Renshuai Tao, Huan Liu, Guanghua Gu et al.AAAI 2025 · 92 citations
- Spot the Fake: Large Multimodal Model-Based Synthetic Image Detection with Artifact ExplanationSiwei Wen, Junyan Ye, Peilin Feng, Hengrui Kang et al.NeurIPS 2025 · 82 citations
Builds on16
- Learning Transferable Visual Models From Natural Language SupervisionAlec Radford, Jong Wook Kim, Chris Hallacy, Aditya Ramesh et al.ICML 2021 · 47,906 citations
- Diffusion Models Beat GANs on Image SynthesisPrafulla Dhariwal, Alexander Quinn NicholNeurIPS 2021 · 13,211 citations
- High-Resolution Image Synthesis with Latent Diffusion ModelsRobin Rombach, Andreas Blattmann, Dominik Lorenz, Patrick Esser et al.CVPR 2022 · 13,123 citations
- Zero-Shot Text-to-Image GenerationAditya Ramesh, Mikhail Pavlov, Gabriel Goh, Scott Gray et al.ICML 2021 · 6,356 citations
- GLIDE: Towards Photorealistic Image Generation and Editing with Text-Guided Diffusion ModelsAlexander Quinn Nichol, Prafulla Dhariwal, Aditya Ramesh, Pranav Shyam et al.ICML 2022 · 4,691 citations
Related papers
- CNN-Generated Images Are Surprisingly Easy to Spot... for NowSheng-Yu Wang, Oliver Wang, Richard Zhang, Andrew Owens et al.CVPR 2020
- Learning on Gradients: Generalized Artifacts Representation for GAN-Generated Images DetectionChuangchuang Tan, Yao Zhao, Shikui Wei, Guanghua Gu et al.CVPR 2023
- Improving Synthesized Image Detection by Disentangling Generator-Shared and Generator-Specific Image ArtifactsYongqi Yang, Yuke Li, Heng Huang, Zhihui Li, Bo Du, Yu WuCVPR Findings 2026 · 1 citation
- FakeInversion: Learning to Detect Images from Unseen Text-to-Image Models by Inverting Stable DiffusionGeorge Cazenavette, Avneesh Sud, Thomas Leung, Ben UsmanCVPR 2024
- FrePGAN: Robust Deepfake Detection Using Frequency-Level PerturbationsYonghyun Jeong, Doyeon Kim, Youngmin Ro, Jongwon ChoiAAAI 2022 · 159 citations
