Neural Mean Discrepancy for Efficient Out-of-Distribution Detection

被引:21
作者
Dong, Xin [1 ]
Guo, Junfeng [2 ]
Li, Ang [2 ,3 ]
Ting, Wei-Te [1 ]
Liu, Cong [2 ]
Kung, H. T. [1 ]
机构
[1] Harvard Univ, Cambridge, MA 02138 USA
[2] UT Dallas, Dallas, TX USA
[3] Google DeepMind, London, England
来源
2022 IEEE/CVF CONFERENCE ON COMPUTER VISION AND PATTERN RECOGNITION (CVPR 2022) | 2022年
关键词
D O I
10.1109/CVPR52688.2022.01862
中图分类号
TP18 [人工智能理论];
学科分类号
081104 ; 0812 ; 0835 ; 1405 ;
摘要
Various approaches have been proposed for out-of-distribution (OOD) detection by augmenting models, input examples, training sets, and optimization objectives. Deviating from existing work, we have a simple hypothesis that standard off-the-shelf models may already contain sufficient information about the training set distribution which can be leveraged for reliable OOD detection. Our empirical study on validating this hypothesis, which measures the model activation's mean for OOD and in-distribution (ID) minibatches, surprisingly finds that activation means of OOD mini-batches consistently deviate more from those of the training data. In addition, training data's activation means can be computed offline efficiently or retrieved from batch normalization layers as a 'free lunch'. Based upon this observation, we propose a novel metric called Neural Mean Discrepancy (NMD), which compares neural means of the input examples and training data. Leveraging the simplicity of NMD, we propose an efficient OOD detector that computes neural means by a standard forward pass followed by a lightweight classifier. Extensive experiments show that NMD outperforms state-of-the-art OOD approaches across multiple datasets and model architectures in terms of both detection accuracy and computational cost.
引用
收藏
页码:19195 / 19205
页数:11
相关论文
共 91 条
[81]  
Sundararajan M, 2017, PR MACH LEARN RES, V70
[82]   CrossNorm and SelfNorm for Generalization under Distribution Shifts [J].
Tang, Zhiqiang ;
Gao, Yunhe ;
Zhu, Yi ;
Zhang, Zhi ;
Li, Mu ;
Metaxas, Dimitris .
2021 IEEE/CVF INTERNATIONAL CONFERENCE ON COMPUTER VISION (ICCV 2021), 2021, :52-61
[83]   Out-of-Distribution Detection Using an Ensemble of Self Supervised Leave-Out Classifiers [J].
Vyas, Apoorv ;
Jammalamadaka, Nataraj ;
Zhu, Xia ;
Das, Dipankar ;
Kaul, Bharat ;
Willke, Theodore L. .
COMPUTER VISION - ECCV 2018, PT VIII, 2018, 11212 :560-574
[84]  
Winkens, 2020, ARXIV200705566
[85]  
Wu Yuxin, 2021, ARXIV210507576
[86]  
Yang Jingkang, 2021, Generalized Out-of-Distribution detection
[87]  
Yosinski J, 2014, ADV NEUR IN, V27
[88]  
You Fuming, 2021, ARXIV211004065
[89]  
Zaeemzadeh Alireza, 2021, P IEEE C COMP VIS PA
[90]  
Zagoruyko S., 2016, BRIT MACH VIS C, DOI [DOI 10.5244/C.30.87, 10.5244/C.30.87]