Spurious-Aware Prototype Refinement for Reliable Out-of-Distribution Detection
Reihaneh Zohrabi, Hosein Hasani, Mahdieh Soleymani Baghshah, Anna Rohrbach, Marcus Rohrbach, Mohammad Hossein Rohban
TL;DR
SPROD tackles OOD detection under unknown spurious correlations by post-hoc refining class prototypes through three stages to capture subgroup structure and debias distances. It relies on distance-based scoring against multiple group prototypes, avoiding softmax confidence and retraining, to improve separation between ID and OOD samples. The method is validated on five SP-OOD benchmarks, including the new Animals MetaCoCo dataset, and shows consistent gains over 19 baselines across diverse backbones and settings, including NSP-OOD and conventional OOD tasks. These results demonstrate a scalable, data-efficient approach to robust OOD detection with real-world applicability. SPROD also provides theoretical and empirical insights into how subgroup-aware prototypes reduce spurious bias and enhance reliability in challenging SP-OOD scenarios.
Abstract
Out-of-distribution (OOD) detection is crucial for ensuring the reliability and safety of machine learning models in real-world applications, where they frequently face data distributions unseen during training. Despite progress, existing methods are often vulnerable to spurious correlations that mislead models and compromise robustness. To address this, we propose SPROD, a novel prototype-based OOD detection approach that explicitly addresses the challenge posed by unknown spurious correlations. Our post-hoc method refines class prototypes to mitigate bias from spurious features without additional data or hyperparameter tuning, and is broadly applicable across diverse backbones and OOD detection settings. We conduct a comprehensive spurious correlation OOD detection benchmarking, comparing our method against existing approaches and demonstrating its superior performance across challenging OOD datasets, such as CelebA, Waterbirds, UrbanCars, Spurious Imagenet, and the newly introduced Animals MetaCoCo. On average, SPROD improves AUROC by 4.8% and FPR@95 by 9.4% over the second best.
