Table of Contents
Fetching ...

Diffusion Epistemic Uncertainty with Asymmetric Learning for Diffusion-Generated Image Detection

Yingsong Huang, Hui Guo, Jing Huang, Bing Bai, Qi Xiong

TL;DR

This paper addresses the challenge of detecting diffusion-generated images beyond reconstruction error by separating epistemic from aleatoric uncertainty. It introduces Diffusion Epistemic Uncertainty with Asymmetric Learning (DEUA), which estimates epistemic uncertainty in diffusion models via last-layer Laplace approximation and trains a classifier with an asymmetric learning objective that yields larger margins for better generalization. By fusing DEU-based features with CLIP visual representations in a two-stage framework, DEUA achieves state-of-the-art generalization across multiple diffusion generators and large-scale datasets (GenImage and DRCT-2M), including cross-generator and cross-dataset scenarios. The work demonstrates that focusing on epistemic uncertainty in the diffusion process, coupled with asymmetric learning, provides a robust, source-agnostic signal for detecting diffusion-generated images and can be integrated into broader deepfake detection pipelines.

Abstract

The rapid progress of diffusion models highlights the growing need for detecting generated images. Previous research demonstrates that incorporating diffusion-based measurements, such as reconstruction error, can enhance the generalizability of detectors. However, ignoring the differing impacts of aleatoric and epistemic uncertainty on reconstruction error can undermine detection performance. Aleatoric uncertainty, arising from inherent data noise, creates ambiguity that impedes accurate detection of generated images. As it reflects random variations within the data (e.g., noise in natural textures), it does not help distinguish generated images. In contrast, epistemic uncertainty, which represents the model's lack of knowledge about unfamiliar patterns, supports detection. In this paper, we propose a novel framework, Diffusion Epistemic Uncertainty with Asymmetric Learning~(DEUA), for detecting diffusion-generated images. We introduce Diffusion Epistemic Uncertainty~(DEU) estimation via the Laplace approximation to assess the proximity of data to the manifold of diffusion-generated samples. Additionally, an asymmetric loss function is introduced to train a balanced classifier with larger margins, further enhancing generalizability. Extensive experiments on large-scale benchmarks validate the state-of-the-art performance of our method.

Diffusion Epistemic Uncertainty with Asymmetric Learning for Diffusion-Generated Image Detection

TL;DR

This paper addresses the challenge of detecting diffusion-generated images beyond reconstruction error by separating epistemic from aleatoric uncertainty. It introduces Diffusion Epistemic Uncertainty with Asymmetric Learning (DEUA), which estimates epistemic uncertainty in diffusion models via last-layer Laplace approximation and trains a classifier with an asymmetric learning objective that yields larger margins for better generalization. By fusing DEU-based features with CLIP visual representations in a two-stage framework, DEUA achieves state-of-the-art generalization across multiple diffusion generators and large-scale datasets (GenImage and DRCT-2M), including cross-generator and cross-dataset scenarios. The work demonstrates that focusing on epistemic uncertainty in the diffusion process, coupled with asymmetric learning, provides a robust, source-agnostic signal for detecting diffusion-generated images and can be integrated into broader deepfake detection pipelines.

Abstract

The rapid progress of diffusion models highlights the growing need for detecting generated images. Previous research demonstrates that incorporating diffusion-based measurements, such as reconstruction error, can enhance the generalizability of detectors. However, ignoring the differing impacts of aleatoric and epistemic uncertainty on reconstruction error can undermine detection performance. Aleatoric uncertainty, arising from inherent data noise, creates ambiguity that impedes accurate detection of generated images. As it reflects random variations within the data (e.g., noise in natural textures), it does not help distinguish generated images. In contrast, epistemic uncertainty, which represents the model's lack of knowledge about unfamiliar patterns, supports detection. In this paper, we propose a novel framework, Diffusion Epistemic Uncertainty with Asymmetric Learning~(DEUA), for detecting diffusion-generated images. We introduce Diffusion Epistemic Uncertainty~(DEU) estimation via the Laplace approximation to assess the proximity of data to the manifold of diffusion-generated samples. Additionally, an asymmetric loss function is introduced to train a balanced classifier with larger margins, further enhancing generalizability. Extensive experiments on large-scale benchmarks validate the state-of-the-art performance of our method.
Paper Structure (21 sections, 1 theorem, 15 equations, 5 figures, 6 tables)

This paper contains 21 sections, 1 theorem, 15 equations, 5 figures, 6 tables.

Key Result

Lemma 1

The epistemic uncertainty in the diffusion model $\boldsymbol{\epsilon}_\theta(\mathbf{x}_t, t)$ is captured by

Figures (5)

  • Figure 1: Distribution of diffusion reconstruction error, aleatoric uncertainty, and epistemic uncertainty in real and generated samples. (a) The reconstruction error distribution for real samples overlaps with that of fake samples due to the presence of aleatoric uncertainty. (b) The distribution of aleatoric uncertainty is nearly indistinguishable between real and fake samples. (c) Epistemic uncertainty more accurately distinguishes real samples from fake ones.
  • Figure 2: Diffusion Reconstruction error and predictive ambiguity (1000 images are used) due to aleatoric uncertainty. The difference in reconstruction error becomes less significant when compared to the standard deviation caused by aleatoric uncertainty.
  • Figure 3: Workflow of our method. In the first stage, we utilize the Laplace approximation to estimate diffusion epistemic uncertainty. In the second stage, we exploit diffusion epistemic uncertainty to train a binary classifier with asymmetric learning.
  • Figure 4: Results of cross-validation on GenImage. We train eight models on eight subsets respectively, each corresponding to a different generator. For both LaRE2 and our method, accuracy (ACC, %) and average precision (AP, %) are reported.
  • Figure 5: Influence of sample step $t$ and margin $m^0$.

Theorems & Definitions (1)

  • Lemma 1