Deep neural networks are susceptible to generating overconfident yet erroneous predictions when presented with data beyond known concepts. This challenge underscores the importance of detecting out-of-distribution (OOD) samples in the open world. In this work, we propose a novel feature-space OOD detection score based on class-specific and class-agnostic information. Specifically, the approach utilizes Whitened Linear Discriminant Analysis to project features into two subspaces - the discriminative and residual subspaces - for which the in-distribution (ID) classes are maximally separated and closely clustered, respectively. The OOD score is then determined by combining the deviation from the input data to the ID pattern in both subspaces. The efficacy of our method, named WDiscOOD, is verified on the large-scale ImageNet-1k benchmark, with six OOD datasets that cover a variety of distribution shifts. WDiscOOD demonstrates superior performance on deep classifiers with diverse backbone architectures, including CNN and vision transformer. Furthermore, we also show that WDiscOOD more effectively detects novel concepts in representation spaces trained with contrastive objectives, including supervised contrastive loss and multi-modality contrastive loss.
翻译:深度神经网络在面对超越已知概念的数据时,容易生成过度自信但错误的预测。这一挑战凸显了在开放世界中检测分布外(OOD)样本的重要性。在本文中,我们提出了一种基于类特定信息和类无关信息的特征空间OOD检测评分方法。具体而言,该方法利用白化线性判别分析将特征投影到两个子空间——判别子空间和残差子空间——分别用于最大化类间分离和类内紧密聚类。随后,通过结合输入数据在两个子空间中与分布内(ID)模式的偏差来确定OOD评分。我们提出的方法名为WDiscOOD,其有效性在大规模ImageNet-1k基准测试上得到验证,使用了涵盖多种分布偏移的六个OOD数据集。WDiscOOD在具有不同主干架构的深度分类器(包括CNN和视觉Transformer)上展现出优越性能。此外,我们还表明,WDiscOOD能够更有效地检测使用对比学习目标(包括监督对比损失和多模态对比损失)训练的表征空间中的新概念。