[Paper Review] Generalized ODIN: Detecting Out-of-distribution Image without Learning from Out-of-distribution Data
The paper proposes learning OoD detection without OoD data by decomposing confidence into h and g components (DeConf) and a modified input preprocessing strategy, achieving strong performance across multiple datasets without OoD tuning.
Deep neural networks have attained remarkable performance when applied to data that comes from the same distribution as that of the training set, but can significantly degrade otherwise. Therefore, detecting whether an example is out-of-distribution (OoD) is crucial to enable a system that can reject such samples or alert users. Recent works have made significant progress on OoD benchmarks consisting of small image datasets. However, many recent methods based on neural networks rely on training or tuning with both in-distribution and out-of-distribution data. The latter is generally hard to define a-priori, and its selection can easily bias the learning. We base our work on a popular method ODIN, proposing two strategies for freeing it from the needs of tuning with OoD data, while improving its OoD detection performance. We specifically propose to decompose confidence scoring as well as a modified input pre-processing method. We show that both of these significantly help in detection performance. Our further analysis on a larger scale image dataset shows that the two types of distribution shifts, specifically semantic shift and non-semantic shift, present a significant difference in the difficulty of the problem, providing an analysis of when ODIN-like strategies do or do not work.
Motivation & Objective
- Motivate OoD detection under open-world assumptions without relying on OoD data for tuning.
- Introduce a dividend/divisor (DeConf) classifier design to decompose confidence into in-domain and domain terms.
- Adapt and improve input preprocessing to tune perturbation magnitudes using only in-distribution data.
- Provide extensive empirical analysis across standard and large-scale OoD benchmarks to understand semantic vs. non-semantic shifts.
Proposed method
- Introduce a probabilistic view by decomposing p(y|d_in, x) into p(y, d_in|x) / p(d_in|x) and implement as a dividend/divisor structure f_i(x) = h_i(x)/g(x).
- Design h_i(x) using inner-product, Euclidean distance, or cosine similarity from penultimate-layer features (I, E, C variants).
- Train to maximize cross-entropy on p(y, d_in|x) with two branches h_i and g, encouraging decomposed confidence to separate in- and out-of-distribution signals.
- Use g(x) as a learned temperature-like, domain-probability function to calibrate confidence and improve OoD discrimination.
- Modify the input preprocessing (IPP) by selecting a single perturbation magnitude epsilon* based on in-distribution data to maximize S(x).
- Evaluate with across-ID validation without OoD data, and compare against ODIN and Mahalanobis baselines (without OoD tuning).
Experimental results
Research questions
- RQ1How can OoD detection be performed without access to OoD data for tuning hyperparameters?
- RQ2Does decomposing classifier confidence into a dividend/divisor structure improve OoD discrimination without OoD data?
- RQ3Can a learned input perturbation strategy using only in-distribution data effectively enhance OoD detection across diverse datasets?
- RQ4How do semantic and non-semantic distribution shifts affect the performance of OoD detection methods?
- RQ5What is the impact of different h_i(x) formulations (I, E, C) and g(x) on robustness and scalability?
Key findings
- DeConf variants significantly improve OoD detection over the baseline without using OoD data (AUROC and TNR@TPR95 improvements across datasets).
- The DeConf-E and DeConf-C variants often yield the best robustness and scalability as the number of in-distribution classes increases.
- A single in-distribution data-based epsilon* for IPP can achieve strong OoD discrimination, reducing dependence on OoD datasets for tuning.
- Combining DeConf with the modified IPP yields superior performance against strong baselines (ODIN*, Mahalanobis*) on many benchmarks.
- Semantic shift and non-semantic shift exhibit different levels of difficulty for OoD detection, with semantic shifts generally more challenging.
- Extra regularization can improve DeConf-I and g(x) performance, indicating overfitting considerations for the dividend/divisor design.
Better researchstarts right now
From reading papers to final review, dramatically reduce your research time.
No credit card · Free plan available
This review was created by AI and reviewed by human editors.