In this paper we revisit the efficacy of knowledge distillation as a function matching and metric learning problem. In doing so we verify three important design decisions, namely the normalisation, soft maximum function, and projection layers as key ingredients. We theoretically show that the projector implicitly encodes information on past examples, enabling relational gradients for the student. We then show that the normalisation of representations is tightly coupled with the training dynamics of this projector, which can have a large impact on the students performance. Finally, we show that a simple soft maximum function can be used to address any significant capacity gap problems. Experimental results on various benchmark datasets demonstrate that using these insights can lead to superior or comparable performance to state-of-the-art knowledge distillation techniques, despite being much more computationally efficient. In particular, we obtain these results across image classification (CIFAR100 and ImageNet), object detection (COCO2017), and on more difficult distillation objectives, such as training data efficient transformers, whereby we attain a 77.2% top-1 accuracy with DeiT-Ti on ImageNet.
翻译:本文重新审视知识蒸馏作为函数匹配与度量学习问题的有效性。通过此项研究,我们验证了三个关键设计要素——即归一化、软最大值函数和投影层——的重要性。我们从理论上证明,投影层隐式编码了过往样本的信息,从而为学生网络提供关系型梯度。随后,我们指出表示向量的归一化与投影层的训练动态紧密耦合,这可能对学生网络的性能产生重大影响。最后,我们展示了一个简单的软最大值函数即可有效解决显著的容量差距问题。在多个基准数据集上的实验结果表明,基于这些见解的方法尽管计算效率大幅提升,仍能获得与最先进知识蒸馏技术相当甚至更优的性能。特别地,我们在图像分类(CIFAR100和ImageNet)、目标检测(COCO2017)以及更具挑战性的蒸馏目标(如训练数据高效型Transformer)上均取得了这一结果——在ImageNet上使用DeiT-Ti实现了77.2%的top-1准确率。