Test-Time Linear Out-of-Distribution Detection
Ke Fan, Tong Liu, Xingyu Qiu, Yikai Wang, Lian Huai, Zeyu Shangguan, Shuang Gou, Fengjian Liu, Yuqian Fu, Yanwei Fu, Xingqun Jiang
Abstract
Out-of-Distribution (OOD) detection aims to address the excessive confidence prediction by neural networks by triggering an alert when the input sample deviates significantly from the training distribution (in-distribution), indicating that the output may not be reliable. Current OOD detection approaches explore all kinds of cues to identify OOD data, such as finding irregular patterns in the feature space, logit space, gradient space, or the raw image space. Surprisingly, we observe a linear trend between the OOD score produced by current OOD detection algorithms and the network features on several datasets. We conduct a thorough investigation, theoretically and empirically, to analyze and understand the meaning of such a linear trend in OOD detection. This paper proposes a Robust Test-time Linear method (RTL) to utilize such linear trends like a 'free lunch' when we have a batch of data to perform OOD detection. By using a simple linear regression as a test time adaptation, we can make a more precise OOD prediction. We further propose an online variant of the proposed method, which achieves promising performance and is more practical for real applications. Theoretical analysis is given to prove the effectiveness of our methods. Extensive experiments on several OOD datasets show the efficacy of RTL for OOD detection tasks, significantly improving the results of base OOD detectors. Project will be available at https://github.com/kfan21/RTL .
Ask about this paper
Your agent reads all of it.
Lune indexed this paper to the last equation, along with the top-tier papers that cite it. Ask a question and the answer quotes them.
Your agent calls
Luneget_paper_fulltext
Free to start. No credit card required.
Terminal
Install the CLIlune papers fulltext 98c2c47f-55c8-4bf0-9c9d-b8f80a9f922dCited by top-tier papers9
- OOD-Barrier: Build a Middle-Barrier for Open-Set Single-Image Test Time Adaptation via Vision Language ModelsBoyang Peng, Sanqing Qu, Tianpei Zou, Fan Lu et al.NeurIPS 2025 · 4 citations
- Activation Matters: Test-time Activated Negative Labels for OOD Detection with Vision-Language ModelsYabin Zhang, Maya Varma, Yunhe Gao, Jean-Benoit Delbrouck et al.CVPR 2026 · 2 citations
- Back to Source: Open-Set Continual Test-Time Adaptation via Domain CompensationYingkai Yang, Chaoqi Chen, Hui HuangCVPR 2026 · 1 citation
- DIsoN: Decentralized Isolation Networks for Out-of-Distribution Detection in Medical ImagingFelix Wagner, Pramit Saha, Harry Anthony, J. Alison Noble et al.NeurIPS 2025 · 1 citation
- COSTARR: Consolidated Open Set Technique with Attenuation for Robust RecognitionRyan Rabinowitz, Steve Cruz, Walter J. Scheirer, Terrance E. BoultICCV 2025 · 1 citation
Builds on7
- An Image is Worth 16x16 Words: Transformers for Image Recognition at ScaleAlexey Dosovitskiy, Lucas Beyer, Alexander Kolesnikov, Dirk Weissenborn et al.ICLR 2021 · 21,477 citations
- Energy-based Out-of-distribution DetectionWeitang Liu, Xiaoyun Wang, John D. Owens, Yixuan LiNeurIPS 2020 · 2,213 citations
- Tent: Fully Test-Time Adaptation by Entropy MinimizationDequan Wang, Evan Shelhamer, Shaoteng Liu, Bruno A. Olshausen et al.ICLR 2021 · 1,731 citations
- Test-Time Training with Self-Supervision for Generalization under Distribution ShiftsYu Sun, Xiaolong Wang, Zhuang Liu, John Miller et al.ICML 2020 · 1,220 citations
- Scalable Penalized Regression for Noise Detection in Learning with Noisy LabelsYikai Wang, Xinwei Sun, Yanwei FuCVPR 2022 · 37 citations
Related papers
- Meta OOD Learning For Continuously Adaptive OOD DetectionXinheng Wu, Jie Lu, Zhen Fang, Guangquan ZhangICCV 2023 · 15 citations
- Neural Mean Discrepancy for Efficient Out-of-Distribution DetectionXin Dong, Junfeng Guo, Ang Li, Wei-Te Ting et al.CVPR 2022 · 40 citations
- ReAct: Out-of-distribution Detection With Rectified ActivationsYiyou Sun, Chuan Guo, Yixuan LiNeurIPS 2021 · 733 citations
- Towards neural networks that provably know when they don't knowAlexander Meinke, Matthias HeinICLR 2020 · 151 citations
- OODD: Test-time Out-of-Distribution Detection with Dynamic DictionaryYifeng Yang, Lin Zhu, Zewen Sun, Hengyu Liu et al.CVPR 2025
