尽管知识蒸馏有经验成功,但仍然缺乏理论基础,可以自然地导致计算廉价的实现。为了解决这一问题,我们使用最近提出的熵函数来促进信息理论与知识蒸馏之间的替代联系。在这样做时,我们介绍了两个不同的互补损失,旨在最大限度地提高学生和教师陈述之间的相关性和互信。我们的方法对知识蒸馏和跨模型转移任务的最先进的竞争性能实现了最先进的,同时产生明显较低的培训开销,而不是密切相关和类似的方法。我们进一步展示了我们对二元蒸馏任务的方法的有效性,由此,我们将光线光到新的最先进的二进制量化。代码,评估协议和培训的型号将公开可用。
translated by 谷歌翻译
Often we wish to transfer representational knowledge from one neural network to another. Examples include distilling a large network into a smaller one, transferring knowledge from one sensory modality to a second, or ensembling a collection of models into a single estimator. Knowledge distillation, the standard approach to these problems, minimizes the KL divergence between the probabilistic outputs of a teacher and student network. We demonstrate that this objective ignores important structural knowledge of the teacher network. This motivates an alternative objective by which we train a student to capture significantly more information in the teacher's representation of the data. We formulate this objective as contrastive learning. Experiments demonstrate that our resulting new objective outperforms knowledge distillation and other cutting-edge distillers on a variety of knowledge transfer tasks, including single model compression, ensemble distillation, and cross-modal transfer. Our method sets a new state-of-the-art in many transfer tasks, and sometimes even outperforms the teacher network when combined with knowledge distillation.
translated by 谷歌翻译
在这项工作中,我们提出了相互信息最大化知识蒸馏(MIMKD)。我们的方法使用对比目标来同时估计,并最大化教师和学生网络之间的本地和全球特征表示的相互信息的下限。我们通过广泛的实验证明,这可以通过将知识从更加性能但计算昂贵的模型转移来改善低容量模型的性能。这可用于产生更好的模型,可以在具有低计算资源的设备上运行。我们的方法灵活,我们可以将具有任意网络架构的教师蒸馏到任意学生网络。我们的经验结果表明,MIMKD优于各种学生教师对的竞争方法,具有不同的架构,以及学生网络的容量极低。我们能够通过从Reset-50蒸馏出来的知识,从基线精度为Shufflenetv2获得74.55%的精度。在Imagenet上,我们使用Reset-34教师网络将Reset-18网络从68.88%提高到70.32%的准确度(1.44%+)。
translated by 谷歌翻译
One of the most efficient methods for model compression is hint distillation, where the student model is injected with information (hints) from several different layers of the teacher model. Although the selection of hint points can drastically alter the compression performance, conventional distillation approaches overlook this fact and use the same hint points as in the early studies. Therefore, we propose a clustering based hint selection methodology, where the layers of teacher model are clustered with respect to several metrics and the cluster centers are used as the hint points. Our method is applicable for any student network, once it is applied on a chosen teacher network. The proposed approach is validated in CIFAR-100 and ImageNet datasets, using various teacher-student pairs and numerous hint distillation methods. Our results show that hint points selected by our algorithm results in superior compression performance compared to state-of-the-art knowledge distillation algorithms on the same student models and datasets.
translated by 谷歌翻译
无教师的在线知识蒸馏(KD)旨在培训多个学生模型的合奏,并彼此提炼知识。尽管现有的在线KD方法实现了理想的性能,但它们通常专注于阶级概率作为核心知识类型,而忽略了宝贵的特征代表性信息。我们为在线KD提供了一个相互的对比学习(MCL)框架。 MCL的核心思想是以在线方式进行对比分布的相互交互和对比度分布的转移。我们的MCL可以汇总跨网络嵌入信息,并最大化两个网络之间的相互信息的下限。这使每个网络能够从他人那里学习额外的对比知识,从而提供更好的特征表示形式,从而提高视觉识别任务的性能。除最后一层外,我们还将MCL扩展到辅助特征细化模块辅助的几个中间层。这进一步增强了在线KD的表示能力。关于图像分类和转移学习到视觉识别任务的实验表明,MCL可以针对最新的在线KD方法带来一致的性能提高。优势表明,MCL可以指导网络生成更好的特征表示。我们的代码可在https://github.com/winycg/mcl上公开获取。
translated by 谷歌翻译
Despite the fact that deep neural networks are powerful models and achieve appealing results on many tasks, they are too large to be deployed on edge devices like smartphones or embedded sensor nodes. There have been efforts to compress these networks, and a popular method is knowledge distillation, where a large (teacher) pre-trained network is used to train a smaller (student) network. However, in this paper, we show that the student network performance degrades when the gap between student and teacher is large. Given a fixed student network, one cannot employ an arbitrarily large teacher, or in other words, a teacher can effectively transfer its knowledge to students up to a certain size, not smaller. To alleviate this shortcoming, we introduce multi-step knowledge distillation, which employs an intermediate-sized network (teacher assistant) to bridge the gap between the student and the teacher. Moreover, we study the effect of teacher assistant size and extend the framework to multi-step distillation. Theoretical analysis and extensive experiments on CIFAR-10,100 and ImageNet datasets and on CNN and ResNet architectures substantiate the effectiveness of our proposed approach.
translated by 谷歌翻译
Transferring knowledge from a teacher neural network pretrained on the same or a similar task to a student neural network can significantly improve the performance of the student neural network. Existing knowledge transfer approaches match the activations or the corresponding handcrafted features of the teacher and the student networks. We propose an information-theoretic framework for knowledge transfer which formulates knowledge transfer as maximizing the mutual information between the teacher and the student networks. We compare our method with existing knowledge transfer methods on both knowledge distillation and transfer learning tasks and show that our method consistently outperforms existing methods. We further demonstrate the strength of our method on knowledge transfer across heterogeneous network architectures by transferring knowledge from a convolutional neural network (CNN) to a multi-layer perceptron (MLP) on CIFAR-10. The resulting MLP significantly outperforms the-state-of-the-art methods and it achieves similar performance to the CNN with a single convolutional layer. * Contributed during an internship at Amazon.
translated by 谷歌翻译
Knowledge distillation aims at transferring knowledge acquired in one model (a teacher) to another model (a student) that is typically smaller. Previous approaches can be expressed as a form of training the student to mimic output activations of individual data examples represented by the teacher. We introduce a novel approach, dubbed relational knowledge distillation (RKD), that transfers mutual relations of data examples instead. For concrete realizations of RKD, we propose distance-wise and angle-wise distillation losses that penalize structural differences in relations. Experiments conducted on different tasks show that the proposed method improves educated student models with a significant margin. In particular for metric learning, it allows students to outperform their teachers' performance, achieving the state of the arts on standard benchmark datasets.
translated by 谷歌翻译
神经网络二进制通过将其权重和激活量化为1位来加速深层模型。但是,二进制神经网络(BNN)与其完整精确(FP)对应物之间仍然存在巨大的性能差距。由于早期作品中权重二进制引起的量化误差已减少,因此激活二进化成为进一步提高准确性的主要障碍。 BNN表征了独特而有趣的结构,其中二进制和潜在的fp激活存在于同一正向通行证中(\ textit {i.e。} $ \ text {binarize}(\ mathbf {a} _f {a} _f)= \ mathbf {a a} _b $) 。为了减轻从FP到二元激活的二进化操作引起的信息降解,我们在通过互信息(MI)最大化的镜头训练BNN时建立了一种新颖的对比学习框架。将MI作为指标引入,以衡量二进制和FP激活之间共享的信息,这有助于对比度学习。具体而言,通过从相同输入样品中拉出二进制和FP激活的正对,以及从不同样品中推动负面对(负面对数的数量可以大大),从而极大地增强了BNN的表示能力。这使下游任务不仅有益于分类,而且还受益于分类和深度估计,〜\ textit {etc}。实验结果表明,我们的方法可以作为现有最新二元方法的堆积模块实现NYUD-V2的能力。
translated by 谷歌翻译
Knowledge distillation is a widely applicable techniquefor training a student neural network under the guidance of a trained teacher network. For example, in neural network compression, a high-capacity teacher is distilled to train a compact student; in privileged learning, a teacher trained with privileged data is distilled to train a student without access to that data. The distillation loss determines how a teacher's knowledge is captured and transferred to the student. In this paper, we propose a new form of knowledge distillation loss that is inspired by the observation that semantically similar inputs tend to elicit similar activation patterns in a trained network. Similarity-preserving knowledge distillation guides the training of a student network such that input pairs that produce similar (dissimilar) activations in the teacher network produce similar (dissimilar) activations in the student network. In contrast to previous distillation methods, the student is not required to mimic the representation space of the teacher, but rather to preserve the pairwise similarities in its own representation space. Experiments on three public datasets demonstrate the potential of our approach.
translated by 谷歌翻译
知识蒸馏(KD)是一个有效的框架,旨在将有意义的信息从大型老师转移到较小的学生。通常,KD通常涉及如何定义和转移知识。以前的KD方法通常着重于挖掘各种形式的知识,例如功能地图和精致信息。但是,知识源自主要监督任务,因此是高度特定于任务的。在自我监督的代表学习的最新成功中,我们提出了一项辅助自我实施的增强任务,以指导网络学习更多有意义的功能。因此,我们可以从KD的这项任务中得出软性自我实施的增强分布作为更丰富的黑暗知识。与以前的知识不同,此分布编码从监督和自我监督的特征学习中编码联合知识。除了知识探索之外,我们建议在各个隐藏层上附加几个辅助分支,以充分利用分层特征图。每个辅助分支都被指导学习自学的增强任务,并将这种分布从教师到学生提炼。总体而言,我们称我们的KD方法为等级自我实施的增强知识蒸馏(HSSAKD)。标准图像分类的实验表明,离线和在线HSSAKD都在KD领域达到了最先进的表现。对象检测的进一步转移实验进一步验证了HSSAKD可以指导网络学习更好的功能。该代码可在https://github.com/winycg/hsakd上找到。
translated by 谷歌翻译
知识蒸馏是通过知识转移模型压缩的有效稳定的方法。传统知识蒸馏(KD)是将来自大型和训练有素的教师网络的知识转移到小型学生网络,这是一种单向过程。最近,已经提出了深度相互学习(DML)来帮助学生网络协同和同时学习。然而,据我们所知,KD和DML从未在统一的框架中共同探索,以解决知识蒸馏问题。在本文中,我们调查教师模型在KD中支持更值得信赖的监督信号,而学生则在DML中捕获教师的类似行为。基于这些观察,我们首先建议将KD与DML联合在统一的框架中。此外,我们提出了一个半球知识蒸馏(SOKD)方法,有效提高了学生和教师的表现。在这种方法中,我们在DML中介绍了同伴教学培训时尚,以缓解学生的模仿困难,并利用KD训练有素的教师提供的监督信号。此外,我们还显示我们的框架可以轻松扩展到基于功能的蒸馏方法。在CiFAR-100和Imagenet数据集上的广泛实验证明了所提出的方法实现了最先进的性能。
translated by 谷歌翻译
知识蒸馏通常涉及如何有效地定义和转移知识从教师到学生。尽管最近的自我监督的对比知识取得了最佳表现,但迫使网络学习此类知识可能会损害对原始班级识别任务的表示。因此,我们采用替代性的自我监督的增强任务来指导网络学习原始识别任务和自我监督的辅助任务的共同分布。它被证明是一种更丰富的知识,可以提高表示能力而不会失去正常的分类能力。此外,以前的方法仅在最终层之间传递概率知识是不完整的。我们建议将几个辅助分类器附加到层次中间特征图中,以生成多样化的自我监督知识,并执行一对一的转移以彻底教授学生网络。我们的方法显着超过了先前的SOTA SSKD,CIFAR-100的平均改善为2.56 \%,并且在广泛使用的网络对上的Imagenet上有0.77 \%的提高。代码可在https://github.com/winycg/hsakd上找到。
translated by 谷歌翻译
在本文中,我们探讨了一项新颖而雄心勃勃的知识转移任务,称为知识分解〜(KF)。 KF的核心思想在于知识的模块化和组装性:鉴于验证的网络模型作为输入,KF旨在将其分解为多个因素网络,每个网络仅处理专用任务,并从源中维护特定于任务的知识,并从源网络。此类因素网络是由任务分开的,可以直接组装,而无需进行任何微调,以产生更有能力的组合任务网络。换句话说,因子网络用作像乐高积木一样的构建块,使我们能够以插件的方式构建自定义网络。具体而言,每个因素网络都包含两个模块,这是一个通用知识模块,该模块是任务无关并由所有因素网络共享的模块,以及一个专门针对因子网络本身的任务特定模块。我们介绍了一个信息理论目标,即Infomax-Bottleneck〜(IMB),以通过优化学习表示和输入之间的相互信息来执行KF。各种基准的实验表明,派生因子网络不仅在专用任务,而且还可以分离,同时享有更好的解释性和模块化。此外,学到的公共知识表示会为转移学习带来令人印象深刻的结果。
translated by 谷歌翻译
Knowledge distillation (KD) has been actively studied for image classification tasks in deep learning, aiming to improve the performance of a student based on the knowledge from a teacher. However, applying KD in image regression with a scalar response variable has been rarely studied, and there exists no KD method applicable to both classification and regression tasks yet. Moreover, existing KD methods often require a practitioner to carefully select or adjust the teacher and student architectures, making these methods less flexible in practice. To address the above problems in a unified way, we propose a comprehensive KD framework based on cGANs, termed cGAN-KD. Fundamentally different from existing KD methods, cGAN-KD distills and transfers knowledge from a teacher model to a student model via cGAN-generated samples. This novel mechanism makes cGAN-KD suitable for both classification and regression tasks, compatible with other KD methods, and insensitive to the teacher and student architectures. An error bound for a student model trained in the cGAN-KD framework is derived in this work, providing a theory for why cGAN-KD is effective as well as guiding the practical implementation of cGAN-KD. Extensive experiments on CIFAR-100 and ImageNet-100 show that we can combine state of the art KD methods with the cGAN-KD framework to yield a new state of the art. Moreover, experiments on Steering Angle and UTKFace demonstrate the effectiveness of cGAN-KD in image regression tasks, where existing KD methods are inapplicable.
translated by 谷歌翻译
最先进的蒸馏方法主要基于中间层的深层特征,而logit蒸馏的重要性被极大地忽略了。为了提供研究逻辑蒸馏的新观点,我们将经典的KD损失重新分为两个部分,即目标类知识蒸馏(TCKD)和非目标类知识蒸馏(NCKD)。我们凭经验研究并证明了这两个部分的影响:TCKD转移有关训练样本“难度”的知识,而NCKD是Logit蒸馏起作用的重要原因。更重要的是,我们揭示了经典的KD损失是一种耦合的配方,该配方抑制了NCKD的有效性,并且(2)限制了平衡这两个部分的灵活性。为了解决这些问题,我们提出了脱钩的知识蒸馏(DKD),使TCKD和NCKD能够更有效,更灵活地发挥其角色。与基于功能的复杂方法相比,我们的DKD可相当甚至更好的结果,并且在CIFAR-100,ImageNet和MS-Coco数据集上具有更好的培训效率,用于图像分类和对象检测任务。本文证明了Logit蒸馏的巨大潜力,我们希望它对未来的研究有所帮助。该代码可从https://github.com/megvii-research/mdistiller获得。
translated by 谷歌翻译
除了使用硬标签的标准监督学习外,通常在许多监督学习设置中使用辅助损失来改善模型的概括。例如,知识蒸馏增加了第二个教师模仿模型训练的损失,在该培训中,教师可能是一个验证的模型,可以输出比标签更丰富的分布。同样,在标记数据有限的设置中,弱标记信息以标签函数的形式使用。此处引入辅助损失来对抗标签函数,这些功能可能是基于嘈杂的规则的真实标签近似值。我们解决了学习以原则性方式结合这些损失的问题。我们介绍AMAL,该AMAL使用元学习在验证度量上学习实例特定的权重,以实现损失的最佳混合。在许多知识蒸馏和规则降解域中进行的实验表明,Amal在这些领域中对竞争基准的增长可显着。我们通过经验分析我们的方法,并分享有关其提供性能提升的机制的见解。
translated by 谷歌翻译
Electroencephalogram (EEG) has been one of the common neuromonitoring modalities for real-world brain-computer interfaces (BCIs) because of its non-invasiveness, low cost, and high temporal resolution. Recently, light-weight and portable EEG wearable devices based on low-density montages have increased the convenience and usability of BCI applications. However, loss of EEG decoding performance is often inevitable due to reduced number of electrodes and coverage of scalp regions of a low-density EEG montage. To address this issue, we introduce knowledge distillation (KD), a learning mechanism developed for transferring knowledge/information between neural network models, to enhance the performance of low-density EEG decoding. Our framework includes a newly proposed similarity-keeping (SK) teacher-student KD scheme that encourages a low-density EEG student model to acquire the inter-sample similarity as in a pre-trained teacher model trained on high-density EEG data. The experimental results validate that our SK-KD framework consistently improves motor-imagery EEG decoding accuracy when number of electrodes deceases for the input EEG data. For both common low-density headphone-like and headband-like montages, our method outperforms state-of-the-art KD methods across various EEG decoding model architectures. As the first KD scheme developed for enhancing EEG decoding, we foresee the proposed SK-KD framework to facilitate the practicality of low-density EEG-based BCI in real-world applications.
translated by 谷歌翻译
我们呈现了对比邻域对准(CNA),一种歧管学习方法来维持学习特征的拓扑,由此映射到源(教师)模型的附近表示的数据点也被目标(学生)模型映射到邻居。目标模型旨在模拟使用对比损耗来模拟源代表空间的局部结构。CNA是一种无人监督的学习算法,不需要对各个样本的地面真理标签。CNA在三种情况下示出:歧管学习,其中模型在尺寸减小空间中保持原始数据的本地拓扑;模型蒸馏,其中小学生模型培训以模仿更大的老师;和遗留模型更新,其中旧模型被更强大的更强大的型号。实验表明,CNA能够在高维空间中捕获歧管,并与其域中的竞争方法相比提高性能。
translated by 谷歌翻译
知识蒸馏是将“知识”从大型模型(教师)转移到更紧凑的(学生)的过程,通常在模型压缩的背景下使用。当两个模型都具有相同的体系结构时,此过程称为自distillation。几项轶事表明,一个自灭的学生可以在持有的数据上胜过老师的表现。在这项工作中,我们系统地研究了许多设置。我们首先表明,即使有一个高度准确的老师,自我介绍也使学生在所有情况下都可以超越老师。其次,我们重新审视了(自我)蒸馏的现有理论解释,并确定矛盾的例子,揭示了这些解释的可能缺点。最后,我们通过损失景观几何形状的镜头为自我鉴定的动态提供了另一种解释。我们进行了广泛的实验,以表明自我验证会导致最小化的最小值,从而导致更好的概括。
translated by 谷歌翻译