arXiv:2506.17633cs.CVcs.AI2025-06ICML被引 16

用自适应提示增强少样本分布外检测,提升模型泛化能力。

Adaptive Multi-prompt Contrastive Network for Few-shot Out-of-distribution Detection

  • 通过可学习的文本提示构建类内类间分布,动态调整边界。
  • 在仅少量有标签数据下,性能超越现有最先进方法。
  • 适合数据稀缺场景下的异常检测任务,如医疗图像分析。

分布外(OOD)检测旨在识别异常样本,防止模型在分布内(ID)数据上训练后输出不可靠结果。大多数现有方法需大量分布内样本训练,严重限制实际应用。为此,本文聚焦更具挑战性的少样本OOD检测设置——仅有少量有标签的分布内样本可用。此前工作忽略了不同类别间的差异性。本文提出自适应多提示对比网络(AMCN),通过学习类间与类内分布来动态调整分布内外分离边界。为弥补无分布外样本及分布内样本稀少的问题,引入CLIP模型,将文本与图像关联,设计可学习的分布内和分布外文本提示(包括标签固定与标签自适应两类)。首先生成自适应提示,然后针对每类引入类级别阈值以建立自适应分类边界,最后提出提示引导的分布内外分离模块,控制分布内与分布外提示间的间隔。实验表明,AMCN显著优于其他前沿方法。

原文摘要 · Abstract (English)

Out-of-distribution (OOD) detection attempts to distinguish outlier samples to prevent models trained on the in-distribution (ID) dataset from producing unavailable outputs. Most OOD detection methods require many IID samples for training, which seriously limits their real-world applications. To this end, we target a challenging setting: few-shot OOD detection, where {Only a few {\em labeled ID} samples are available.} Therefore, few-shot OOD detection is much more challenging than the traditional OOD detection setting. Previous few-shot OOD detection works ignore the distinct diversity between different classes. In this paper, we propose a novel network: Adaptive Multi-prompt Contrastive Network (AMCN), which adapts the ID-OOD separation boundary by learning inter- and intra-class distribution. To compensate for the absence of OOD and scarcity of ID {\em image samples}, we leverage CLIP, connecting text with images, engineering learnable ID and OOD {\em textual prompts}. Specifically, we first generate adaptive prompts (learnable ID prompts, label-fixed OOD prompts and label-adaptive OOD prompts). Then, we generate an adaptive class boundary for each class by introducing a class-wise threshold. Finally, we propose a prompt-guided ID-OOD separation module to control the margin between ID and OOD prompts. Experimental results show that AMCN outperforms other state-of-the-art works.

少样本学习分布外检测CLIP

Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。