Abstract
In Class Incremental Learning (CIL), models must learn new tasks sequentially without forgetting previous ones. While storing exemplars is a common solution, privacy and memory constraints often necessitate exemplar-free approaches. Knowledge Distillation (KD) is the standard alternative, yet it often suffers from performance degradation due to distribution shifts. This paper identifies a critical flaw in standard KD: the "frozen teacher" provides a noisy signal when applied to new data distributions. We present Teacher Adaptation (TA), a simple yet effective method that updates the teacher’s Batch Normalization (BN) statistics on new data. This approach significantly reduces representation shift and improves distillation quality without the need for stored data or complex meta-learning.
Introduction
Class Incremental Learning (CIL) presents a significant challenge for deep learning: catastrophic forgetting. When a model is trained on a new task, it tends to lose the knowledge acquired from previous tasks. The most effective mitigation strategy—storing a small buffer of old examples (exemplars)—is often prohibited in privacy-sensitive domains like medicine or on edge devices with strict memory limits.
In these exemplar-free scenarios, researchers typically rely on Knowledge Distillation (KD). In this framework, the model from the previous task acts as a "teacher," guiding a "student" model (the current learner) to maintain consistent outputs on new data. However, standard KD assumes the teacher is a perfect reference. This paper demonstrates that when the data distribution shifts between tasks, a frozen teacher becomes an "unreliable narrator," leading to a noisy distillation signal and poor performance.
The Problem: Representation Shift in Frozen Teachers
The authors identify that the root of the problem lies in the Batch Normalization (BN) layers of the teacher model. BN layers rely on running mean and variance statistics calculated during the teacher's original training phase. When the student encounters a new task with a different data distribution, the teacher’s internal activations—processed through these old statistics—become misaligned with the current data.
This "representation shift" results in a high KD loss that does not reflect a loss of knowledge, but rather a mismatch in normalization. Consequently, the student model is forced to mimic distorted outputs, which accelerates forgetting of the original task features.
Proposed Method: Teacher Adaptation (TA)
To address this, the authors propose Teacher Adaptation (TA). TA is a plug-and-play strategy that can be integrated into existing KD-based methods such as General KD (GKD), Task-wise KD (TKD), and Multi-class KD (MKD).
Mechanism
Unlike standard KD, where the teacher is entirely static, TA allows the teacher to update its non-trainable BN statistics (moving averages) using the data from the current task. Crucially:
- Fixed Parameters: The teacher’s trainable weights and biases remain frozen to preserve its learned knowledge.
- Dynamic Statistics: The running mean and variance are updated during the forward passes of the new training data.
- Concurrent Updates: The teacher and student are updated simultaneously during the training of the new task, ensuring the teacher's internal state remains aligned with the student's input distribution.
Warmup Phase
To further stabilize training, the authors implement a "warmup" phase. Initially, only the new classification head is trained. This prevents the large gradients generated by a randomly initialized head from corrupting the weights of the feature extractor during the early stages of learning a new task.
Experimental Evaluation
The authors evaluated TA across several rigorous benchmarks:
- Standard Datasets: CIFAR100, TinyImageNet200, and ImageNet100.
- Domain Shift: DomainNet, featuring six distinct domains (e.g., sketches, photos), was used to test the method under severe distribution shifts.
- Fine-grained Classification: A custom benchmark combining specialized datasets like Oxford Flowers and CUB Birds.
- Robustness Analysis: A "corrupted CIFAR100" experiment where Gaussian noise was introduced to specific tasks to measure how TA handles controllable data volatility.
Key Results and Insights
Performance Gains
TA consistently outperformed standard KD baselines across all benchmarks. On CIFAR100 (10-task split), TA improved the incremental accuracy of the GKD baseline from 42.52% to 45.25%. In a more challenging 20-task split, the improvement was even more pronounced, jumping from 31.89% to 37.11%.
Stability and Alignment
Through Centered Kernel Alignment (CKA) analysis, the authors confirmed that updating BN statistics makes the teacher’s internal activations more similar to the student’s. This alignment reduces the divergence between the two models, leading to a lower and more stable KD loss.
Mitigating Recency Bias
CIL models often suffer from a bias toward the most recently learned classes. The authors found that TA helps produce more balanced logit magnitudes across all tasks, naturally mitigating this bias without requiring specialized loss functions or architectural changes.
Zero-Cost Efficiency
One of the most compelling aspects of TA is its efficiency. Unlike meta-learning or methods that expand the model architecture, TA requires virtually no additional computational overhead or memory. It simply modifies the handling of the teacher's forward pass.
Limitations and Future Work
While TA is highly effective, the authors noted that its impact is slightly reduced when paired with Multi-class Knowledge Distillation (MKD). They suggest that the sigmoid functions used in MKD may be less sensitive to the logit shifts that TA is designed to correct. Additionally, while TA is designed for exemplar-free settings, future research could explore its utility in hybrid scenarios where a small number of exemplars are available.
Conclusion
Teacher Adaptation (TA) provides a simple, computationally efficient solution to a fundamental problem in exemplar-free continual learning. By recognizing that a teacher must adapt its normalization to new data distributions, TA ensures a cleaner distillation signal, significantly reducing catastrophic forgetting and setting a new standard for KD-based incremental learning.
Summary updated