Detecting stress through 2D ECG images using pretrained models, transfer learning and model compression techniques
Stress is a major part of our everyday life, associated with most activities we perform on a daily basis and
if we are not careful about managing stress, it can have a detrimental impact on our health. Despite recent
advances in this domain, HRV analysis is still the most common method to detect stress, and although the
results that have been produced are admirable, feature extraction is complicated and time consuming. We
propose an algorithm to convert 1D (dimensional) ECG data from WESAD (wearable stress and affect detection
dataset) into 2D ECG images, which are representative of stress/not stress. It does not require time consuming
processes such as feature extraction and filtering. We utilize transfer learning to obtain competitive results.
We also demonstrate that model compression techniques can significantly reduce the computational size of the
algorithms, without sacrificing much of the performance, as evident from a classification accuracy of 90.62%
using the quantization technique. Results substantiate the effectiveness of our proposed method and empirically
demonstrates the potential of deep learning algorithms for edge computing and mobile applications, which
utilizes low performing hardware.