Why Out-of-distribution Detection in CNNs Does Not Like Mahalanobis -- and What to Use Instead
Kamil Szyc, Tomasz Walkowiak, Henryk Maciejewski

TL;DR
This paper critiques the use of Mahalanobis distance for out-of-distribution detection in CNNs, showing that nonparametric LOF-based methods often outperform or match it, especially in high-dimensional data scenarios.
Contribution
The paper introduces a nonparametric LOF-based confidence scoring method for CNNs, demonstrating its effectiveness over Mahalanobis distance in out-of-distribution detection tasks.
Findings
LOF-based methods outperform Mahalanobis in high-dimensional OoD detection
LOF-based confidence scores improve state-of-the-art performance
Nonparametric approach simplifies OoD detection in CNNs
Abstract
Convolutional neural networks applied for real-world classification tasks need to recognize inputs that are far or out-of-distribution (OoD) with respect to the known or training data. To achieve this, many methods estimate class-conditional posterior probabilities and use confidence scores obtained from the posterior distributions. Recent works propose to use multivariate Gaussian distributions as models of posterior distributions at different layers of the CNN (i.e., for low- and upper-level features), which leads to the confidence scores based on the Mahalanobis distance. However, this procedure involves estimating probability density in high dimensional data using the insufficient number of observations (e.g. the dimensionality of features at the last two layers in the ResNet-101 model are 2048 and 1024, with ca. 1000 observations per class used to estimate density). In this work,…
Peer Reviews
No public reviews on file for this paper yet. If you reviewed it on a platform where reviews are public (OpenReview, ICLR, NeurIPS, ICML), you can paste yours below so the community can read it here.
Videos
No videos yet. Explain this paper in a talk, walkthrough, or lecture? Add one.
Taxonomy
TopicsAdversarial Robustness in Machine Learning · Anomaly Detection Techniques and Applications · Advanced Neural Network Applications
