📰 AI 资讯

Beyond Perceptual Distance: Discrepancy Assessment on Deep Representation for Out-of-Distribution Detection with Diffusion Model

2026-07-15 04:00

arXiv:2409.10094v3 Announce Type: replace Abstract: Out-of-Distribution (OoD) detection aims to justify whether a given sample is from the training distribution of the classifier-under-protection, i.e., In-Distribution (InD), or from an unknown out distribution. Recent researches have leveraged Diffusion Models (DMs) for OoD detection due to their powerful distribution modeling capability. Given an input image, an InD-pretrained DM produces a corresponding InD-aligned counterpart, which serves as a generative reference for comparison. However, existing DM-based methods typically assess this underlying discrepancy through visual-level distances in the raw image space, which may be misaligned with the distributional discrepancy relevant to OoD detection. In this work, we investigate the fundamentals of discrepancy assessment in DM-based OoD detection, asking how the discrepancy between an input and its DM-generated counterpart should be formulated, and in which representation spaces and with which metrics it should be measured. To this end, we propose to assess the discrepancy in a classifier-relative manner by exploiting the representation spaces of the classifier-under-protection, whose training on InD data encodes rich task-relevant InD knowledge. In particular, we quantify two types of discrepancy: feature-level covariate discrepancy in deep feature representations and logit-level concept discrepancy in output logits, enabling effective differentiation between InD and OoD samples. Moreover, a subspace-based strategy is devised to refine representations of the DM generation to promote discrepancy assessment. Together, these designs form our novel detection framework, namely DDR. Extensive experiments on the challenging large-scale ImageNet-1K dataset demonstrate the superior detection performance of DDR over both DM-based and non-DM-based methods.