This paper identifies the linear classification head as the primary culprit behind the "stability gap"—a sudden performance drop on old tasks when a model starts learning new ones. By replacing the linear head with a non-parametric Nearest-Mean Classifier (NMC), the authors significantly reduce training instability and boost final accuracy across multiple continual learning benchmarks.
What Problem Does This Paper Address?
In Continual Learning (CL), neural networks learn a sequence of tasks. A major hurdle is catastrophic forgetting, where learning new information wipes out previous knowledge. Recent research highlighted a specific nuance called the stability gap: at the start of a new task, the model's accuracy on old tasks doesn't just drift away; it plummets instantly before partially recovering later in the training cycle.
This behavior is counter-intuitive. If we want stable learners, we expect gradual degradation, not a "heart attack" at every task boundary. The authors set out to find the source of this instability: is the feature extractor (backbone) losing the ability to represent old data, or is the classification head simply failing to map those features correctly?
Methods
The researchers proposed a "disentanglement" strategy using the Nearest-Mean Classifier (NMC).
Standard models use a Linear Head—a learned weight matrix followed by a softmax. In contrast, NMC is non-parametric. It calculates "prototypes" (the average feature vector for each class) and classifies new samples by finding the closest prototype in the representation space.
To isolate the cause of the stability gap, they compared:
- Standard Finetuning: A backbone with a traditional linear head.
- Oracle NMC: A backbone where the classifier has access to all previous training data to compute perfect prototypes (providing an upper bound on representation quality).
- Realistic NMC: A practical version using a small memory buffer of "exemplars" to estimate prototypes for old classes.
By training both models with the same backbone but different classification strategies, they could pinpoint whether the instability was coming from the features themselves or the way they were being classified.
Datasets
The authors evaluated their approach on a diverse set of benchmarks:
- General Image Classification: CIFAR100 and ImageNet100 (split into 5 and 10 tasks).
- Fine-grained Classification: CUB-200-2011 (Birds) and FGVC Aircraft.
- Architectural Ablations: They tested various backbones including ResNet18, ResNet50, VGG11, MobileNetV2, and EfficientNet-B4.
Key Insights and Ideas
- The Head is the Bottleneck: The most striking finding is that the backbone's representations are actually quite stable. The massive performance drops seen in standard CL are largely due to the linear head becoming biased toward new tasks.
- Representations Persist: As shown in Figure 1, while the linear head (red) crashes at task boundaries, the NMC (blue) using the exact same features remains much more stable. This proves the "knowledge" is still in the backbone; the linear head just can't access it effectively during the transition.
- Task-Recency Bias: Linear heads suffer from a strong preference for the most recent classes because the gradients from the new task dominate the weight updates. NMC bypasses this by relying on geometric distance in the feature space rather than learned weights that are easily overwritten.
- Warm-up is Not a Cure: A common transfer learning technique is to "warm up" the head by freezing the backbone initially. The authors found this does not mitigate the stability gap in CL, suggesting the issue is fundamental to how linear heads interact with shifting data distributions.
Key Results
- Drastic Stability Improvements: On CIFAR100 (10 tasks), the Stability Gap (SG) metric was reduced from 63.04% for the linear head to 25.35% for NMC.
- Higher Final Accuracy: Beyond just being stable, NMC led to better end-of-training performance. On ImageNet100 (10 tasks), final accuracy jumped from 32.38% to 45.02%.
- Oracle Insights: The Oracle NMC experiments (Figure 2) showed that the linear head is responsible for 2 to 4 times more instability than the backbone itself.
Limitations and Future Work
- Exemplar Dependency: The study primarily focuses on replay-based methods where a memory buffer is available. The authors note that extending this analysis to exemplar-free methods (which rely solely on regularization) is an important next step.
- Simplified Prototypes: NMC assumes class distributions are somewhat spherical in the feature space. Future work could explore more sophisticated non-parametric classifiers that handle complex class geometries better.
- Joint Incremental Learning: While NMC helps, a small stability gap still exists even in joint training scenarios, suggesting there are still minor optimization-level mysteries to solve in the backbone.
Summary updated