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

MCUNetV2:面向微型深度学习的内存高效的基于补丁的推理

MCUNetV2: Memory-Efficient Patch-based Inference for Tiny Deep Learning

MIT(麻省理工学院);MIT-IBM Watson AI Lab(麻省理工学院-IBM沃森人工智能实验室)

Ji Lin, Wei-Ming Chen, Han Cai, Chuang Gan, Song Han

AI总结:

针对MCU内存瓶颈,本文提出逐补丁推理、网络再分配与神经架构搜索协同优化的MCUNetV2,显著降低峰值内存并提升分类与检测性能。

摘要:

由于内存大小有限,在微控制器(MCU)上进行微型深度学习具有挑战性。我们发现,内存瓶颈源于卷积神经网络(CNN)设计中不均衡的内存分布:前几个块的内存使用量比网络其余部分高一个数量级。为缓解这一问题,我们提出了一种通用的逐补丁推理调度,它仅处理特征图的一个小空间区域,并显著降低峰值内存。然而,朴素实现会带来重叠补丁和计算开销。我们进一步提出网络再分配,将感受野和FLOPs转移到后期阶段,以减少计算开销。手动再分配感受野十分困难。我们利用神经架构搜索将该过程自动化,以联合优化神经架构和推理调度,从而产生了MCUNetV2。基于补丁的推理有效地将现有网络的峰值内存使用量降低了4-8倍。通过与神经网络协同设计,MCUNetV2在MCU上创下了ImageNet准确率纪录(71.8%),并在仅32kB SRAM下于视觉唤醒词数据集上取得超过90%的准确率。MCUNetV2还打通了微型设备上的目标检测,在Pascal VOC上相比最先进结果取得了高出16.9%的mAP。我们的研究在很大程度上解决了tinyML中的内存瓶颈,并为图像分类之外的多种视觉应用铺平了道路。

英文摘要:

Tiny deep learning on microcontroller units (MCUs) is challenging due to the limited memory size. We find that the memory bottleneck is due to the imbalanced memory distribution in convolutional neural network (CNN) designs: the first several blocks have an order of magnitude larger memory usage than the rest of the network. To alleviate this issue, we propose a generic patch-by-patch inference scheduling, which operates only on a small spatial region of the feature map and significantly cuts down the peak memory. However, naive implementation brings overlapping patches and computation overhead. We further propose network redistribution to shift the receptive field and FLOPs to the later stage and reduce the computation overhead. Manually redistributing the receptive field is difficult. We automate the process with neural architecture search to jointly optimize the neural architecture and inference scheduling, leading to MCUNetV2. Patch-based inference effectively reduces the peak memory usage of existing networks by 4-8x. Co-designed with neural networks, MCUNetV2 sets a record ImageNet accuracy on MCU (71.8%), and achieves >90% accuracy on the visual wake words dataset under only 32kB SRAM. MCUNetV2 also unblocks object detection on tiny devices, achieving 16.9% higher mAP on Pascal VOC compared to the state-of-the-art result. Our study largely addressed the memory bottleneck in tinyML and paved the way for various vision applications beyond image classification.

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

↑