arXivDaily arXiv每日学术速递 周一至周五更新
arXiv 2209.08310cs.CV
收藏

动态早期退出网络的样本加权学习

Learning to Weight Samples for Dynamic Early-exiting Networks

Tsinghua University(清华大学);Carnegie Mellon University(卡内基梅隆大学);China Mobile Research Institute(中国移动研究院)

Yizeng Han, Yifan Pu, Zihang Lai, Chaofei Wang, Shiji Song, Junfen Cao, Wenhui Huang, Chao Deng, Gao Huang

摘要:

早期退出是提高深度网络推理效率的有效范例。通过构建具有不同资源需求(出口)的分类器,这样的网络允许在早期出口处输出简单的样本,从而消除了执行更深层的需求。虽然现有的工作主要集中在多出口网络的架构设计,这些模型的训练策略在很大程度上是未开发的。目前最先进的模型在训练过程中对所有样本的处理都是相同的。然而,在测试过程中的早期退出行为被忽视,导致培训和测试之间的差距。在本文中,我们建议弥合这一差距的样本加权。直观的、简单的样本,通常在推理过程中在网络的早期退出,应该对训练早期分类器做出更多贡献。然而,后期分类器应该强调硬样本(大多数来自更深层)的训练。我们的工作建议采用一个权重预测网络来加权每个出口处不同训练样本的损失。该权重预测网络和骨干模型在具有新的优化目标的元学习框架下联合优化。通过将推理过程中的自适应行为引入训练阶段,我们表明所提出的加权机制始终提高了分类精度和推理效率之间的权衡。代码可在https://github.com/LeapLabTHU/L2W-DEN上获得。

英文摘要:

Early exiting is an effective paradigm for improving the inference efficiency of deep networks. By constructing classifiers with varying resource demands (the exits), such networks allow easy samples to be output at early exits, removing the need for executing deeper layers. While existing works mainly focus on the architectural design of multi-exit networks, the training strategies for such models are largely left unexplored. The current state-of-the-art models treat all samples the same during training. However, the early-exiting behavior during testing has been ignored, leading to a gap between training and testing. In this paper, we propose to bridge this gap by sample weighting. Intuitively, easy samples, which generally exit early in the network during inference, should contribute more to training early classifiers. The training of hard samples (mostly exit from deeper layers), however, should be emphasized by the late classifiers. Our work proposes to adopt a weight prediction network to weight the loss of different training samples at each exit. This weight prediction network and the backbone model are jointly optimized under a meta-learning framework with a novel optimization objective. By bringing the adaptive behavior during inference into the training phase, we show that the proposed weighting mechanism consistently improves the trade-off between classification accuracy and inference efficiency. Code is available at https://github.com/LeapLabTHU/L2W-DEN.

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

↑