Uncertainty-Calibrated Test-Time Model Adaptation Without Forgetting

Mingkui Tan, Guohao Chen, Jiaxiang Wu, Yifan Zhang, Yaofo Chen, Peilin Zhao, Shuaicheng Niu

TL;DR

EATA-C is a novel test-time adaptation framework that enables deep neural networks to adapt to new environments efficiently without forgetting their original training or becoming dangerously overconfident. By selectively updating the model on reliable samples and balancing model vs. data uncertainty, it achieves state-of-the-art accuracy and calibration with significantly lower computational costs than previous methods.

What Problem Does This Paper Address?

Deep neural networks are notoriously brittle when faced with distribution shifts—changes in the environment like new lighting, weather conditions, or sensor noise that differ from the training data. Test-Time Adaptation (TTA) aims to fix this by allowing a model to update itself using the very samples it sees during inference.

However, existing TTA methods face three major hurdles:

  1. Efficiency: Most methods require expensive backpropagation for every single test sample, which is too slow for real-time applications like autonomous driving.
  2. Catastrophic Forgetting: While adapting to new "out-of-distribution" (OOD) data, models often "forget" how to handle their original "in-distribution" (ID) data.
  3. Overconfidence: Popular techniques like entropy minimization force the model to make highly confident predictions. This is dangerous when the data is inherently ambiguous or noisy, leading to "confidently wrong" outputs.

Methods

The authors propose two versions of their method: EATA (Efficient Anti-Forgetting TTA) and its enhanced version, EATA-C (EATA with Calibration).

Overview of the EATA-C architecture, showing active sample selection, consistency loss, and anti-forgetting regularization.

1. Efficient & Anti-Forgetting (EATA)

  • Active Sample Selection: Instead of updating on every sample, EATA uses a "quality filter." It identifies reliable samples (those with low prediction entropy) and non-redundant samples (those that provide diverse information). This drastically reduces the number of backward passes needed.
  • Fisher Regularization: To prevent forgetting, EATA calculates the importance of model weights using Fisher information from a small set of ID samples. During adaptation, it penalizes large changes to these critical weights, ensuring the model retains its original knowledge.

2. Uncertainty Calibration (EATA-C)

EATA-C goes further by distinguishing between two types of uncertainty:

  • Reducible Model Uncertainty: This stems from the model not being fully trained for the new domain. EATA-C minimizes this using a Consistency Loss, which encourages the full network and a randomly sampled sub-network to produce similar predictions.
  • Irreducible Data Uncertainty: This is inherent noise in the data itself. EATA-C uses label disagreement between the full and sub-networks as a proxy for this. It then applies a Min-Max Entropy Regularizer: it minimizes entropy (boosts confidence) for "certain" samples and maximizes entropy (lowers confidence) for "uncertain" ones near decision boundaries.

Datasets

The authors evaluated their methods on three major benchmarks for OOD generalization:

  • ImageNet-C: The standard ImageNet validation set corrupted with 15 types of noise, blurs, and weather effects at various severity levels.
  • ImageNet-R: A collection of 30,000 images containing artistic renditions (paintings, sketches, etc.) of ImageNet classes.
  • ACDC: A semantic segmentation dataset featuring adverse driving conditions like fog, night, rain, and snow.

Key Insights and Ideas

  • More data isn't always better: The authors discovered that adapting on high-entropy (highly uncertain) samples can actually degrade performance because their gradients are noisy and unreliable.
The effect of entropy on adaptation. Low-entropy samples contribute most to accuracy gains, while high-entropy samples can hurt performance.
  • Forgetting is a "Lifelong" Problem: In scenarios where a model adapts continuously over time, standard methods like Tent eventually collapse to zero accuracy on the original data. EATA’s Fisher regularization is crucial for long-term stability.
  • Calibration Matters for Safety: By separating model and data uncertainty, EATA-C provides a "honesty" check. It allows the model to remain uncertain when the input is genuinely ambiguous, which is vital for high-stakes decision-making.

Key Results

EATA-C sets a new benchmark across multiple architectures (ResNet-50 and ViT-Base):

  • Accuracy: On ImageNet-C (severity 5), EATA-C achieved an average accuracy of 66.65% with a ViT-Base model, significantly outperforming the baseline Tent (53.92%).
  • Calibration: It reduced the Expected Calibration Error (ECE) from 8.78% (Tent) to a mere 5.14% on ViT-Base.
  • Efficiency: EATA-C is remarkably efficient. On ResNet-50, it required only ~33,000 backward passes compared to 50,000 for standard methods, while achieving better results.
Comparison of EATA-C against state-of-the-art methods on ImageNet-C. EATA-C consistently achieves the highest accuracy and lowest ECE.

Limitations and Future Work

  • Norm-Only Updates: Following common TTA practices, the authors primarily update only the normalization layers. While efficient, this might limit the model's ability to adapt to extremely severe distribution shifts.
  • ID Sample Requirement: The anti-forgetting mechanism requires a small set of unlabeled in-distribution samples to estimate weight importance. While the authors show 500 samples are enough, this might not always be available in every deployment scenario.
  • Future Directions: Exploring how to automatically determine the optimal number of ID samples and extending the framework to more complex tasks like object detection are promising next steps.

Summary updated

BibTeX
@article{tan2025uncertainty,
  author = {Mingkui Tan and Guohao Chen and Jiaxiang Wu and Yifan Zhang and Yaofo Chen and Peilin Zhao and Shuaicheng Niu},
  title = {{Uncertainty-Calibrated Test-Time Model Adaptation Without Forgetting}},
  journal = {IEEE Trans. Pattern Anal. Mach. Intell.},
  year = {2025},
  doi = {10.1109/tpami.2025.3560696},
}
Figure