Abstract
Vision Transformers (ViTs) have revolutionized static image recognition but historically struggle with Class Incremental Learning (CIL), where models must learn new classes sequentially without forgetting previous ones. This paper introduces ViTIL (ViT for Incremental Learning), a specialized training recipe that addresses slow convergence, recency bias, and classifier underfitting. By integrating a convolutional stem, class-balanced finetuning, and optimized learning rates, ViTIL achieves state-of-the-art results on CIFAR and ImageNet, demonstrating that ViTs can be superior backbones for evolving data streams.
Introduction
Class Incremental Learning (CIL) presents a significant challenge for deep learning models: the tendency to forget old information when learning new tasks, known as catastrophic forgetting. While Convolutional Neural Networks (CNNs) like ResNet have been the standard backbone for CIL, Vision Transformers (ViTs) offer potential advantages in feature extraction. However, naive implementations of ViTs in CIL frameworks often result in poor performance.
Researchers identified three primary bottlenecks for ViTs in this context:
- Slow Convergence: The lack of inductive bias in standard ViTs makes them data-hungry and slow to train on small initial class sets.
- Extreme Recency Bias: ViTs exhibit a stronger tendency than CNNs to favor newly learned classes over older ones.
- Classifier Underfitting: Standard ViT training recipes often use learning rates that are too low for the final classification layer to converge properly.
Experimental Protocols and Benchmarks
The effectiveness of ViTIL was evaluated on CIFAR-100, ImageNet-100, and the full ImageNet-1000 dataset. The researchers employed various protocols to simulate real-world learning scenarios, including starting with a large base set of 500 classes (B500) or starting from scratch (B0), with varying incremental steps and memory constraints for replaying old data.
The ViTIL Recipe
To resolve the identified issues, the authors propose ViTIL, a "bag of treatments" for incremental ViT training:
- Convolutional Stem: Instead of the standard non-overlapping "patchify" layer, ViTIL utilizes four convolutional layers at the input. This provides spatial priors that significantly accelerate convergence, particularly in early learning stages.
- Balanced Finetuning (CBF): To mitigate recency bias, a two-stage training process is used. After training on new data, the backbone is frozen, and only the classifier is finetuned using a perfectly balanced set of exemplars from all seen classes. This approach is more compatible with the heavy data augmentation (Mixup/CutMix) required by ViTs than traditional margin-based losses.
- Large Learning Rate for Classifier: The classifier is trained with a learning rate approximately 10 times higher than the backbone. This ensures the classification layer is sufficiently expressive and avoids the "cold" softmax temperature associated with underfitting.
Results and Analysis
ViTIL consistently outperformed existing CNN-based state-of-the-art methods, such as PODNet, LUCIR, and BiC, across nearly all experimental settings.
As shown in Figure 5, each component of the ViTIL recipe contributes to improved performance and a "flatter" accuracy degradation slope compared to standard ResNet and ViT baselines. Key findings include:
- ImageNet-1000 Performance: In the B500 setup, ViTIL achieved 69.20% top-1 accuracy, a 1.69% improvement over previous benchmarks.
- Computational Efficiency: The ViT-tiny model used in ViTIL requires only 1.1G FLOPs, compared to 1.8G FLOPs for a ResNet-18 baseline, offering better performance with lower computational cost.
- Training Dynamics: The convolutional stem reduces the training time required for saturation from over 2000 epochs to approximately 800 epochs.
Conclusion
The ViTIL framework proves that Vision Transformers can be highly effective for incremental learning when their specific architectural needs are addressed. By combining convolutional priors with balanced finetuning and optimized optimization strategies, ViTIL sets a new standard for CIL. Future work will focus on reducing the training overhead further and exploring exemplar-free applications of these insights.
Summary updated