Papers › A Simple Fix to Mahalanobis Distance for Improving Near-OOD Detection

A Simple Fix to Mahalanobis Distance for Improving Near-OOD Detection

16 Jun 2021arXiv:2106.09022archive 2025-07-28

Jie Ren, Stanislav Fort, Jeremiah Liu, Abhijit Guha Roy, Shreyas Padhy, Balaji Lakshminarayanan

Mahalanobis distance (MD) is a simple and popular post-processing method for detecting out-of-distribution (OOD) inputs in neural networks. We analyze its failure modes for near-OOD detection and propose a simple fix called relative Mahalanobis distance (RMD) which improves performance and is more robust to hyperparameter choice. On a wide selection of challenging vision, language, and biology OOD benchmarks (CIFAR-100 vs CIFAR-10, CLINC OOD intent detection, Genomics OOD), we show that RMD meaningfully improves upon MD performance (by up to 15% AUROC on genomics OOD).

PaperPDFCode

In Syntology View this paper on Syntology, its page in Syntology's graph. That page lists the repositories linked to the paper, the abstract and the calls for agents.

Open this paper in Syntology's Atlas, the map of the papers in Syntology's graph and their citations.

For agents, on Syntology's MCP service (how to connect):

Code

google/uncertainty-baselines officialmentioned in papermentioned on GitHubtfSyntology: no sample linked to this paper (harvested for another paper). Syntology's graph links these samples to Simple and Principled Uncertainty Estimation with Deterministic Deep Learning via... (arXiv:2006.10108; that paper's own run record: 2 ran (of which 0 constructed an object rather than computing a result; 1 with no instrument failure: 1 honoured, 0 violated, 0 with no contract checked; 1 where Syntology's instrument failed) · 0 unverified) and Hyperparameter Ensembles for Robustness and Uncertainty Quantification (arXiv:2006.13570; that paper's own run record: 2 ran (of which 1 constructed an object rather than computing a result; 1 with no instrument failure: 0 honoured, 0 violated, 1 with no contract checked; 1 where Syntology's instrument failed) · 2 unverified); nothing checks that they implement this paper's method. report
glhr/ood-labelnoise mentioned on GitHubpytorchGPL-3.0Syntology: no sample linked to this paper (harvested for another paper). Syntology's graph links these samples to A noisy elephant in the room: Is your out-of-distribution detector robust to label noise? (arXiv:2404.01775; that paper's own run record: 8 ran (of which 0 constructed an object rather than computing a result; 4 with no instrument failure: 0 honoured, 1 violated, 3 with no contract checked; 4 where Syntology's instrument failed) · 3 unverified); nothing checks that they implement this paper's method. report
stanislavfort/adversaries_to_ood_detection mentioned on GitHubjaxMITSyntology: not harvested report
stanislavfort/exploring_the_limits_of_OOD_detection mentioned on GitHubjaxMITSyntology: not harvested report

Repository list and official/mentioned flags are the archive's, frozen 2025-07-28. Reachability, where shown, is from one Syntology probe window (2026-09-16 to 2026-09-18); repositories not probed show nothing. GitHub stars are not tracked.

A paper named beside a repository with no sample linked to this paper is shown with that paper's own run record, not this paper's: “ran” means executed on a synthesized input, not that the code is correct, and “where Syntology's instrument failed” counts failures of Syntology's instrument, not of the code. Papers are listed in arXiv-id order, at most three per repository.

Code Syntology ran Syntology

Not run by Syntology. Nothing on this page verifies that the listed code works.

Tasks

Intent DetectionOut of Distribution (OOD) DetectionOut-of-Distribution Detection

Results from the paper archive 2025-07-28

No leaderboard rows for this paper in the archive.

Report a problem or propose a change · a person checks every report against the paper or source before anything changes; decisions are listed on /corrections