Transfer learning on edge is challenging due to on-device limited resources. Existing work addresses this issue by training a subset of parameters or adding model patches. Developed with inference in mind, Inverted Residual Blocks (IRBs) split a convolutional layer into depthwise and pointwise convolutions, leading to more stacking layers, e.g., convolution, normalization, and activation layers. Though they are efficient for inference, IRBs require that additional activation maps are stored in memory for training weights for convolution layers and scales for normalization layers. As a result, their high memory cost prohibits training IRBs on resource-limited edge devices, and making them unsuitable in the context of transfer learning. To address this issue, we present MobileTL, a memory and computationally efficient on-device transfer learning method for models built with IRBs. MobileTL trains the shifts for internal normalization layers to avoid storing activation maps for the backward pass. Also, MobileTL approximates the backward computation of the activation layer (e.g., Hard-Swish and ReLU6) as a signed function which enables storing a binary mask instead of activation maps for the backward pass. MobileTL fine-tunes a few top blocks (close to output) rather than propagating the gradient through the whole network to reduce the computation cost. Our method reduces memory usage by 46% and 53% for MobileNetV2 and V3 IRBs, respectively. For MobileNetV3, we observe a 36% reduction in floating-point operations (FLOPs) when fine-tuning 5 blocks, while only incurring a 0.6% accuracy reduction on CIFAR10. Extensive experiments on multiple datasets demonstrate that our method is Pareto-optimal (best accuracy under given hardware constraints) compared to prior work in transfer learning for edge devices.


翻译:在设备边缘进行迁移学习是一项具有挑战性的任务,原因在于设备上的资源有限。现有的工作通过训练一部分参数或添加模型补丁来解决这个问题。 反向残差块(IRBs)是为推断而开发的,它们将卷积层分为深度卷积和点卷积,从而导致更多的堆叠层,例如卷积、归一化和激活层。虽然它们对于推断是有效的,但IRBs需要存储附加的激活映射,用于训练卷积层的权重和归一化层的尺度。 因此,它们的高存储成本妨碍了在资源有限的边缘设备上训练IRBs,并且使得它们在迁移学习的背景下不适用。 为了解决这个问题,我们提出了MobileTL,它是一种内存和计算资源高效的基于设备内部的迁移学习方法,适用于使用IRBs构建的模型。 MobileTL训练内部归一化层的偏移量,以避免存储反向传递的激活映射。此外,MobileTL将激活层的反向计算(例如,Hard-Swish和ReLU6)近似为有符号函数,从而使反向传递时只需存储二进制掩码而非激活映射。MobileTL只需微调靠近输出端的几个顶部块(close to output),而不是通过整个网络传递梯度来减少计算成本。我们的方法将MobileNetV2和V3 IRBs的内存使用量分别减少46%和53%。对于MobileNetV3,当微调5个块时,我们观察到浮点运算(FLOPs)减少了36%,同时在CIFAR10上只承担0.6%的精度降低。对多个数据集进行的广泛实验表明,与边缘设备迁移学习先前的工作相比,我们的方法是帕累托最优的(给定硬件约束下的最佳精度)。

0
下载
关闭预览

相关内容

迁移学习(Transfer Learning)是一种机器学习方法,是把一个领域(即源领域)的知识,迁移到另外一个领域(即目标领域),使得目标领域能够取得更好的学习效果。迁移学习(TL)是机器学习(ML)中的一个研究问题,着重于存储在解决一个问题时获得的知识并将其应用于另一个但相关的问题。例如,在学习识别汽车时获得的知识可以在尝试识别卡车时应用。尽管这两个领域之间的正式联系是有限的,但这一领域的研究与心理学文献关于学习转移的悠久历史有关。从实践的角度来看,为学习新任务而重用或转移先前学习的任务中的信息可能会显着提高强化学习代理的样本效率。

知识荟萃

精品入门和进阶教程、论文和代码整理等

更多

查看相关VIP内容、论文、资讯等
Graph Transformer近期进展
专知会员服务
60+阅读 · 2023年1月5日
【2022新书】高效深度学习,Efficient Deep Learning Book
专知会员服务
114+阅读 · 2022年4月21日
Google-EfficientNet v2来了!更快,更小,更强!
专知会员服务
18+阅读 · 2021年4月4日
专知会员服务
41+阅读 · 2021年1月18日
近期必读的六篇 ICML 2020【对比学习】相关论文
专知会员服务
56+阅读 · 2020年9月15日
[ICML-Google]先宽后窄:对深度薄网络的有效训练
专知会员服务
33+阅读 · 2020年7月5日
赛尔笔记 | 自然语言处理中的迁移学习(下)
AI科技评论
11+阅读 · 2019年10月21日
BERT/Transformer/迁移学习NLP资源大列表
专知
19+阅读 · 2019年6月9日
Transferring Knowledge across Learning Processes
CreateAMind
25+阅读 · 2019年5月18日
Deep Compression/Acceleration:模型压缩加速论文汇总
极市平台
13+阅读 · 2019年5月15日
基于PyTorch/TorchText的自然语言处理库
专知
27+阅读 · 2019年4月22日
Unsupervised Learning via Meta-Learning
CreateAMind
41+阅读 · 2019年1月3日
基于Keras进行迁移学习
论智
12+阅读 · 2018年5月6日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
2+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
8+阅读 · 2009年12月31日
Arxiv
21+阅读 · 2021年12月31日
Arxiv
13+阅读 · 2021年7月20日
Arxiv
19+阅读 · 2018年3月28日
VIP会员
相关基金
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
2+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2013年12月31日
国家自然科学基金
0+阅读 · 2012年12月31日
国家自然科学基金
0+阅读 · 2011年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
0+阅读 · 2009年12月31日
国家自然科学基金
8+阅读 · 2009年12月31日
Top
微信扫码咨询专知VIP会员