Improving Confidence Estimates for Unfamiliar Examples

Zhizhong Li, Derek HoiemCVPR 2020

Introduction

Deep learning models frequently exhibit extreme overconfidence when encountering "unfamiliar" data—samples that belong to known classes but differ significantly from the training distribution, such as a new dog breed or an age group not represented in the training set. This paper explores strategies to ensure models "know what they don't know," moving beyond the standard i.i.d. assumption where training and testing data are drawn from the same distribution.

The Problem: Overconfidence on Unfamiliar Data

In real-world applications, models often face "epistemic uncertainty" due to a lack of knowledge about specific data sub-populations. The authors demonstrate that current classifiers don't just fail on these unfamiliar examples; they fail with high certainty. For instance, a gender classifier was found to be 12 times more likely to produce an incorrect prediction at a 99% confidence level when presented with an unfamiliar age group. This phenomenon is a significant hurdle for deploying AI in safety-critical areas like autonomous driving or medical diagnosis.

Examples of high-confidence misclassifications on unfamiliar data across various tasks, including gender recognition, pet classification, and animal categorization.

Methodology

The study evaluates several techniques for mitigating overconfidence:

  1. Temperature Scaling (T-scaling): A post-processing method that divides logits by a constant $T$ (learned on a validation set) to soften probability distributions without altering the predicted class.
  2. Ensembles: Averaging predictions from multiple models (10 in this study) initialized differently. Disagreement between models on unfamiliar data naturally lowers aggregate confidence.
  3. Distillation and G-distillation: Attempting to compress ensemble knowledge into a single model. G-distillation uses an additional unsupervised dataset to help the student model mimic the ensemble's uncertainty on out-of-distribution data.
  4. Bayesian Models (MC-Dropout): Simulating an ensemble within a single network by using dropout at test time.
  5. Novelty-weighted Scaling: Dynamically adjusting temperature $T$ based on a "novelty score" derived from the ODIN detector.

Experimental Setup

The authors created specific "familiar/unfamiliar" splits across four distinct tasks:

  • Gender Recognition (LFW+): Familiar (ages 18-59) vs. Unfamiliar (under 18 or over 59).
  • Cat vs. Dog (Pets): Familiar breeds vs. entirely new breeds.
  • Animal Categorization (ImageNet): Familiar species vs. new species within the same superclass (e.g., different types of birds).
  • Object Presence (VOC/COCO): Comparing models trained on PASCAL VOC and tested on MS COCO to evaluate dataset collection biases.

Key Results and Insights

The experimental results highlight several critical findings:

  • Ensembles as the Gold Standard: Ensembles of calibrated models consistently outperformed all other methods, improving both confidence quality and underlying accuracy (label error) on unfamiliar samples. They reduced Negative Log Likelihood (NLL) by 33% to 46% across tasks.
  • Effectiveness of T-scaling: Despite its simplicity, T-scaling significantly reduced Expected Calibration Error (ECE) by 20% to 37% on unfamiliar data with negligible computational overhead. On the Gender task, the baseline model's ECE jumped from 0.013 on familiar data to 0.109 on unfamiliar data, highlighting the need for such calibration.
  • The Distillation Gap: Standard distillation fails to capture ensemble behavior on unfamiliar data. While G-distillation helps, it does not fully bridge the performance gap to the full ensemble.
  • Novelty Detection Challenges: Weighting confidence by novelty scores did not outperform standard T-scaling, likely because validation sets often lack sufficient variety to tune these weights effectively for generalization.

Conclusion and Future Work

While ensembles provide the most robust reliability, their computational cost remains a barrier for real-time applications. T-scaling offers a practical, efficient alternative for basic calibration. Future research should focus on achieving ensemble-level reliability within single, efficient architectures and exploring how representation learning can improve a model's inherent self-awareness regarding unfamiliar inputs.

Summary updated

BibTeX
@inproceedings{li2020improving,
  author = {Zhizhong Li and Derek Hoiem},
  title = {{Improving Confidence Estimates for Unfamiliar Examples}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2020},
  doi = {10.1109/cvpr42600.2020.00276},
}
Figure