Table of Contents
Fetching ...

A Systematic Comparison of Training Objectives for Out-of-Distribution Detection in Image Classification

Furkan Genç, Onat Özdemir, Emre Akbaş

TL;DR

A systematic comparison of four widely used training objectives, spanning probabilistic, prototype-based, metric-learning, and ranking-based supervision, for OOD detection in image classification under standardized OpenOOD protocols finds that Cross-Entropy Loss provides the most consistent near- and far-OOD performance overall.

Abstract

Out-of-distribution (OOD) detection is critical in safety-sensitive applications. While this challenge has been addressed from various perspectives, the influence of training objectives on OOD behavior remains comparatively underexplored. In this paper, we present a systematic comparison of four widely used training objectives: Cross-Entropy Loss, Prototype Loss, Triplet Loss, and Average Precision (AP) Loss, spanning probabilistic, prototype-based, metric-learning, and ranking-based supervision, for OOD detection in image classification under standardized OpenOOD protocols. Across CIFAR-10/100 and ImageNet-200, we find that Cross-Entropy Loss, Prototype Loss, and AP Loss achieve comparable in-distribution accuracy, while Cross-Entropy Loss provides the most consistent near- and far-OOD performance overall; the other objectives can be competitive in specific settings.

A Systematic Comparison of Training Objectives for Out-of-Distribution Detection in Image Classification

TL;DR

A systematic comparison of four widely used training objectives, spanning probabilistic, prototype-based, metric-learning, and ranking-based supervision, for OOD detection in image classification under standardized OpenOOD protocols finds that Cross-Entropy Loss provides the most consistent near- and far-OOD performance overall.

Abstract

Out-of-distribution (OOD) detection is critical in safety-sensitive applications. While this challenge has been addressed from various perspectives, the influence of training objectives on OOD behavior remains comparatively underexplored. In this paper, we present a systematic comparison of four widely used training objectives: Cross-Entropy Loss, Prototype Loss, Triplet Loss, and Average Precision (AP) Loss, spanning probabilistic, prototype-based, metric-learning, and ranking-based supervision, for OOD detection in image classification under standardized OpenOOD protocols. Across CIFAR-10/100 and ImageNet-200, we find that Cross-Entropy Loss, Prototype Loss, and AP Loss achieve comparable in-distribution accuracy, while Cross-Entropy Loss provides the most consistent near- and far-OOD performance overall; the other objectives can be competitive in specific settings.
Paper Structure (37 sections, 18 equations, 7 figures, 6 tables)

This paper contains 37 sections, 18 equations, 7 figures, 6 tables.

Figures (7)

  • Figure 1: Performance metrics for CIFAR-10 on the OpenOOD benchmark: (a) ID Accuracy, (b) near-OOD AUROC, and (c) far-OOD AUROC. ** denotes statistically significant difference. AP: AP Loss, CE: Cross-Entropy Loss, PT: Prototype Loss, TL: Triplet Loss.
  • Figure 2: Performance metrics for CIFAR-100 on the OpenOOD benchmark: (a) ID Accuracy, (b) near-OOD AUROC, and (c) far-OOD AUROC. ** denotes statistically significant difference. AP: AP Loss, CE: Cross-Entropy Loss, PT: Prototype Loss, TL: Triplet Loss.
  • Figure 3: Performance metrics for ImageNet-200 on the OpenOOD benchmark: (a) ID Accuracy, (b) near-OOD AUROC, and (c) far-OOD AUROC. ** denotes statistically significant difference. AP: AP Loss, CE: Cross-Entropy Loss, PT: Prototype Loss, TL: Triplet Loss.
  • Figure 4: t-SNE visualizations for ID vs near-OOD and far-OOD samples.
  • Figure 5: t-SNE Visualizations for ID vs OOD Comparison
  • ...and 2 more figures