Amin Rostami, Koorosh Motaman, Bahram Tarvirdizadeh, Khalil Alipour, Mohammad Ghamari
{"title":"LSTM-based real-time stress detection using PPG signals on raspberry Pi","authors":"Amin Rostami, Koorosh Motaman, Bahram Tarvirdizadeh, Khalil Alipour, Mohammad Ghamari","doi":"10.1049/wss2.12083","DOIUrl":null,"url":null,"abstract":"<p>Stress, widely recognised for its profound adverse effects on both physical and mental health, necessitates the development of innovative real-time detection methods. In this context, the escalating prevalence of wearable embedded systems, integrated with artificial intelligence (AI) for the continuous monitoring of critical physiological indicators like heart rate and blood pressure, accentuates their growing relevance in the efficient detection of stress. This article presents an innovative methodology employing deep learning algorithms on the Raspberry Pi 3, a platform distinguished by its cost-effectiveness and limited resources. The authors have developed an advanced AI algorithm that achieves high accuracy in real-time stress detection using photoplethysmography (PPG) sensors while significantly reducing computational demands. The authors’ method utilises an artificial neural network with long short-term memory (LSTM) layers, proving highly effective in time-series data analysis. In this study, the authors implement key TensorFlow toolkit optimisation techniques including quantisation aware training (QAT), Pruning and prune-preserving quantisation aware training. These techniques are applied to refine the authors’ model, decreasing size and latency without sacrificing accuracy. The results highlight the LSTM-based model's proficiency in accurately detecting stress using raw PPG sensor data on the Raspberry Pi 3, a comparatively affordable platform. The model attains an accuracy of 89.32% and an F1 score of 89.55% on the diverse wearable stress and affect detection stress-level dataset. Additionally, the authors’ optimised model exhibits substantial reductions in both size and latency while maintaining high accuracy. This approach shows great potential for various applications, such as stress monitoring in healthcare, sports, and workplace settings. The use of the Raspberry Pi 3 makes the system portable, cost-effective, and energy-efficient, enhancing its potential impact and accessibility.</p>","PeriodicalId":51726,"journal":{"name":"IET Wireless Sensor Systems","volume":"14 6","pages":"333-347"},"PeriodicalIF":1.5000,"publicationDate":"2024-10-30","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"https://onlinelibrary.wiley.com/doi/epdf/10.1049/wss2.12083","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"IET Wireless Sensor Systems","FirstCategoryId":"1085","ListUrlMain":"https://onlinelibrary.wiley.com/doi/10.1049/wss2.12083","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"Q3","JCRName":"TELECOMMUNICATIONS","Score":null,"Total":0}
引用次数: 0
Abstract
Stress, widely recognised for its profound adverse effects on both physical and mental health, necessitates the development of innovative real-time detection methods. In this context, the escalating prevalence of wearable embedded systems, integrated with artificial intelligence (AI) for the continuous monitoring of critical physiological indicators like heart rate and blood pressure, accentuates their growing relevance in the efficient detection of stress. This article presents an innovative methodology employing deep learning algorithms on the Raspberry Pi 3, a platform distinguished by its cost-effectiveness and limited resources. The authors have developed an advanced AI algorithm that achieves high accuracy in real-time stress detection using photoplethysmography (PPG) sensors while significantly reducing computational demands. The authors’ method utilises an artificial neural network with long short-term memory (LSTM) layers, proving highly effective in time-series data analysis. In this study, the authors implement key TensorFlow toolkit optimisation techniques including quantisation aware training (QAT), Pruning and prune-preserving quantisation aware training. These techniques are applied to refine the authors’ model, decreasing size and latency without sacrificing accuracy. The results highlight the LSTM-based model's proficiency in accurately detecting stress using raw PPG sensor data on the Raspberry Pi 3, a comparatively affordable platform. The model attains an accuracy of 89.32% and an F1 score of 89.55% on the diverse wearable stress and affect detection stress-level dataset. Additionally, the authors’ optimised model exhibits substantial reductions in both size and latency while maintaining high accuracy. This approach shows great potential for various applications, such as stress monitoring in healthcare, sports, and workplace settings. The use of the Raspberry Pi 3 makes the system portable, cost-effective, and energy-efficient, enhancing its potential impact and accessibility.
人们普遍认为压力对身心健康具有深远的不利影响,因此有必要开发创新的实时检测方法。在这种背景下,可穿戴嵌入式系统的日益普及,与人工智能(AI)相结合,用于持续监测心率和血压等关键生理指标,突显了它们在有效检测压力方面日益增长的相关性。本文介绍了一种在树莓派3上采用深度学习算法的创新方法,树莓派3是一个以其成本效益和有限资源而闻名的平台。作者开发了一种先进的人工智能算法,该算法使用光体积脉搏波(PPG)传感器实现高精度的实时应力检测,同时显着降低了计算需求。作者的方法利用具有长短期记忆(LSTM)层的人工神经网络,证明在时间序列数据分析中非常有效。在本研究中,作者实现了关键的TensorFlow工具包优化技术,包括量化感知训练(QAT),修剪和修剪保持量化感知训练。这些技术被用于改进作者的模型,在不牺牲准确性的情况下减小尺寸和延迟。结果突出了基于lstm的模型在使用Raspberry Pi 3(一个相对便宜的平台)上的原始PPG传感器数据准确检测应力方面的熟练程度。该模型在不同的可穿戴应力和影响检测应力水平数据集上的准确率为89.32%,F1得分为89.55%。此外,作者的优化模型在保持高精度的同时,在大小和延迟方面都有显着减少。这种方法显示了各种应用的巨大潜力,例如医疗保健、体育和工作场所环境中的压力监测。树莓派3的使用使系统便携,经济高效,节能,增强其潜在的影响和可访问性。
期刊介绍:
IET Wireless Sensor Systems is aimed at the growing field of wireless sensor networks and distributed systems, which has been expanding rapidly in recent years and is evolving into a multi-billion dollar industry. The Journal has been launched to give a platform to researchers and academics in the field and is intended to cover the research, engineering, technological developments, innovative deployment of distributed sensor and actuator systems. Topics covered include, but are not limited to theoretical developments of: Innovative Architectures for Smart Sensors;Nano Sensors and Actuators Unstructured Networking; Cooperative and Clustering Distributed Sensors; Data Fusion for Distributed Sensors; Distributed Intelligence in Distributed Sensors; Energy Harvesting for and Lifetime of Smart Sensors and Actuators; Cross-Layer Design and Layer Optimisation in Distributed Sensors; Security, Trust and Dependability of Distributed Sensors. The Journal also covers; Innovative Services and Applications for: Monitoring: Health, Traffic, Weather and Toxins; Surveillance: Target Tracking and Localization; Observation: Global Resources and Geological Activities (Earth, Forest, Mines, Underwater); Industrial Applications of Distributed Sensors in Green and Agile Manufacturing; Sensor and RFID Applications of the Internet-of-Things ("IoT"); Smart Metering; Machine-to-Machine Communications.