Search to Distill: Pearls Are Everywhere but Not the Eyes

Yu Liu, Xuhui Jia, Mingxing Tan, Raviteja Vemulapalli, Yukun Zhu, Bradley Green, Xiaogang Wang

Introduction

Knowledge Distillation (KD) has become a cornerstone technique for model compression, enabling the transfer of performance from massive teacher models to compact student models suitable for edge deployment. Traditionally, this process treats the student architecture as a fixed container, focusing solely on optimizing its weights to mimic the teacher's outputs. However, this research argues that the student's architecture is just as critical as its parameters. By introducing Architecture-aware Knowledge Distillation (AKD), the authors demonstrate that the ideal student architecture is not universal but is instead uniquely tied to the specific structural knowledge of its teacher.

The Problem: Architecture-Teacher Incompatibility

The fundamental oversight in standard KD is the assumption that a good architecture for ground-truth labels is necessarily a good architecture for distillation. The authors posit that neural networks possess "structural knowledge" that makes certain architectures more compatible with specific teachers.

Conceptual overview of AKD vs. conventional NAS, highlighting how different teachers lead to different optimal student architectures.

As illustrated in the conceptual diagram above, a student architecture that excels when distilled from Teacher A might perform poorly when paired with Teacher B. If the student's structure cannot efficiently represent the teacher's internal logic, the distillation process becomes suboptimal. The challenge lies in finding the specific "pearl"—the ideal student architecture—within a massive search space for any given teacher.

Methods: Architecture-aware Knowledge Distillation (AKD)

To solve this compatibility problem, the authors propose a framework that uses Neural Architecture Search (NAS) guided by a KD-specific reward. Instead of searching for models that perform well on hard labels, AKD searches for models that are inherently "distillable" by a target teacher.

The AKD framework utilizing an RL agent to optimize for both distillation accuracy and mobile latency.

The AKD Loop

  1. KD-Guided NAS: A Reinforcement Learning (RL) agent (an RNN) samples student architectures from a factorized hierarchical search space, selecting parameters like convolution types, kernel sizes, and expansion ratios.
  2. Reward Mechanism: Each sampled architecture is trained via Knowledge Distillation from a fixed teacher (e.g., Inception-ResNet-v2 or EfficientNet-B7) for a limited number of proxy epochs.
  3. Multi-Objective Optimization: The RL agent receives a reward based on a combination of the student's distillation accuracy and its real-world inference latency on mobile hardware.

Key Insights and Results

The search process reveals that teachers indeed possess distinct structural preferences. When two identical RL agents search for students for different teachers, they converge to entirely different regions of the architecture search space. This confirms that "KD-friendliness" is a structural property.

Performance on ImageNet

On the ImageNet benchmark, AKDNet achieves state-of-the-art results:

  • AKDNet-15ms: Reaches 66.5% top-1 accuracy, significantly outperforming the conventional "NAS-then-distill" approach, which achieves only 63.9% at the same latency.
  • Efficiency: AKD models consistently require lower latency and fewer FLOPS than human-designed (MobileNet-v2) or standard NAS-designed counterparts while maintaining higher accuracy.

Generalization to Face Recognition

One of the most surprising findings is the transferability of these architectures. A student architecture optimized to "listen" to a teacher on ImageNet also performs better when distilled for face recognition tasks. In the MegaFace challenge, the AKDNet-M architecture achieved 98.42% accuracy, vastly outperforming standard mobile baselines. This suggests that structural compatibility between a teacher and student is largely task-independent.

Conclusion and Future Work

AKD shifts the focus of model compression from weight optimization to architectural synergy. While the search process is computationally intensive—requiring significant TPU resources—the resulting "pearls" offer unprecedented efficiency and performance. Future research may focus on reducing search costs and developing metrics to quantify the "structural similarity" between neural networks, further unlocking the potential of teacher-student pairings.

Summary updated

BibTeX
@inproceedings{liu2020search,
  author = {Yu Liu and Xuhui Jia and Mingxing Tan and Raviteja Vemulapalli and Yukun Zhu and Bradley Green and Xiaogang Wang},
  title = {{Search to Distill: Pearls Are Everywhere but Not the Eyes}},
  booktitle = {IEEE/CVF Conference on Computer Vision and Pattern Recognition},
  year = {2020},
  doi = {10.1109/cvpr42600.2020.00756},
}
Figure