Table of Contents
Fetching ...

Tin-Tin: Towards Tiny Learning on Tiny Devices with Integer-based Neural Network Training

Yi Hu, Jinhang Zuo, Eddie Zhang, Bob Iannucci, Carlee Joe-Wong

TL;DR

The paper tackles on-device lifelong learning on resource-constrained MCUs lacking floating-point units by introducing Tin-Tin, an integer-based training framework that replaces FP computations with 8-bit and 32-bit integer arithmetic. It presents a novel dynamic range strategy (integer rescaling and compound exponentiation) along with gradient-aligned weight updates to maintain stability and accuracy without FPUs. The approach is validated on real MCU hardware across motor bearing fault detection and spectrum sensing, and on MNIST, showing substantial energy savings (up to 82%) and memory reductions (up to 40%) with competitive accuracy. The work demonstrates the practicality of energy-efficient, continual learning on edge devices, enabling sustainable ML-enabled sensing and adaptive systems on tiny MCUs.

Abstract

Recent advancements in machine learning (ML) have enabled its deployment on resource-constrained edge devices, fostering innovative applications such as intelligent environmental sensing. However, these devices, particularly microcontrollers (MCUs), face substantial challenges due to limited memory, computing capabilities, and the absence of dedicated floating-point units (FPUs). These constraints hinder the deployment of complex ML models, especially those requiring lifelong learning capabilities. To address these challenges, we propose Tin-Tin, an integer-based on-device training framework designed specifically for low-power MCUs. Tin-Tin introduces novel integer rescaling techniques to efficiently manage dynamic ranges and facilitate efficient weight updates using integer data types. Unlike existing methods optimized for devices with FPUs, GPUs, or FPGAs, Tin-Tin addresses the unique demands of tiny MCUs, prioritizing energy efficiency and optimized memory utilization. We validate the effectiveness of Tin-Tin through end-to-end application examples on real-world tiny devices, demonstrating its potential to support energy-efficient and sustainable ML applications on edge platforms.

Tin-Tin: Towards Tiny Learning on Tiny Devices with Integer-based Neural Network Training

TL;DR

The paper tackles on-device lifelong learning on resource-constrained MCUs lacking floating-point units by introducing Tin-Tin, an integer-based training framework that replaces FP computations with 8-bit and 32-bit integer arithmetic. It presents a novel dynamic range strategy (integer rescaling and compound exponentiation) along with gradient-aligned weight updates to maintain stability and accuracy without FPUs. The approach is validated on real MCU hardware across motor bearing fault detection and spectrum sensing, and on MNIST, showing substantial energy savings (up to 82%) and memory reductions (up to 40%) with competitive accuracy. The work demonstrates the practicality of energy-efficient, continual learning on edge devices, enabling sustainable ML-enabled sensing and adaptive systems on tiny MCUs.

Abstract

Recent advancements in machine learning (ML) have enabled its deployment on resource-constrained edge devices, fostering innovative applications such as intelligent environmental sensing. However, these devices, particularly microcontrollers (MCUs), face substantial challenges due to limited memory, computing capabilities, and the absence of dedicated floating-point units (FPUs). These constraints hinder the deployment of complex ML models, especially those requiring lifelong learning capabilities. To address these challenges, we propose Tin-Tin, an integer-based on-device training framework designed specifically for low-power MCUs. Tin-Tin introduces novel integer rescaling techniques to efficiently manage dynamic ranges and facilitate efficient weight updates using integer data types. Unlike existing methods optimized for devices with FPUs, GPUs, or FPGAs, Tin-Tin addresses the unique demands of tiny MCUs, prioritizing energy efficiency and optimized memory utilization. We validate the effectiveness of Tin-Tin through end-to-end application examples on real-world tiny devices, demonstrating its potential to support energy-efficient and sustainable ML applications on edge platforms.

Paper Structure

This paper contains 32 sections, 2 equations, 9 figures, 5 tables, 3 algorithms.

Figures (9)

  • Figure 1: Data RAM of ULP MCUs and the memory requirements for various ML applications, including anomaly detection (munir2019deepantvitolo2021lowpowerhimeur2022detection) and signal classification ( subray2021spectrum). Solid lines: fp32; dashed lines: int8. For DeepAnT munir2019deepant, a kernel size of 3 and a pooling layer that preserves the output dimensions are assumed. Integer-based ML frameworks significantly reduce RAM requirements, expanding the range of devices on which ML applications can be deployed.
  • Figure 2: Dataflow illustrating the memory requirements and computation costs of the forward (black) and backward (red) passes for a linear layer with input dimension $n$, output dimension $m$ and batch size $b$.
  • Figure 3: The value distributions of weights and layer outputs change significantly across layers and epochs during the training of a four-layer model for MNIST, demonstrating the need for dynamic representation ranges.
  • Figure 4: Tin-Tin Training Framework
  • Figure 5: The forward pass (black) and backward pass (red) of a linear layer with ReLU activation are shown. 8-bit integer operands (shaded boxes) are used for all matrix multiplications.
  • ...and 4 more figures