Tiny machine learning (TinyML) is a rapidly growing field aiming to democratize machine learning (ML) for resource-constrained microcontrollers (MCUs). Given the pervasiveness of these tiny devices, it is inherent to ask whether TinyML applications can benefit from aggregating their knowledge. Federated learning (FL) enables decentralized agents to jointly learn a global model without sharing sensitive local data. However, a common global model may not work for all devices due to the complexity of the actual deployment environment and the heterogeneity of the data available on each device. In addition, the deployment of TinyML hardware has significant computational and communication constraints, which traditional ML fails to address. Considering these challenges, we propose TinyReptile, a simple but efficient algorithm inspired by meta-learning and online learning, to collaboratively learn a solid initialization for a neural network (NN) across tiny devices that can be quickly adapted to a new device with respect to its data. We demonstrate TinyReptile on Raspberry Pi 4 and Cortex-M4 MCU with only 256-KB RAM. The evaluations on various TinyML use cases confirm a resource reduction and training time saving by at least two factors compared with baseline algorithms with comparable performance.
翻译:摘要:小型机器学习(TinyML)是一个快速发展的领域,旨在将机器学习(ML)用于资源受限的微控制器(MCUs)。鉴于这些微型设备的普及性,自然而然地要问TinyML应用程序是否可以从聚合其知识中受益。联邦学习(FL)使分散的代理能够在不共享敏感本地数据的情况下共同学习全局模型。然而,由于实际部署环境的复杂性和每个设备可用数据的异构性,一个共同的全局模型可能不适用于所有设备。此外,TinyML硬件的部署具有重要的计算和通信约束,传统的ML无法解决这些问题。考虑到这些挑战,我们提出了TinyReptile,这是一种受元学习和在线学习启发的简单但高效的算法,用于跨小型设备协作学习神经网络(NN)的坚实初始化,可快速适应新设备与其数据有关。我们在带有256-KB RAM的Raspberry Pi 4和Cortex-M4 MCU上展示了TinyReptile。对各种TinyML用例进行的评估证实,与具有可比性能的基准算法相比,TinyReptile可以减少资源使用和训练时间至少两个因素。