MCUFormer: Deploying Vision Tranformers on Microcontrollers with Limited Memory

Yinan Liang, Ziwei Wang, Xiuwei Xu, Yansong Tang, Jie Zhou +1 more
2/12/2026

No official code found. Best implementation: liangyn22/MCUFormer (76 stars, last commit 2023-10-31).

Abstract

Due to the high price and heavy energy consumption of GPUs, deploying deep models on IoT devices such as microcontrollers makes significant contributions for ecological AI. Conventional methods successfully enable convolutional neural network inference of high resolution images on microcontrollers, while the framework for vision transformers that achieve the state-of-the-art performance in many vision applications still remains unexplored. In this paper, we propose a hardware-algorithm co-optimizations method called MCUFormer to deploy vision transformers on microcontrollers with extremely limited memory, where we jointly design transformer architecture and construct the inference operator library to fit the memory resource constraint. More specifically, we generalize the one-shot network architecture search (NAS) to discover the optimal architecture with highest task performance given the memory budget from the microcontrollers, where we enlarge the existing search space of vision transformers by considering the low-rank decomposition dimensions and patch resolution for memory reduction. For the construction of the inference operator library of vision transformers, we schedule the memory buffer during inference through operator integration, patch embedding decomposition, and token overwriting, allowing the memory buffer to be fully utilized to adapt to the forward pass of the vision transformer. Experimental results demonstrate that our MCUFormer achieves 73.62\% top-1 accuracy on ImageNet for image classification with 320KB memory on STM32F746 microcontroller. Code is available at https://github.com/liangyn22/MCUFormer.

View on arXivView PDF

Code Implementations(1)

liangyn22/MCUFormerCommunity100%

[NeurIPS 2023] MCUFormer: Deploying Vision Transformers on Microcontrollers with Limited Memory

768Oct 24, 20232 years ago

Similar Papers

Cite this paper

@article{liang2026mcuformer,
  title  = {MCUFormer: Deploying Vision Tranformers on Microcontrollers with Limited Memory},
  author = {Yinan Liang and Ziwei Wang and Xiuwei Xu and Yansong Tang and Jie Zhou and Jiwen Lu},
  year   = {2026},
  eprint = {2310.16898},
  archivePrefix = {arXiv},
  url    = {https://arxiv.org/abs/2310.16898},
  journal = {NEURIPS 2023 2023}
}

Add a badge to your README

Shows whether official code is linked for this paper.

Code of Paper badge
[![Code of Paper](https://codeofpaper.com/badge/2310.16898.svg)](https://codeofpaper.com/paper/2310.16898)

Discussion