Skip to main content
QUICK REVIEW

[Paper Review] A Closer Look at Knowledge Distillation with Features, Logits, and Gradients

Yen-Chang Hsu, James Smith|arXiv (Cornell University)|Mar 18, 2022
Domain Adaptation and Few-Shot LearningComputer Science7 citations
TL;DR

This paper proposes a unified framework for knowledge distillation (KD) that systematically compares knowledge sources—features, logits, and gradients—by approximating KL divergence via Taylor expansion. It finds that logits are generally the most effective knowledge source, while gradient-weighted feature distillation improves performance, with feature dimensionality being a critical design factor for efficient KD.

ABSTRACT

Knowledge distillation (KD) is a substantial strategy for transferring learned knowledge from one neural network model to another. A vast number of methods have been developed for this strategy. While most method designs a more efficient way to facilitate knowledge transfer, less attention has been put on comparing the effect of knowledge sources such as features, logits, and gradients. This work provides a new perspective to motivate a set of knowledge distillation strategies by approximating the classical KL-divergence criteria with different knowledge sources, making a systematic comparison possible in model compression and incremental learning. Our analysis indicates that logits are generally a more efficient knowledge source and suggests that having sufficient feature dimensions is crucial for the model design, providing a practical guideline for effective KD-based transfer learning.

Motivation & Objective

  • To resolve inconsistencies in prior KD literature regarding the relative effectiveness of knowledge sources like features, logits, and gradients.
  • To develop a unified mathematical framework that enables fair comparison of distillation using different knowledge sources under the same optimization criteria.
  • To investigate how model design, particularly feature dimensionality, affects the effectiveness of different knowledge sources in KD.
  • To evaluate the proposed framework in two key transfer learning scenarios: model compression and incremental learning.

Proposed method

  • The paper uses Taylor expansion to approximate the classical KL-divergence loss in KD, expressing it in terms of logits, features, and gradients from the teacher model.
  • It derives a generalized divergence criterion that allows distillation with logits, features, and gradients under a single unified optimization framework.
  • For feature distillation, it introduces a gradient-weighted importance mechanism, where feature importance is determined by the magnitude of gradients from the teacher model.
  • The method formulates distillation objectives using squared error losses for logits and features, with gradient-based weighting to prioritize informative features.
  • The framework is instantiated into three variants: Logits-SE (logits distillation), Features-SE (plain feature distillation), and Weighted H Features-SE (gradient-weighted feature distillation).
  • Experiments are conducted on model compression and incremental learning benchmarks, using standard datasets like CIFAR-10 and CIFAR-100 with task-incremental learning protocols.

Experimental results

Research questions

  • RQ1Which knowledge source—features, logits, or gradients—yields the most effective knowledge distillation across different learning tasks?
  • RQ2How does the dimensionality of the student’s penultimate layer features impact the effectiveness of different knowledge sources?
  • RQ3Can a unified mathematical framework reconcile and compare distillation methods based on different knowledge sources under the same optimization criteria?
  • RQ4Does gradient-based feature weighting improve the performance of feature-based distillation compared to uniform weighting?
  • RQ5Is the relative effectiveness of knowledge sources consistent across different transfer learning scenarios, such as model compression and incremental learning?

Key findings

  • Logits are generally the most effective knowledge source for distillation, outperforming both plain and gradient-weighted features in both model compression and incremental learning tasks.
  • Weighted feature distillation using gradients from the teacher model significantly improves performance over plain feature distillation, with a 15.9% accuracy gain on S-CIFAR100 in incremental learning.
  • The effectiveness of feature-based distillation is highly sensitive to the dimensionality of the penultimate layer features, with higher dimensions leading to better performance.
  • In incremental learning, the best-performing method, Logits-SE, achieved 95.3% accuracy on S-CIFAR10 and 78.3% on S-CIFAR100, outperforming all baselines including EWC and MAS.
  • The proposed framework provides a consistent and mathematically grounded basis for comparing distillation strategies, resolving inconsistencies in prior work due to differing optimization criteria.

Read this paper

Open the full text in the Nubint reader and ask about any passage as you read.

Read this paper on Nubint

This review was generated by AI from the original paper. Please check the paper before citing it.