Selective Learning: Towards Robust Calibration with Dynamic Regularization

Zongbo Han, Yifeng Yang, Changqing Zhang, Linjun Zhang, Joey Tianyi Zhou, Qinghua Hu, Huaxiu YaoarXiv 2024 · DOI

TL;DR

Deep learning models are notoriously overconfident, often failing to "know what they don't know." This paper introduces Dynamic Regularization (DREG), a selective learning approach that identifies easy versus challenging samples during training to apply regularization strategically. DREG achieves state-of-the-art calibration and accuracy across diverse datasets by resolving the conflicting objectives inherent in traditional regularization methods.

The Challenge of Miscalibration

In deep learning, miscalibration occurs when a model’s predicted confidence does not align with its actual accuracy. For instance, a model might report 99% confidence in a prediction that is only correct 70% of the time. This phenomenon typically stems from overfitting, where the model "memorizes" the training set, including noise and outliers, rather than learning generalizable features.

Existing solutions, such as label smoothing or focal loss, attempt to mitigate this by adding a penalty to prevent extreme confidence. However, these methods often suffer from conflicting objectives: they simultaneously attempt to increase confidence to minimize classification loss and decrease it to maximize entropy. This "one-size-fits-all" approach leads to two primary failures:

  1. Under-confidence on easy samples that the model should be certain about.
  2. Over-confidence on challenging samples (outliers) that exceed the model's capacity.

Dynamic Regularization (DREG)

To address these limitations, the authors propose Dynamic Regularization (DREG). Instead of uniform regularization, DREG treats training as a selective process based on the Huber $\eta$-contamination model. This model assumes training data is a mixture of "in-distribution" (clean) and "outlier" (challenging) samples.

Dynamic objective vs. conflicting objectives in previous methods.

The DREG Algorithm

The DREG training loop follows a three-step process:

  1. Difficulty Estimation: For every training batch, the model calculates the classification loss for each sample.
  2. Sorting & Selection: Samples are sorted by loss. The top $\eta$ fraction (highest loss) are identified as "challenging," while the remainder are classified as "easy."
  3. Dual-Objective Loss:
  4. Easy Samples: The model applies standard classification loss (e.g., Cross-Entropy) to increase confidence and ensure high accuracy.
  5. Challenging Samples: The model applies a regularization loss—specifically, a weighted KL divergence against a uniform distribution—to encourage lower confidence and higher entropy.

By dynamically switching the objective based on sample difficulty, the model learns to be confident within its "competency zone" and appropriately uncertain outside of it.

Key Results and Insights

DREG consistently outperformed state-of-the-art methods, including Focal Loss, Label Smoothing, and Logit Normalization, in both accuracy and calibration metrics.

Performance comparison on CIFAR-8-2 and CIFAR-80-20 hard sets.
  • Calibration: On the challenging subset of CIFAR-8-2, DREG achieved an Expected Calibration Error (ECE) of 10.24%, significantly lower than the second-best method (IFL at 14.01%).
  • Accuracy: On the Camelyon17 "hard set," DREG reached 87.46% accuracy, surpassing the baseline Empirical Risk Minimization (ERM) at 85.75%.
  • Robustness: The model demonstrated superior performance in ranking-based metrics like AURC (Area Under the Risk-Coverage curve), indicating a better ability to distinguish between its own correct and incorrect predictions.

The core insight of the research is the realization that miscalibration is not just about the model being "too strong," but rather about it being forced to provide definitive answers for data it cannot understand. DREG's sorting mechanism implicitly estimates the probability of a sample being an outlier over the course of training, bridging the gap between standard empirical risk minimization and robust statistics.

Limitations and Future Directions

While effective, DREG introduces two primary hyperparameters: $\eta$ (the fraction of challenging data) and $\beta$ (regularization strength). Although the model is relatively stable, $\eta$ requires tuning based on the expected noise level of the dataset. Future work may explore more automated ways to define the "challenging" threshold, perhaps by leveraging the model's own internal uncertainty metrics rather than a fixed fraction.

Summary updated

BibTeX
@misc{han2024selective,
  author = {Zongbo Han and Yifeng Yang and Changqing Zhang and Linjun Zhang and Joey Tianyi Zhou and Qinghua Hu and Huaxiu Yao},
  title = {{Selective Learning: Towards Robust Calibration with Dynamic Regularization}},
  year = {2024},
  eprint = {2402.08384},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2402.08384},
}
Figure