Wearable systems for the long-term monitoring of cardiovascular diseases are becoming widespread and valuable assets in diagnosis and therapy. A promising approach for real-time analysis of the electrocardiographic (ECG) signal and the detection of heart conditions, such as arrhythmia, is represented by the transformer machine learning model. Transformers are powerful models for the classification of time series, although efficient implementation in the wearable domain raises significant design challenges, to combine adequate accuracy and a suitable complexity. In this work, we present a tiny transformer model for the analysis of the ECG signal, requiring only 6k parameters and reaching 98.97% accuracy in the recognition of the 5 most common arrhythmia classes from the MIT-BIH Arrhythmia database, assessed considering 8-bit integer inference as required for efficient execution on low-power microcontroller-based devices. We explored an augmentation-based training approach for improving the robustness against electrode motion artifacts noise, resulting in a worst-case post-deployment performance assessment of 98.36% accuracy. Suitability for wearable monitoring solutions is finally demonstrated through efficient deployment on the parallel ultra-low-power GAP9 processor, where inference execution requires 4.28ms and 0.09mJ.
翻译:用于心血管疾病长期监测的可穿戴系统正成为诊断和治疗中广泛且宝贵的工具。针对心电信号实时分析及心律失常等心脏疾病检测,Transformer机器学习模型提供了一种有前景的方法。Transformer作为时间序列分类的强大模型,在可穿戴领域的有效实现面临重大设计挑战,需兼顾足够精度与合理复杂度。本文提出一种微型Transformer模型用于心电信号分析,仅需6k参数即可在MIT-BIH心律失常数据库中对5种最常见心律失常类别实现98.97%的识别准确率(基于8位整数推理评估,即低功耗微控制器设备高效执行所要求的精度)。我们探索了基于数据增强的训练方法以提升对电极运动伪影噪声的鲁棒性,部署后最差性能评估准确率达98.36%。通过在高能效并行GAP9处理器上的高效部署,最终验证了其适用于可穿戴监测方案,推理执行仅需4.28毫秒和0.09毫焦耳。