用扩散模型分层重建特征,无监督识别异常数据
Diffusion-based Layer-wise Semantic Reconstruction for Unsupervised Out-of-Distribution Detection
- 分层提取特征并加噪声,用扩散模型重建以区分正常与异常
- 在多个数据集上达到当前最优检测精度和速度
- 适合需要安全部署的实时机器学习系统
无监督分布外(OOD)检测旨在仅通过无标签的分布内(ID)训练样本识别分布外数据,对构建安全的实际机器学习系统至关重要。现有基于重建的方法通过测量输入与其生成对应物在像素/特征空间中的重建误差来实现。然而,这类生成方法面临关键矛盾:提升生成模型重建能力的同时保持对ID数据的紧凑表示。为此,我们提出基于扩散模型的分层语义重建方法用于无监督OOD检测。该方法利用扩散模型固有的数据重建能力,在潜在特征空间中区分ID与OOD样本。为建立全面且具有判别性的特征表示,我们设计多层语义特征提取策略。通过向提取特征添加高斯噪声,并使用扩散模型进行特征重建,根据重建误差实现ID与OOD样本的分离。在多个基于不同数据集的基准测试上,实验结果表明本方法在检测准确率和速度方面均达到当前最优水平。代码已公开于https://github.com/xbyym/DLSR。
原文摘要 · Abstract (English)
Unsupervised out-of-distribution (OOD) detection aims to identify out-of-domain data by learning only from unlabeled In-Distribution (ID) training samples, which is crucial for developing a safe real-world machine learning system. Current reconstruction-based methods provide a good alternative approach by measuring the reconstruction error between the input and its corresponding generative counterpart in the pixel/feature space. However, such generative methods face a key dilemma: improving the reconstruction power of the generative model while keeping a compact representation of the ID data. To address this issue, we propose the diffusion-based layer-wise semantic reconstruction approach for unsupervised OOD detection. The innovation of our approach is that we leverage the diffusion model's intrinsic data reconstruction ability to distinguish ID samples from OOD samples in the latent feature space. Moreover, to set up a comprehensive and discriminative feature representation, we devise a multi-layer semantic feature extraction strategy. By distorting the extracted features with Gaussian noise and applying the diffusion model for feature reconstruction, the separation of ID and OOD samples is implemented according to the reconstruction errors. Extensive experimental results on multiple benchmarks built upon various datasets demonstrate that our method achieves state-of-the-art performance in terms of detection accuracy and speed. Code is available at <https://github.com/xbyym/DLSR>.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。