用极少真实数据+生成数据,高效训练小模型。
Hybrid Data-Free Knowledge Distillation
- 结合少量真实数据与生成数据,通过教师引导生成高质量合成样本。
- 仅需现有方法1/120的收集数据量,达到顶尖性能。
- 适合数据受限场景,如隐私保护或资源有限的部署环境。
数据无关的知识蒸馏旨在不使用教师网络原始训练数据的情况下,从预训练的大模型中学习一个紧凑的学生网络。现有基于采集和基于生成的方法分别依赖大量真实样本或合成样本,但在实际应用中因难以获取足够真实数据或准确模拟而表现受限。为此,我们提出一种新方法——混合数据无关知识蒸馏(HiDFD),仅需少量真实数据并生成充足样本进行学生网络训练。其包含两个核心模块:教师引导生成与学生蒸馏。教师引导生成模块利用教师网络指导生成对抗网络(GAN)从极少真实样本中生成高质量合成样本,设计特征融合机制防止过拟合,并通过类别频率平滑技术平衡各类别生成训练。学生蒸馏模块采用数据膨胀策略,结合真实与合成数据,通过基于分类器共享的特征对齐方法训练学生网络。在多个基准上的大量实验表明,相比现有方法,本方法仅需120倍更少的收集数据即可实现领先性能。代码已公开于https://github.com/tangjialiang97/HiDFD。
原文摘要 · Abstract (English)
Data-free knowledge distillation aims to learn a compact student network from a pre-trained large teacher network without using the original training data of the teacher network. Existing collection-based and generation-based methods train student networks by collecting massive real examples and generating synthetic examples, respectively. However, they inevitably become weak in practical scenarios due to the difficulties in gathering or emulating sufficient real-world data. To solve this problem, we propose a novel method called \textbf{H}ybr\textbf{i}d \textbf{D}ata-\textbf{F}ree \textbf{D}istillation (HiDFD), which leverages only a small amount of collected data as well as generates sufficient examples for training student networks. Our HiDFD comprises two primary modules, \textit{i.e.}, the teacher-guided generation and student distillation. The teacher-guided generation module guides a Generative Adversarial Network (GAN) by the teacher network to produce high-quality synthetic examples from very few real-world collected examples. Specifically, we design a feature integration mechanism to prevent the GAN from overfitting and facilitate the reliable representation learning from the teacher network. Meanwhile, we drive a category frequency smoothing technique via the teacher network to balance the generative training of each category. In the student distillation module, we explore a data inflation strategy to properly utilize a blend of real and synthetic data to train the student network via a classifier-sharing-based feature alignment technique. Intensive experiments across multiple benchmarks demonstrate that our HiDFD can achieve state-of-the-art performance using 120 times less collected data than existing methods. Code is available at https://github.com/tangjialiang97/HiDFD.
Thank you to arXiv for use of its open access interoperability. PaperDance 不是 arXiv 官方产品;中文卡片由大模型生成,请以原文为准。