SOTAVerified

RankFeat: Rank-1 Feature Removal for Out-of-distribution Detection

2022-09-18Code Available0· sign in to hype

Yue Song, Nicu Sebe, Wei Wang

Code Available — Be the first to reproduce this paper.

Reproduce

Code

Abstract

The task of out-of-distribution (OOD) detection is crucial for deploying machine learning models in real-world settings. In this paper, we observe that the singular value distributions of the in-distribution (ID) and OOD features are quite different: the OOD feature matrix tends to have a larger dominant singular value than the ID feature, and the class predictions of OOD samples are largely determined by it. This observation motivates us to propose RankFeat, a simple yet effective post hoc approach for OOD detection by removing the rank-1 matrix composed of the largest singular value and the associated singular vectors from the high-level feature (i.e., X- s_1u_1v_1^T). RankFeat achieves the state-of-the-art performance and reduces the average false positive rate (FPR95) by 17.90\% compared with the previous best method. Extensive ablation studies and comprehensive theoretical analyses are presented to support the empirical results.

Tasks

Benchmark Results

DatasetModelMetricClaimedVerifiedStatus
ImageNet-1k vs Curated OODs (avg.)RankFeat (ResNetv2-101)FPR9536.8Unverified
ImageNet-1k vs iNaturalistRankFeat (ResNetv2-101)AUROC91.91Unverified
ImageNet-1k vs PlacesRankFeat (ResNetv2-101)FPR9539.34Unverified
ImageNet-1k vs SUNRankFeat (ResNetv2-101)FPR9529.27Unverified
ImageNet-1k vs TexturesRankFeat (ResNetv2-101)AUROC91.7Unverified

Reproductions