🤖 AI Summary
This work addresses the poor performance of existing out-of-distribution (OOD) detection methods on real-world, unforeseen OOD samples. The authors propose a dynamic OOD prototype learning mechanism that relies solely on in-distribution (ID) data during training. At test time, easily detectable OOD samples are leveraged as anchors to facilitate the adaptive discovery of hard-to-detect OOD instances through a two-stage process: coarse-grained pattern capture followed by fine-grained pattern refinement. This approach integrates feature clustering with similarity-based metrics and requires no pre-defined OOD labels, making it compatible with diverse model architectures. Evaluated on the ImageNet OOD benchmark, the method achieves an 11.60% reduction in FPR95 and a 4.70% improvement in AUROC, significantly outperforming current state-of-the-art techniques.
📝 Abstract
Recent studies show that using potential out-of-distribution (OOD) labels from large corpora as auxiliary information can improve OOD detection in vision-language models (VLMs). However, these methods often fail when real-world OOD samples fall outside the predefined OOD label set. To address this limitation, we propose DynProto, a novel approach that learns OOD prototypes dynamically during testing using only in-distribution (ID) information. DynProto is inspired by a key observation: OOD samples predicted as the same ID class tend to cluster in the feature space. With this insight, we leverage easy-to-detect OOD samples as ``anchors'' to find their harder-to-detect, similar counterparts. To this end, DynProto introduces two modules: \textbf{Coarse OOD Pattern Capturing Module} caches OOD patterns that are easily confused with each ID class during testing, and \textbf{Fine-grained OOD Pattern Refinement Module} subsequently clusters these patterns within each cache and aggregates them into representative OOD prototypes. By measuring similarity to ID and dynamic OOD prototypes, DynProto enables accurate OOD detection. DynProto significantly outperforms prior methods across multiple benchmarks. On ImageNet OOD benchmark, DynProto reduces FPR95 by 11.60\% and improves AUROC by 4.70\%. Moreover, the framework is architecture-agnostic and can be integrated into various backbones.