arXivDaily arXiv每日学术速递 周一至周五更新
arXiv周末暂无论文更新,休息一下吧,周末愉快~~
arXiv 2407.11802cs.CVcs.AI

判别性与一致性表征蒸馏

Discriminative and Consistent Representation Distillation

Imperial College London(伦敦帝国学院)

Nikos Giakoumoglou, Tania Stathaki

AI总结:

针对现有对比蒸馏依赖外部记忆库、温度参数固定的问题,提出结合对比实例判别与一致性正则的DCD方法,通过批内采样和可学习参数实现高效蒸馏,在多任务多数据集上取得有竞争力的性能并降低资源消耗。

摘要:

知识蒸馏(Knowledge Distillation, KD)将大型教师模型的知识迁移到更小的学生模型中。尽管对比目标已被证明在自监督场景下学习结构化表征有效,但它在蒸馏中的应用受限于两个实际缺陷:依赖外部记忆库进行负采样,以及固定的温度超参数限制了在不同训练阶段和师生模型对之间的适应性。因此我们提出判别性与一致性表征蒸馏(Discriminative and Consistent Representation Distillation, DCD),该方法将对比实例判别与跨模型相似度矩阵上的一致性正则项相结合。对比项将每个学生表征与对应的教师表征对齐,而一致性项对该矩阵行归一化视图和列归一化视图之间的不对称性进行惩罚,约束仅靠实例判别无法约束的非对角结构;我们证明当该矩阵为对称矩阵时,一致性项恰好为零。我们进一步引入了高效的批内采样方法,无需外部记忆库,并设置可学习的缩放和偏置参数,在训练过程中自适应控制蒸馏信号的锐度和偏移量。该方法与标准KD的训练速度相当,仅额外增加6.6万个参数。通过在CIFAR-100、ImageNet和MS-COCO上的大量实验,以及向STL-10和Tiny ImageNet的跨数据集迁移实验,我们表明该方法在分类、目标检测和迁移任务中取得了具有竞争力的性能,同时与现有对比蒸馏方法相比,大幅降低了内存消耗和训练时间。

英文摘要:

Knowledge Distillation (KD) transfers knowledge from a large teacher to a smaller student model. While contrastive objectives have proven effective for learning structured representations in self-supervised settings, their use in distillation is hindered by two practical shortcomings: the reliance on external memory banks for negative sampling, and fixed temperature hyperparameters that limit adaptability across training stages and teacher-student pairs. We therefore propose Discriminative and Consistent Representation Distillation (DCD), which combines contrastive instance discrimination with a consistency regularization term over the cross-model similarity matrix. The contrastive term aligns each student representation with its teacher counterpart, while the consistency term penalizes asymmetry between the row-normalized and column-normalized views of that matrix, constraining the off-diagonal structure that instance discrimination alone leaves free; we show that it vanishes precisely when this matrix is symmetric. We further introduce an efficient in-batch sampling that eliminates external memory banks, and learnable scale and bias parameters that adapt during training to control the sharpness and offset of the distillation signal. The method matches the training speed of standard KD while adding only 66K additional parameters. Through extensive experiments on CIFAR-100, ImageNet, and MS-COCO, together with cross-dataset transfer to STL-10 and Tiny ImageNet, we show that our approach achieves competitive performance in classification, object detection, and transfer, while substantially reducing memory consumption and training time compared to existing contrastive distillation methods.

机构、总结、中文摘要均由AI分析而来,可能存在错误,请以论文正文为准。

↑