Utilizing electroencephalogram (EEG) data alongside machine learning for the classification of different levels of mental stress
Loading...
Date
Authors
Mikogaziev, Murad
Advisor
Referee
Mark
C
Journal Title
Journal ISSN
Volume Title
Publisher
Vysoké učení technické v Brně. Fakulta informačních technologií
ORCID
Abstract
Tato práce zkoumá využití EEG dat v kombinaci se strojovým učením pro klasifikaci různých úrovní mentálního stresu. Vzhledem k nárůstu poruch souvisejících se stresem je naléhavě potřeba neinvazivních a účinných nástrojů pro monitorování stresu. EEG, díky své přenosnosti a nízkým nákladům, představuje slibné řešení, pokud je doplněno technikami strojového učení. Studie využila soubor dat sestávající ze 70 EEG záznamů, každý se 64 kanály vzorkovanými frekvencí 512 Hz nebo 2048 Hz, anotované se čtyřmi úrovněmi stresu. Metodika zahrnovala předzpracování EEG dat prostřednictvím výběru kanálů (redukce na 14 klíčových kanálů), převzorkování na 128 Hz, odstranění artefaktů (pomocí zářezových a pásmových filtrů a nástroje AutoReject) a přepočítání referencí na společný průměr. Z EEG signálů byly extrahovány rysy z časové, frekvenční, asymetrické a konektivní domény a top 100 nejvýznamnějších rysů bylo vybráno pomocí ANOVA F-skóre. Bylo natrénováno a vyhodnoceno pět klasifikátorů (Random Forest, Extra Trees, k-nejbližších sousedů, Bagging a XGBoost) pomocí pětinásobné křížové validace. Rovněž byly implementovány ensemble metody (hard a soft voting), přičemž nejlepší výsledky dosáhl soft-votingový ensemble s přesností (accuracy) 0,8381, precizností (precision) 0,8557, recall 0,8219 a F1-skóre 0,8352. Klíčová zjištění poukazují na význam rysů jako amplituda peak-to-peak, rozptyl, Hjorthova pohyblivost a komplexita a koherence v beta a alfa pásmech pro klasifikaci stresu. Studie demonstruje potenciál EEG-založených modelů strojového učení pro přesné, neinvazivní monitorování mentálního stresu a otevírá cestu k budoucím pokrokům v technologii duševního zdraví.
This thesis explores the use of EEG data combined with machine learning to classify different levels of mental stress. With stress-related disorders on the rise, there is a pressing need for non-invasive and effective stress monitoring tools. EEG, due to its portability and cost-effectiveness, is a promising solution when paired with machine learning techniques. The study utilized a dataset of 70 EEG recordings, each with 64 channels sampled at 512 Hz or 2048 Hz, annotated with four stress levels. The methodology involved preprocessing the EEG data through channel selection (reducing to 14 key channels), resampling to 128 Hz, artifact removal (using notch and bandpass filters, and AutoReject), and re-referencing to a common average. Features were extracted from time, frequency, asymmetry, and connectivity domains, and the top 100 features were selected using the ANOVA F-score method. Five machine learning classifiers (Random Forest, Extra Trees, k-Nearest Neighbors, Bagging, and XGBoost) were trained and evaluated using 5-fold cross-validation. Ensemble methods (hard and soft voting) were also implemented. The soft voting ensemble achieved the highest performance with an accuracy of 0.8381, precision of 0.8557, recall of 0.8219, and F1-score of 0.8352. Key findings highlight the importance of features such as peak-to-peak amplitude, variance, Hjorth mobility and complexity, and coherence in beta and alpha bands for stress classification. The study demonstrates the potential of EEG-based machine learning models for accurate, non-invasive mental stress monitoring, with implications for future advancements in mental health technology.
This thesis explores the use of EEG data combined with machine learning to classify different levels of mental stress. With stress-related disorders on the rise, there is a pressing need for non-invasive and effective stress monitoring tools. EEG, due to its portability and cost-effectiveness, is a promising solution when paired with machine learning techniques. The study utilized a dataset of 70 EEG recordings, each with 64 channels sampled at 512 Hz or 2048 Hz, annotated with four stress levels. The methodology involved preprocessing the EEG data through channel selection (reducing to 14 key channels), resampling to 128 Hz, artifact removal (using notch and bandpass filters, and AutoReject), and re-referencing to a common average. Features were extracted from time, frequency, asymmetry, and connectivity domains, and the top 100 features were selected using the ANOVA F-score method. Five machine learning classifiers (Random Forest, Extra Trees, k-Nearest Neighbors, Bagging, and XGBoost) were trained and evaluated using 5-fold cross-validation. Ensemble methods (hard and soft voting) were also implemented. The soft voting ensemble achieved the highest performance with an accuracy of 0.8381, precision of 0.8557, recall of 0.8219, and F1-score of 0.8352. Key findings highlight the importance of features such as peak-to-peak amplitude, variance, Hjorth mobility and complexity, and coherence in beta and alpha bands for stress classification. The study demonstrates the potential of EEG-based machine learning models for accurate, non-invasive mental stress monitoring, with implications for future advancements in mental health technology.
Description
Keywords
Citation
MIKOGAZIEV, M. Utilizing electroencephalogram (EEG) data alongside machine learning for the classification of different levels of mental stress [online]. Brno: Vysoké učení technické v Brně. Fakulta informačních technologií. 2025.
Document type
Document version
Date of access to the full text
Language of document
en
Study field
Informační technologie
Comittee
doc. Ing. Tomáš Martínek, Ph.D. (předseda)
Ing. Vladimír Bartík, Ph.D. (člen)
Ing. Jiří Hynek, Ph.D. (člen)
doc. Mgr. Adam Rogalewicz, Ph.D. (člen)
doc. Ing. Michal Španěl, Ph.D. (člen)
Date of acceptance
2025-06-17
Defence
Student nejprve prezentoval výsledky, kterých dosáhl v rámci své práce. Komise se poté seznámila s hodnocením vedoucího a posudkem oponenta práce. Student následně odpověděl na otázky přítomných. Komise se na základě posudku oponenta, hodnocení vedoucího, přednesené prezentace a odpovědí studenta na položené otázky rozhodla práci hodnotit stupněm C.
Result of defence
práce byla úspěšně obhájena
