Why Feature Magnitude Deceives OOD Detectors: An Angular Separation Perspective
Abstract
Out-of-Distribution (OOD) detection is a critical safety requirement for deploying deep neural networks in open-world environments. While recent advances increasingly rely on more computationally intensive training methods involving synthetic outliers, contrastive objectives, or specialized loss functions, their gains often come with substantial computational overhead and implementation complexity. In this work, we revisit the fundamentals of OOD detection and uncover a key flaw in common distance-based detectors: sensitivity to feature magnitude. We show that low-norm OOD samples can appear closer to in-distribution (ID) class centroids than actual ID samples, evading detection. To this end, we introduce Angular Separation Learning (ASL), a simple and highly effective strategy that applies ℓ -normalization to features before 2 the final classification layer. This modification compels the network to optimize for angular separation, achieving robust feature learning without additional regularization mechanisms, synthetic samples, or costly negative mining. Through extensive experiments on diverse benchmarks, we demonstrate that ASL not only matches but often surpasses state-of-theart methods, especially in challenging near-OOD scenarios, while maintaining training efficiency. Our results indicate that a minimalist rethink of standard training can achieve superior OOD performance, prompting a re-evaluation of the complexity-to-performance trade-off in OOD detection. Codes are available at https://github.com/HAIV-Lab/ASL.