Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals

Detalhes bibliográficos
Autor(a) principal: Braga, Rodrigo Duarte
Data de Publicação: 2022
Tipo de documento: Dissertação
Idioma: eng
Título da fonte: Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos)
Texto Completo: http://hdl.handle.net/10362/152018
Resumo: In this work, machine learning algorithms for automatic sleep cycles detection were developed. The features were selected based on the AASM manual, which is considered the gold standard for human technicians. These include features such as saturation of peripheral oxygen or others related to heart rate variation. As normally, the sleep phases naturally differ in frequency, to balance the classes within the dataset, we either oversampled the least common sleep stages or undersampled the most common, allowing for a less skewed performance favouring the most represented stages, while simultaneously improving worst-stage classification. For training the models we used MESA, a database containing 2056 full overnight unattended polysomnographies from a group of 2237 participants. With the goal of developing an algorithm that would only require a PPG device to be able to accurately predict sleep stages and quality, the main channels used from this dataset were SpO2 and PPG. Employing several popular Python libraries used for the development of machine learning and deep learning algorithms, we exhaustively explored the optimisation of the manifold parameters and hyperparameters conditioning both the training and architecture of these models in order for them to better fit our purposes. As a result of these strategies, we were able to develop a neural network model (Multilayer perceptron) with 80.50% accuracy, 0.7586 Cohen’s kappa, and 77.38% F1- score, for five sleep stages. The performance of our algorithm does not seem to be correlated with sleep quality or the number of transitional epochs in each recording, suggesting uniform performance regardless of the presence of sleep disorders. To test its performance in a different real-world scenario we compared the classifications attributed by a popular sleep stage classification android app, which collected information using a smartwatch, and our algorithm, using signals obtained from a device developed by PLUX. These algorithms displayed a strong level of agreement (90.96% agreement, 0.8663 Cohen’s kappa).
id RCAP_80bc53f920e0cd966cb0c3333264b357
oai_identifier_str oai:run.unl.pt:10362/152018
network_acronym_str RCAP
network_name_str Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos)
repository_id_str 7160
spelling Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignalsDeep LearningMachine LearningWearablePhotoplethysmographySleep StagesHeart Rate VariationDomínio/Área Científica::Engenharia e Tecnologia::Outras Engenharias e TecnologiasIn this work, machine learning algorithms for automatic sleep cycles detection were developed. The features were selected based on the AASM manual, which is considered the gold standard for human technicians. These include features such as saturation of peripheral oxygen or others related to heart rate variation. As normally, the sleep phases naturally differ in frequency, to balance the classes within the dataset, we either oversampled the least common sleep stages or undersampled the most common, allowing for a less skewed performance favouring the most represented stages, while simultaneously improving worst-stage classification. For training the models we used MESA, a database containing 2056 full overnight unattended polysomnographies from a group of 2237 participants. With the goal of developing an algorithm that would only require a PPG device to be able to accurately predict sleep stages and quality, the main channels used from this dataset were SpO2 and PPG. Employing several popular Python libraries used for the development of machine learning and deep learning algorithms, we exhaustively explored the optimisation of the manifold parameters and hyperparameters conditioning both the training and architecture of these models in order for them to better fit our purposes. As a result of these strategies, we were able to develop a neural network model (Multilayer perceptron) with 80.50% accuracy, 0.7586 Cohen’s kappa, and 77.38% F1- score, for five sleep stages. The performance of our algorithm does not seem to be correlated with sleep quality or the number of transitional epochs in each recording, suggesting uniform performance regardless of the presence of sleep disorders. To test its performance in a different real-world scenario we compared the classifications attributed by a popular sleep stage classification android app, which collected information using a smartwatch, and our algorithm, using signals obtained from a device developed by PLUX. These algorithms displayed a strong level of agreement (90.96% agreement, 0.8663 Cohen’s kappa).Neste trabalho, foram desenvolvidos algoritmos de aprendizagem de máquinas para a detecção automática de ciclos de sono. Os sinais específicos captados durante a extração de características foram selecionados com base no manual AASM, que é considerado o padrão-ouro para técnicos. Estas incluem características como a saturação do oxigénio periférico ou outras relacionadas com a variação do ritmo cardíaco. A fim de equilibrar a frequência das classes dentro do conjunto de dados, ora se fez a sobreamostragem das fases menos comuns do sono, ora se fez a subamostragem das mais comuns, permitindo um desempenho menos enviesado em favor das fases mais representadas e, simultaneamente, melhorando a classificação das fases com pior desempenho. Para o treino dos modelos criados, utilizámos MESA, uma base de dados contendo 2056 polissonografias completas, feitas durante a noite e sem vigilância, de um grupo de 2237 participantes. Do conjunto de dados escolhido, os principais canais utilizados foram SpO2 e PPG, com o objetivo de desenvolver um algoritmo que apenas exigiria um dispositivo PPG para poder prever com precisão as fases e a qualidade do sono. Utilizando várias bibliotecas populares de Python para o desenvolvimento de algoritmos de aprendizagem de máquinas e de aprendizagem profunda, explorámos exaustivamente a optimização dos múltiplos parâmetros e hiperparâmetros que tanto condicionam a formação como a arquitetura destes modelos, de modo a que se ajustem melhor aos nossos propósitos. Como resultado disto, fomos capazes de desenvolver um modelo de rede neural (Multilayer perceptron) com 80.50% de precisão, 0.7586 kappa de Cohen e F1-score de 77.38%, para cinco fases de sono. O desempenho do nosso algoritmo não parece estar correlacionado com a qualidade do sono ou o número de épocas de transição em cada gravação, sugerindo um desempenho uniforme independentemente da presença de distúrbios do sono. Para testar o seu desempenho num cenário de mundo real diferente, comparámos as classificações atribuídas por uma aplicação Android de classificação de fases do sono popular, através da recolha de informação por um smartwatch, e o nosso algoritmo, utilizando sinais obtidos a partir de um dispositivo desenvolvido pela PLUX. Estes algoritmos demonstraram um forte nível de concordância (90.96% de concordância, 0.8663 kappa de Cohen).Gamboa, HugoRUNBraga, Rodrigo Duarte2023-04-21T18:28:17Z2022-112022-11-01T00:00:00Zinfo:eu-repo/semantics/publishedVersioninfo:eu-repo/semantics/masterThesisapplication/pdfhttp://hdl.handle.net/10362/152018enginfo:eu-repo/semantics/openAccessreponame:Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos)instname:Agência para a Sociedade do Conhecimento (UMIC) - FCT - Sociedade da Informaçãoinstacron:RCAAP2024-03-11T05:34:26Zoai:run.unl.pt:10362/152018Portal AgregadorONGhttps://www.rcaap.pt/oai/openaireopendoar:71602024-03-20T03:54:47.036080Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos) - Agência para a Sociedade do Conhecimento (UMIC) - FCT - Sociedade da Informaçãofalse
dc.title.none.fl_str_mv Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
title Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
spellingShingle Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
Braga, Rodrigo Duarte
Deep Learning
Machine Learning
Wearable
Photoplethysmography
Sleep Stages
Heart Rate Variation
Domínio/Área Científica::Engenharia e Tecnologia::Outras Engenharias e Tecnologias
title_short Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
title_full Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
title_fullStr Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
title_full_unstemmed Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
title_sort Machine learning algorithms development for sleep cycles detection and general physical activity based on biosignals
author Braga, Rodrigo Duarte
author_facet Braga, Rodrigo Duarte
author_role author
dc.contributor.none.fl_str_mv Gamboa, Hugo
RUN
dc.contributor.author.fl_str_mv Braga, Rodrigo Duarte
dc.subject.por.fl_str_mv Deep Learning
Machine Learning
Wearable
Photoplethysmography
Sleep Stages
Heart Rate Variation
Domínio/Área Científica::Engenharia e Tecnologia::Outras Engenharias e Tecnologias
topic Deep Learning
Machine Learning
Wearable
Photoplethysmography
Sleep Stages
Heart Rate Variation
Domínio/Área Científica::Engenharia e Tecnologia::Outras Engenharias e Tecnologias
description In this work, machine learning algorithms for automatic sleep cycles detection were developed. The features were selected based on the AASM manual, which is considered the gold standard for human technicians. These include features such as saturation of peripheral oxygen or others related to heart rate variation. As normally, the sleep phases naturally differ in frequency, to balance the classes within the dataset, we either oversampled the least common sleep stages or undersampled the most common, allowing for a less skewed performance favouring the most represented stages, while simultaneously improving worst-stage classification. For training the models we used MESA, a database containing 2056 full overnight unattended polysomnographies from a group of 2237 participants. With the goal of developing an algorithm that would only require a PPG device to be able to accurately predict sleep stages and quality, the main channels used from this dataset were SpO2 and PPG. Employing several popular Python libraries used for the development of machine learning and deep learning algorithms, we exhaustively explored the optimisation of the manifold parameters and hyperparameters conditioning both the training and architecture of these models in order for them to better fit our purposes. As a result of these strategies, we were able to develop a neural network model (Multilayer perceptron) with 80.50% accuracy, 0.7586 Cohen’s kappa, and 77.38% F1- score, for five sleep stages. The performance of our algorithm does not seem to be correlated with sleep quality or the number of transitional epochs in each recording, suggesting uniform performance regardless of the presence of sleep disorders. To test its performance in a different real-world scenario we compared the classifications attributed by a popular sleep stage classification android app, which collected information using a smartwatch, and our algorithm, using signals obtained from a device developed by PLUX. These algorithms displayed a strong level of agreement (90.96% agreement, 0.8663 Cohen’s kappa).
publishDate 2022
dc.date.none.fl_str_mv 2022-11
2022-11-01T00:00:00Z
2023-04-21T18:28:17Z
dc.type.status.fl_str_mv info:eu-repo/semantics/publishedVersion
dc.type.driver.fl_str_mv info:eu-repo/semantics/masterThesis
format masterThesis
status_str publishedVersion
dc.identifier.uri.fl_str_mv http://hdl.handle.net/10362/152018
url http://hdl.handle.net/10362/152018
dc.language.iso.fl_str_mv eng
language eng
dc.rights.driver.fl_str_mv info:eu-repo/semantics/openAccess
eu_rights_str_mv openAccess
dc.format.none.fl_str_mv application/pdf
dc.source.none.fl_str_mv reponame:Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos)
instname:Agência para a Sociedade do Conhecimento (UMIC) - FCT - Sociedade da Informação
instacron:RCAAP
instname_str Agência para a Sociedade do Conhecimento (UMIC) - FCT - Sociedade da Informação
instacron_str RCAAP
institution RCAAP
reponame_str Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos)
collection Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos)
repository.name.fl_str_mv Repositório Científico de Acesso Aberto de Portugal (Repositórios Cientìficos) - Agência para a Sociedade do Conhecimento (UMIC) - FCT - Sociedade da Informação
repository.mail.fl_str_mv
_version_ 1799138136037523456