Search for a command to run...
Early stress detection and measurement is a crucial strategy because it is important to take action immediately to prevent stress from increasing and leading to potential health issues. The system relies on heart rate variability (HRV), which is collected from ECG. The system presents the Convolutional Neural Network (CNN) as a Machine Learning (ML) model for stress level classification using features selected by lasso regression. CNN directly receives feeds from some cases that have known the imbalanced class issues. An important part of the system deals with the distribution of class imbalance in the training data. In training data, some classes of user stress levels have fewer samples than others. This aspect is addressed by the method of stratified k-fold cross-validation. Stratified k-fold cross-validation is a method of cross-validation in which each fold of the cross-validation keeps the same ratio as the original dataset, including the smaller classes in reasonable representation in both training and evaluation. The system provides fair representation of all classes while providing precise real-time stress detection. However, the need for a several-fold increase in the total amount of time resulting in a longer duration. The High Performance Computing (HPC) parallel execution is used by the system to address this problem. Because the HPC architecture distributes tasks among several processors, it maximizes resource usage and drastically cuts down on total elapsed time. From the experimental results, 5-fold stratified cross-validation on ML with HPC parallel processing based on the Message Passing Interface (MPI) achieves the highest accuracy (0.9999) and the lowest MAE (0.0001), showing superior reliability and efficiency for stress level classification.