Out-of-distribution (OOD) detection is a crucial aspect of deploying machine learning models in open-world applications. Empirical evidence suggests that training with auxiliary outliers substantially improves OOD detection. However, such outliers typically exhibit a distribution gap compared to the test OOD data and do not cover all possible test OOD scenarios. Additionally, incorporating these outliers introduces additional training burdens. In this paper, we introduce a novel paradigm called test-time OOD detection, which utilizes unlabeled online data directly at test time to improve OOD detection performance. While this paradigm is efficient, it also presents challenges such as catastrophic forgetting. To address these challenges, we propose adaptive outlier optimization (AUTO), which consists of an in-out-aware filter, an ID memory bank, and a semantically-consistent objective. AUTO adaptively mines pseudo-ID and pseudo-OOD samples from test data, utilizing them to optimize networks in real time during inference. Extensive results on CIFAR-10, CIFAR-100, and ImageNet benchmarks demonstrate that AUTO significantly enhances OOD detection performance.
翻译:分布外(OOD)检测是机器学习模型在开放世界应用部署中的关键环节。经验证据表明,使用辅助异常值进行训练能显著提升OOD检测性能。然而,这类异常值通常与测试OOD数据存在分布差异,且无法覆盖所有可能的测试OOD场景。此外,引入这些异常值还会带来额外的训练负担。本文提出一种名为"测试时OOD检测"的新范式,该范式直接在测试阶段利用无标注在线数据来提升OOD检测性能。尽管该范式高效,但仍面临灾难性遗忘等挑战。为解决这些问题,我们提出自适应异常值优化(AUTO)方法,该方法包含内外敏感滤波器、ID内存库和语义一致性目标三个组件。AUTO能从测试数据中自适应挖掘伪ID和伪OOD样本,并在推理过程中实时用于网络优化。在CIFAR-10、CIFAR-100和ImageNet基准上的大量实验结果表明,AUTO能显著提升OOD检测性能。