BicKD: Bilateral Contrastive Knowledge Distillation
This work addresses a limitation in knowledge distillation for machine learning practitioners, offering an incremental improvement over existing methods.
The paper tackles the problem of vanilla knowledge distillation lacking class-wise comparison and structural constraints by proposing BicKD, a bilateral contrastive knowledge distillation method that introduces a novel loss to enhance orthogonality among classes and consistency within classes, resulting in consistent outperformance of state-of-the-art techniques across various models and benchmarks.
Knowledge distillation (KD) is a machine learning framework that transfers knowledge from a teacher model to a student model. The vanilla KD proposed by Hinton et al. has been the dominant approach in logit-based distillation and demonstrates compelling performance. However, it only performs sample-wise probability alignment between teacher and student's predictions, lacking an mechanism for class-wise comparison. Besides, vanilla KD imposes no structural constraint on the probability space. In this work, we propose a simple yet effective methodology, bilateral contrastive knowledge distillation (BicKD). This approach introduces a novel bilateral contrastive loss, which intensifies the orthogonality among different class generalization spaces while preserving consistency within the same class. The bilateral formulation enables explicit comparison of both sample-wise and class-wise prediction patterns between teacher and student. By emphasizing probabilistic orthogonality, BicKD further regularizes the geometric structure of the predictive distribution. Extensive experiments show that our BicKD method enhances knowledge transfer, and consistently outperforms state-of-the-art knowledge distillation techniques across various model architectures and benchmarks.