arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2404.09326cs.CVcs.AIcs.LG
收藏

用于视觉Transformer小样本蒸馏的权重复制与低秩适配方法

Weight Copy and Low-Rank Adaptation for Few-Shot Distillation of Vision Transformers

University of Bucharest(布加勒斯特大学);Norwegian University of Science and Technology(挪威科技大学);University of Medicine and Pharmacy “Carol Davila”(卡罗尔·达维拉医药大学)

Diana-Nicoleta Grigore, Mariana-Iuliana Georgescu, Jon Alvarez Justo, Tor Johansen, Andreea Iuliana Ionescu, Radu Tudor Ionescu

AI总结:

针对小样本下视觉Transformer知识蒸馏问题,提出结合权重复制与增强版LoRA的蒸馏方法,经多领域多任务实验验证性能优于现有最优方案,且各组件均有效。

摘要:

小样本知识蒸馏是近年兴起的一种可行方案,可在有限数据与计算资源条件下利用大规模预训练模型的知识。本文提出一种面向视觉Transformer的新型小样本特征蒸馏方法,该方法基于两个核心步骤展开。首先,利用视觉Transformer具备一致深度结构的特性,将现有预训练视觉Transformer(教师模型)中间层的权重复制到更浅的架构(学生模型)中,其中间隔因子可控制学生Transformer相对于教师模型的复杂度。随后,采用增强版低秩适配(Low-Rank Adaptation, LoRA)在小样本场景下向学生模型蒸馏知识,旨在还原被跳过的教师层所执行的信息处理过程。我们分别以有监督和自监督Transformer作为教师模型,在来自自然、医学、卫星图像等不同领域、涵盖分类与分割任务的6个数据集上开展了全面实验。实证结果表明,该方法的性能优于现有最优对比方法;此外,消融实验结果也验证了所提流程中每个组件的有效性。我们的代码已发布于https://github.com/dianagrigore/WeCoLoRA。

英文摘要:

Few-shot knowledge distillation recently emerged as a viable approach to harness the knowledge of large-scale pre-trained models, using limited data and computational resources. In this paper, we propose a novel few-shot feature distillation approach for vision transformers. Our approach is based on two key steps. Leveraging the fact that vision transformers have a consistent depth-wise structure, we first copy the weights from intermittent layers of existing pre-trained vision transformers (teachers) into shallower architectures (students), where the intermittence factor controls the complexity of the student transformer with respect to its teacher. Next, we employ an enhanced version of Low-Rank Adaptation (LoRA) to distill knowledge into the student in a few-shot scenario, aiming to recover the information processing carried out by the skipped teacher layers. We present comprehensive experiments with supervised and self-supervised transformers as teachers, on six data sets from various domains (natural, medical and satellite images) and tasks (classification and segmentation). The empirical results confirm the superiority of our approach over state-of-the-art competitors. Moreover, the ablation results demonstrate the usefulness of each component of the proposed pipeline. We release our code at https://github.com/dianagrigore/WeCoLoRA.

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

↑