Table of Contents
Fetching ...

R$^2$BD: A Reconstruction-Based Method for Generalizable and Efficient Detection of Fake Images

Qingyu Liu, Zhongjie Ba, Jianmin Guo, Qiu Wang, Zhibo Wang, Jie Shi, Kui Ren

TL;DR

R^2BD tackles the dual challenges of generalization and efficiency in fake image detection by introducing G-LDM, a unified reconstruction model that bridges GANs, VAEs, and diffusion pathways, and a residual bias mechanism that enables single-step detection. The approach combines one-step residual bias signals in both RGB and latent spaces with a lightweight two-stream classifier, achieving rapid inference (~0.706 s per image) while delivering strong cross-paradigm performance. Across extensive benchmarks spanning GANs, pixel-space diffusion, and latent-diffusion models, R^2BD demonstrates superior generalization (especially under hybrid training) and robustness to common degradations, addressing a key practical bottleneck of prior reconstruction-based detectors. The work provides a scalable, cross-paradigm detection framework with significant implications for real-time AIGC forensics and content authentication.

Abstract

Recently, reconstruction-based methods have gained attention for AIGC image detection. These methods leverage pre-trained diffusion models to reconstruct inputs and measure residuals for distinguishing real from fake images. Their key advantage lies in reducing reliance on dataset-specific artifacts and improving generalization under distribution shifts. However, they are limited by significant inefficiency due to multi-step inversion and reconstruction, and their reliance on diffusion backbones further limits generalization to other generative paradigms such as GANs. In this paper, we propose a novel fake image detection framework, called R$^2$BD, built upon two key designs: (1) G-LDM, a unified reconstruction model that simulates the generation behaviors of VAEs, GANs, and diffusion models, thereby broadening the detection scope beyond prior diffusion-only approaches; and (2) a residual bias calculation module that distinguishes real and fake images in a single inference step, which is a significant efficiency improvement over existing methods that typically require 20$+$ steps. Extensive experiments on the benchmark from 10 public datasets demonstrate that R$^2$BD is over 22$\times$ faster than existing reconstruction-based methods while achieving superior detection accuracy. In cross-dataset evaluations, it outperforms state-of-the-art methods by an average of 13.87\%, showing strong efficiency and generalization across diverse generative methods. The code and dataset used for evaluation are available at https://github.com/QingyuLiu/RRBD.

R$^2$BD: A Reconstruction-Based Method for Generalizable and Efficient Detection of Fake Images

TL;DR

R^2BD tackles the dual challenges of generalization and efficiency in fake image detection by introducing G-LDM, a unified reconstruction model that bridges GANs, VAEs, and diffusion pathways, and a residual bias mechanism that enables single-step detection. The approach combines one-step residual bias signals in both RGB and latent spaces with a lightweight two-stream classifier, achieving rapid inference (~0.706 s per image) while delivering strong cross-paradigm performance. Across extensive benchmarks spanning GANs, pixel-space diffusion, and latent-diffusion models, R^2BD demonstrates superior generalization (especially under hybrid training) and robustness to common degradations, addressing a key practical bottleneck of prior reconstruction-based detectors. The work provides a scalable, cross-paradigm detection framework with significant implications for real-time AIGC forensics and content authentication.

Abstract

Recently, reconstruction-based methods have gained attention for AIGC image detection. These methods leverage pre-trained diffusion models to reconstruct inputs and measure residuals for distinguishing real from fake images. Their key advantage lies in reducing reliance on dataset-specific artifacts and improving generalization under distribution shifts. However, they are limited by significant inefficiency due to multi-step inversion and reconstruction, and their reliance on diffusion backbones further limits generalization to other generative paradigms such as GANs. In this paper, we propose a novel fake image detection framework, called RBD, built upon two key designs: (1) G-LDM, a unified reconstruction model that simulates the generation behaviors of VAEs, GANs, and diffusion models, thereby broadening the detection scope beyond prior diffusion-only approaches; and (2) a residual bias calculation module that distinguishes real and fake images in a single inference step, which is a significant efficiency improvement over existing methods that typically require 20 steps. Extensive experiments on the benchmark from 10 public datasets demonstrate that RBD is over 22 faster than existing reconstruction-based methods while achieving superior detection accuracy. In cross-dataset evaluations, it outperforms state-of-the-art methods by an average of 13.87\%, showing strong efficiency and generalization across diverse generative methods. The code and dataset used for evaluation are available at https://github.com/QingyuLiu/RRBD.
Paper Structure (27 sections, 15 equations, 8 figures, 6 tables)

This paper contains 27 sections, 15 equations, 8 figures, 6 tables.

Figures (8)

  • Figure 1: Illustration for observations and problems of existing works. a) Feature extraction-based works rely on the forgery features on the training dataset (e.g., StyleGAN and StarGAN), which are difficult to generalize to detecting ProGAN-based images. b) Existing reconstruction-based methods employ diffusion models for reconstruction, which results in large residuals for both GAN-generated and real images, increasing the risk of misclassification. c) Our G-LDM integrates the principles of diffusion models and GANs, enabling it to reconstruct images of diverse generative paths with smaller residuals.
  • Figure 2: Overview of the R$^2$BD inference pipeline. Given an input image, we perform one-step DDIM inversion and reconstruction using the pre-trained G-LDM to compute residual bias in both latent and RGB spaces. The two residual bias features are then fed into a two-stream classifier to predict whether the image is real or fake.
  • Figure 3: The training process of G-LDM model. Diffusion generator and discriminator training iterative alternating training.
  • Figure 4: UMAP mcinnes2018umap visualization of real vs. fake features at step 1 and step 20. (a) Existing methods using measured residuals show poor separability at step 1, requiring multiple steps to distinguish real from fake. (b) Our residual bias features exhibit clear separation even at step 1, enabling efficient and effective detection.
  • Figure 5: The visualisation results of the proposed R$^2$BD and related works.
  • ...and 3 more figures