Abstract
Knowledge distillation aims at obtaining a compact and effective model by learning the mapping function from a much larger one. Due to the limited capacity of the student, the student would underfit the teacher. Therefore, student performance would unexpectedly drop when distilling from an oversized teacher, termed the capacity gap problem. We investigate this problem by study the gap of confidence between teacher and student. We find that the magnitude of confidence is not necessary for knowledge distillation and could harm the student performance if the student are forced to learn confidence. We propose Spherical Knowledge Distillation to eliminate this gap explicitly, which eases the underfitting problem. We find this novel knowledge representation can improve compact models with much larger teachers and is robust to temperature. We conducted experiments on both CIFAR100 and ImageNet, and achieve significant improvement. Specifically, we train ResNet18 to 73.0 accuracy, which is a substantial improvement over previous SOTA and is on par with resnet34 almost twice the student size.
Introduction: The Capacity Gap Paradox
In deep learning, the prevailing intuition is that a more powerful "teacher" model should yield a more capable "student" model through knowledge distillation (KD). However, empirical evidence often reveals a "Capacity Gap": as the teacher's size and complexity increase beyond a certain point, the student's performance begins to plateau or even decline. This phenomenon suggests that the student model lacks the capacity to fully absorb the teacher's complex mapping.
Recent research identifies overconfidence in large models as a primary driver of this gap. Large teachers minimize training loss by producing output values (logits) with high magnitudes, representing extreme confidence. Small students, constrained by fewer parameters, struggle to replicate these magnitudes. This struggle leads to underfitting the actual class relationships as the student wastes capacity trying to match the teacher's extreme confidence levels.
Methods: Spherical Knowledge Distillation (SKD)
To address the capacity gap, we propose Spherical Knowledge Distillation (SKD). The core idea is to decouple the "knowledge" (the relative relationship between classes) from the "confidence" (the magnitude of the logits).
In standard KD, students attempt to mimic the teacher's soft probability distributions directly. In contrast, SKD projects both teacher and student logits onto a unit sphere by dividing them by their $l^2$ norm. This normalization step effectively strips away the confidence gap. To ensure the resulting vectors are suitable for the Softmax function, they are rescaled by the average norm of the teacher's logits ($l_{avg}$). The student then minimizes the KL-divergence between these spherical distributions, allowing it to focus entirely on the directional information—the true "knowledge"—provided by the teacher.
Experimental Results
We validated SKD on the CIFAR-100 and ImageNet datasets using various network architectures, comparing it against standard KD and other state-of-the-art methods.
Solving the Capacity Gap
A critical finding is that SKD successfully mitigates the performance drop associated with oversized teachers. While standard KD accuracy falls as teachers grow from ResNet-32 to ResNet-110, SKD maintains a steady upward trajectory in student performance.
Performance Benchmarks
On the ImageNet dataset, SKD achieved a state-of-the-art (SOTA) result for ResNet-18. By distilling from a ResNet-50 teacher, the ResNet-18 student reached 73.0% accuracy, a significant jump from the ~69.2% typically seen with standard KD. Remarkably, this performance is nearly identical to a ResNet-34 model (73.3%), which has nearly double the parameters of the ResNet-18 student.
Furthermore, SKD demonstrates exceptional robustness to the "temperature" hyperparameter ($\tau$), which is notoriously difficult to tune in standard KD. Because the logits are normalized, the inherent "softness" of the distribution is better controlled, making the training process more stable across different settings.
Conclusion
Spherical Knowledge Distillation offers a geometrically intuitive solution to the capacity gap problem. By recognizing that logit magnitude is often a byproduct of model size rather than useful knowledge, SKD allows compact models to learn effectively from even the largest teachers. This approach not only sets new performance benchmarks but also simplifies the distillation process by reducing sensitivity to hyperparameters.
Summary updated