{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/rankfeat-rank-1-feature-removal-for-out-of","title":"RankFeat: Rank-1 Feature Removal for Out-of-distribution Detection","arxiv_id":"2209.08590","date":"2022-09-18","proceeding":null,"authors":["Yue Song","Nicu Sebe","Wei Wang"],"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 \\texttt{RankFeat}, a simple yet effective \\texttt{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 (\\emph{i.e.,} $\\mathbf{X}{-} \\mathbf{s}_{1}\\mathbf{u}_{1}\\mathbf{v}_{1}^{T}$). \\texttt{RankFeat} achieves the \\emph{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.","url_abs":"https://arxiv.org/abs/2209.08590v1","url_pdf":"https://arxiv.org/pdf/2209.08590v1.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"rankfeat-rank-1-feature-removal-for-out-of","repo_url":"https://github.com/kingjamessong/rankfeat","is_official":1,"mentioned_in_paper":1,"mentioned_in_github":1,"framework":"pytorch","reach":null}],"tasks":[{"task_slug":"out-of-distribution-detection","task_name":"Out-of-Distribution Detection"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-12","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs Curated OODs (avg.)","model":"RankFeat (ResNetv2-101)","rank_in_archive_order":8,"of":16,"metrics":{"AUROC":"92.15","FPR95":"36.8"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-9","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs Places","model":"RankFeat (ResNetv2-101)","rank_in_archive_order":8,"of":25,"metrics":{"AUROC":"90.93","FPR95":"39.34"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-8","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs SUN","model":"RankFeat (ResNetv2-101)","rank_in_archive_order":8,"of":22,"metrics":{"AUROC":"94.07","FPR95":"29.27"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-10","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs Textures","model":"RankFeat (ResNetv2-101)","rank_in_archive_order":15,"of":34,"metrics":{"AUROC":"91.7","FPR95":"37.29"},"uses_additional_data":false},{"leaderboard":"/sota/out-of-distribution-detection-on-imagenet-1k-3","task":"Out-of-Distribution Detection","dataset":"ImageNet-1k vs iNaturalist","model":"RankFeat (ResNetv2-101)","rank_in_archive_order":19,"of":28,"metrics":{"AUROC":"91.91","FPR95":"41.31"},"uses_additional_data":false}],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2209.08590","mcp":null,"developers":"https://syntology.ai/developers"},"arxiv_metadata":null,"syntology_extracted_results":null}