BioTrain: Sub-MB, Sub-50mW On-Device Fine-Tuning for Edge-AI on Biosignals
Authors: Run Wang, Victor J. B. Jung, Philip Wiese, Sebastian Frey, Giusy Spacone, Francesco Conti, Alessio Burrello, Luca Benini
Organizations: Integrated Systems Laboratory (IIS), ETH Zurich, Switzerland · Department of Electrical, Electronic and Information Engineering (DEI), University of Bologna, Italy · Department of Control and Computer Engineering (DAUIN), Politecnico di Torino, Italy
Biosignals exhibit substantial cross-subject and cross-session variability, inducing severe domain shifts that degrade post-deployment performance for small, edge-oriented AI models. On-device adaptation is therefore essential to both preserve user privacy and ensure system reliability. However, existing sub-100 mW MCU-based wearable platforms can only support shallow or sparse adaptation schemes due to the prohibitive memory footprint and computational cost of full backpropagation (BP). In this paper, we propose BioTrain, a framework enabling full-network fine-tuning of state-of-the-art biosignal models under milliwatt-scale power and sub-megabyte memory constraints. We validate BioTrain using both offline and on-device benchmarks on EEG and EOG datasets, covering Day-1 new-subject calibration and longitudinal adaptation to signal drift. Experimental results show that full-network fine-tuning achieves accuracy improvements of up to 35% over non-adapted baselines and outperforms last-layer updates by approximately 7% during new-subject calibration. On the GAP9 MCU platform, BioTrain enables efficient on-device training throughput of 17 samples/s for EEG and 85 samples/s for EOG models within a power envelope below 50 mW. In addition, BioTrain's efficient memory allocator and network topology optimization enable the use of a large batch size, reducing peak memory usage. For fully on-chip BP on GAP9, BioTrain reduces the memory footprint by 8.1x, from 5.4 MB to 0.67 MB, compared to conventional full-network fine-tuning using batch normalization with batch size 8.
Figures & tables
TABLE I: Representative on-device training frameworks.
Fig. 1: Overview of the BioTrain framework for on-device model adaptation. (a) The framework interfaces with PyTorch to support common neural network architectures. (b) The training engine executes forward and backward passes, exposing intermediate activations and gradients through an autograd mechanism to enable parameter updates. (c) The deployment stack lowers training operators through a frontend–midend–backend compiler pipeline, generating optimized kernels and bare-metal C code with explicit memory management. (d) In the target on-device learning scenario, a cloud-pretrained model is first initialized and calibrated for a new user, followed by continual on-device adaptation over time.
Fig. 2: Overview of the deployment stack for end-to-end on- MCU training. In light blue, our novel inserted blocks.
Fig. 3: Overview of the evaluation protocols. The pipeline includes: (1) Offline Server Pre-training using a LOSO scheme ( N−1 subjects); (2) Scenario A : Day-1 Calibration. (3) Scenario B : Longitudinal Adaptation.
Property
EEG Dataset
EOG Dataset
Subjects
5
5
Sessions per subject
4
2
Signal channels
8
3 ( L / R / C )
Classification task
2 ( Tongue vs. Rest )
11
Trial duration
3.8s ( T=1900 )
2.0s ( T=1000 )
Backbone model
MI-BMINet
EpiDeNet
TABLE II: Summary of the EEG and EOG datasets and models.
Figure 6
Dataset
Strategy
Acc (Subj/Sess)
Params (Train)
FLOPs
L2 Peak Memory (MB)
Latency (ms)
Power (mW)
Energy (mJ)
Throughput (GFLOPs/s)
EEG [ 4 ]
LP
74.8 / 76.2
0.07 k
139.2 M
0.19
360.0
45.2
16.08
0.38
Full-FT
80.0 / 78.7
7.9 k
416.8 M
5.36 †
—
—
—
—
Edge-FT
86.4 / 83.9
7.9 k
416.8 M
0.67
469.6
43.8
20.16
0.89
EOG [ 7 ]
LP
83.3 / 86.5
0.2 k
7.2 M
0.11
34.4
50.4
1.76
0.21
Full-FT
88.7 / 89.1
4.1 k
20.8 M
2.24 †
—
—
—
—
Edge-FT
87.7 / 87.2
4.1 k
20.8 M
0.28
93.6
48.2
4.48
0.22
TABLE IV: System-level evaluation of on-device training on GAP9 (FP32, 1.5 MB L2), comparing LP, Full-FT, and Edge-FT.
On-device model adaptation is essential to enable lifelong personalization on resource-constrained hardware, but compute, power, and memory limitations of such devices make end-to-end backpropagation impractical for modern deep neural networks. This work proposes a heterogeneous adaptation pipeline that repurposes a commercial edge AI inference accelerator, Hailo-8L, for frozen-backbone feature extraction during on-device training. The computational graph is partitioned so that the pre-trained backbone is quantized to INT8 and run on the accelerator, while only a lightweight FP32 classification head is fine-tuned on the host CPU, enabling frequent, energy-efficient in-field updates with most weights remaining fixed. Across multiple architectures and datasets, this pipeline achieves up to 15.4x faster wall-clock training time compared to a Raspberry Pi 5 CPU baseline, offers competitive throughput in favorable settings, and consistently reduces energy per sample. Post-training quantization restoration is shown to be crucial for preserving the quality of accelerator-generated features and mitigating accuracy loss in quantization-sensitive architectures. Overall, the results demonstrate a practical approach to efficient on-device adaptation using inference-oriented edge accelerators. The implementation is available at https://github.com/MatPiech/accelerator-training.
Mateusz Piechocki, Alessandro Capotondi, Marek Kraft
Poznan University of Technology, Institute of Robotics and Machine Intelligence, Poznan, Poland · University of Modena and Reggio Emilia, The High-Performance Real-Time Laboratory, Modena, Italy
On-device tuning of deep neural networks enables long-term adaptation at the edge while preserving data privacy. However, the high computational and memory demands of backpropagation pose significant challenges for ultra-low-power, memory-constrained extreme-edge devices. These challenges are further amplified for attention-based models due to their architectural complexity and computational scale. We present TrainDeeploy, a framework that unifies efficient inference and on-device training on heterogeneous ultra-low-power System-on-Chips (SoCs). TrainDeeploy provides the first complete on-device training pipeline for extreme-edge SoCs supporting both Convolutional Neural Networks (CNNs) and Transformer models, together with multiple training strategies such as selective layer-wise fine-tuning and Low-Rank Adaptation (LoRA). On a RISC-V-based heterogeneous SoC, we demonstrate the first end-to-end on-device fine-tuning of a Compact Convolutional Transformer (CCT), achieving up to 11 trained images per second. We show that LoRA reduces dynamic memory usage by 23%, decreases the number of trainable parameters and gradients by 15x, and reduces memory transfer volume by 1.6x compared to full backpropagation. TrainDeeploy achieves up to 4.6 FLOP/cycle on CCT (0.28M parameters, 71-126M FLOPs) and up to 13.4 FLOP/cycle on Deep-AE (0.27M parameters, 0.8M FLOPs), while expanding the scope of prior frameworks to support both CNN and Transformer models with parameter-efficient tuning on extreme-edge platforms.
Run Wang, Victor J. B. Jung, Philip Wiese +3
Integrated Systems Laboratory (IIS), ETH Zurich, Switzerland · Department of Electrical, Electronic and Information Engineering (DEI), University of Bologna, Italy · Department of Control and Computer Engineering (DAUIN), Politecnico di Torino, Italy
EEG foundation models pretrained via self-supervised learning promise transferable representations, but their generalization remains limited, especially across diverse clinical datasets. Full fine-tuning is impractical for resource-constrained clinical settings due to high computational requirements. In this work, we investigate whether parameter-efficient self-supervised adaptation, updating only 9% of parameters suffices to align representations to target tasks. We evaluate our method on two state-of-the-art models with different pretraining objectives: BIOT (contrastive) and CBraMod (masked reconstruction), and evaluate on three clinical EEG datasets for abnormality detection (TUAB), event classification (TUEV), and seizure detection (CHB-MIT) under both in-distribution and out-of-distribution conditions. SSL adaptation yields consistent gains over linear probing, up to 20x AUCPR. Under a fixed compute budget, peak performance requires only 20--50% of available unlabeled data. Critically, when total window count is fixed, performance remains invariant to patient count, suggesting that performance is dependent on overall temporal window diversity only. Our findings demonstrate that parameter-efficient adaptation enables effective deployment of EEG Foundation models (EEG-FM) with minimal computational overhead and data collection burden. Code available at: https://github.com/c3n-group/efficient-eeg-adapt
Meghal Dani, Stefanie Liebe
University of Tübingen, Germany · Hertie Institute for AI in Brain Health (Hertie AI), Tübingen, Germany · Dept. of Neurology and Epileptology, University Clinic Tübingen, Germany +1