Activation Subspaces for Out-of-Distribution Detection

Barış Zöngür, Robin Hesse, Stefan Roth
8/29/2025
cs.LGcs.CV

No official code found. Best implementation: visinf/actsub (7 stars, Apache-2.0, last commit 2025-10-24).

Abstract

To ensure the reliability of deep models in real-world applications, out-of-distribution (OOD) detection methods aim to distinguish samples close to the training distribution (in-distribution, ID) from those farther away (OOD). In this work, we propose a novel OOD detection method that utilizes singular value decomposition of the weight matrix of the classification head to decompose the model's activations into decisive and insignificant components, which contribute maximally, respectively minimally, to the final classifier output. We find that the subspace of insignificant components more effectively distinguishes ID from OOD data than raw activations in regimes of large distribution shifts (Far-OOD). This occurs because the classification objective leaves the insignificant subspace largely unaffected, yielding features that are ''untainted'' by the target classification task. Conversely, in regimes of smaller distribution shifts (Near-OOD), we find that activation shaping methods profit from only considering the decisive subspace, as the insignificant component can cause interference in the activation space. By combining two findings into a single approach, termed ActSub, we achieve state-of-the-art results in various standard OOD benchmarks.

View on arXivView PDF

Code Implementations(1)

visinf/actsubCommunity74%
Apache-2.0

Activation Subspaces for Out-of-Distribution Detection (ICCV 2025)

70Shell, PythonJul 21, 202512 months agoApache-2.0

Similar Papers

Cite this paper

@article{zngr2025activation,
  title  = {Activation Subspaces for Out-of-Distribution Detection},
  author = {Barış Zöngür and Robin Hesse and Stefan Roth},
  year   = {2025},
  eprint = {2508.21695},
  archivePrefix = {arXiv},
  url    = {http://arxiv.org/abs/2508.21695v1}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2508.21695.svg)](https://codeofpaper.com/paper/2508.21695)

Discussion