Article Search
닫기

## Original Article

Split Viewer

International Journal of Fuzzy Logic and Intelligent Systems 2020; 20(2): 138-144

Published online June 25, 2020

https://doi.org/10.5391/IJFIS.2020.20.2.138

© The Korean Institute of Intelligent Systems

## Prediction Method of Periodic Limb Movements Based on Deep Learning Using ECG Signal

Urtnasan Erdenebayar1 , Jong-Uk Park1 , SooYong Lee2 , Eun-Yeon Joo3 , and Kyoung-Joung Lee1

1Department of Biomedical Engineering, College of Health Science, Yonsei University, Wonju, Korea
2Department of Liberal Education, Yonsei University, Wonju, Korea
3Department of Neurology, Samsung Medical Center, Sungkyunkwan University School of Medicine, Seoul, Korea

Correspondence to :
Kyoung-Joung Lee (lkj5809@yonsei.ac.kr)

Received: December 31, 2019; Revised: April 8, 2020; Accepted: May 15, 2020

This is an Open Access article distributed under the terms of the Creative Commons Attribution Non-Commercial License (http://creativecommons.org/licenses/by-nc/3.0/) which permits unrestricted noncommercial use, distribution, and reproduction in any medium, provided the original work is properly cited.

In this study, we demonstrated a novel method to predict a patient with periodic limb movements (PLMs) based on a deep learning model using an electrocardiogram (ECG) signal. A convolutional neural network (CNN) model was used to distinguish between the PLM and control subjects through morphological analysis of an ECG signal. The constructed CNN model consisted of convolutional, pooling, and fully connected layers. For this study, polysomnography (PSG) data that were measured from 14 subjects at the Samsung Medical Center were used. The subjects were divided into control group (4 males, 3 females) and PLM group (4 males, 3 females). To train and evaluate the CNN model, the ECG dataset was collected during the PSG study, and it was normalized and segmented at a duration of 10 s. The training and test sets consisted of 30,324 and 7,582 segments, respectively. The CNN model presented a prediction performance with an F1-score of 100.0% for the test sets. We obtained robust results that demonstrated the possibility of the automatic screening of PLM patients using the CNN model with an ECG signal.

Keywords: Periodic limb movement disorder, Convolutional neural network, Deep learning, Electrocardiogram

### 1. Introduction

Periodic limb movements (PLMs) are regarded as repetitive and episodic movements caused by specific muscle atonia during sleep. PLM episodes are repeated four or more times consecutively, with the duration of one episode that ranges from 0.5 to 5 seconds. The interval between two episodes is from 5 to 90 seconds. Frequent occurrence of PLMs (e.g., the average number of PLMs per hour) may be lead to arousal or sleep fragmentation, which can affect personal health and wellbeing [1]. Furthermore, PLMs are known to be related to several other disorders, including cardiovascular disease, hypertension, depression, narcolepsy, rapid eye movement disorder, and Parkinson’s disease [26]. Thus, early and easy diagnosis of PLMs is clinically crucial to prevent other associated diseases.

Nocturnal polysomnography (PSG) is the standard diagnostic test for sleep disorders, including PLMs and restless legs syndrome. In PSG, various equipment are attached to the body of the patient to measure various bio-signals, such as electroencephalogram (EEG), electrooculogram (EOG), electrocardiogram (ECG), and electromyogram (EMG). In addition, the PSG test can accurately and objectively diagnose all sleep-related disorders based on the bio-signals recorded during sleep [7]. However, PSG tests are expensive and inconvenient and require sleep experts. Most importantly, sleep experts require annotating the PLMs manually, which is a remarkable task, and the annotation results may differ according to the experience and proficiency of the sleep expert.

A few studies have proposed alternative methods for scoring PLMs based on accelerometry, EMG, and film sensors [811]. King et al. [9] proposed a novel approach to measure PLMs using an Actiwatch (Cambridge Neuro-Technology Ltd., Cambridge, UK). They demonstrated the potential of the continuous measurement of PLMs for monitoring and treatment. Prill and Fahrenberg [10] investigated a method based on multiple accelerometry for PLM assessment. However, these studies required additional devices or multiple sensors and their performance was not sufficient. Finally, Wetter et al. [11] developed an automatic scoring method based on an EMG signal during PSG. They achieved an accuracy of 92.5% for PLM episodes. Portable PSG is essentially used for home sleep monitoring to diagnose sleep disorders [12]. Portable or home PSG only requires four channel physiological signals: ECG, respiratory, SpO2, and photoplethysmography. Therefore, a novel algorithm based on a single-lead ECG signal is required for PLM monitoring in laboratory and home.

In this study, using a single-lead ECG signal, we proposed a novel approach for the automatic prediction of PLM patients by deep learning. A convolutional neural network (CNN) was used as the deep learning model. For the performance evaluation, a clinical dataset obtained from control and patient groups with PLMs was used.

### 2.1 Study Population

For this study, 14 subjects were enrolled, and all of them underwent nocturnal PSG recordings. All the PSG recordings were obtained by using a polygraphic amplifier (N7000; Embla, Iceland) over an average period of 7.5 hours at the Samsung Medical Center, Seoul, Korea (Table 1). The PSG data comprise numerous biosignals, including EEG, EOG, EMG, ECG, chest and abdominal respiration, airflow, oxygen saturation, and snoring. The signals were recorded at a sampling rate of 200 Hz and segmented into units of 30 seconds. Sleep disorders, including PLMs, were labeled according to the criteria of the American Association of Sleep Medicine [13]. All the PSG recordings were approved by the Institutional Review Board of Samsung Medical Center (IRB No. 2012-01-063).

### 2.2 Dataset

The ECG signals of the subjects in each group were collected using a single-lead transducer and then resampled at 100 Hz; they consisted of 1,000 samples per episode. The study population was randomly divided into training (10 subjects, 30,324 events) and test (4 subjects, 7,582 events) sets to train and evaluate the constructed deep learning model (Table 2).

### 3.1 Deep Learning Model

Deep learning can be useful for modeling the characteristics of human sleep patterns, particularly sleep-related movements during sleep, such as PLMs. A CNN is a most common deep learning model known to present outstanding performance in computer vision and pattern recognition [14]. In this study, an optimal CNN model for PLM prediction was designed and optimized via trial and error. Thus, the proposed deep learning model comprised a three-layer CNN model.

3.1.1 Conveolutional layer

The proposed CNN model used one-dimensional (1D) convolutional and pooling layers. In this layer, feature maps were extracted from the ECG signal. The 1D convolutional filters were applied in different sizes and numbers to each layer. A 1D convolution layer can be represented by the convolution operation expressed in Eq. (1).

xkl=bkl+i=1Nwkl-1*yil-1,

where xkl denotes the k-th feature map in layer l, bkl is the bias of the k-th feature map in layer l, and yil-1 represents the i-th feature map in layer l − 1. Further, wkl-1 is the k-th convolutional kernel from all the features in layer l − 1 to the kth feature map in layer l, N denotes the total number of features in layer l − 1, and (*) indicates a vector convolution [15].

3.1.2 Pooling layer

A pooling layer performs logical functions to increase the discriminative power of the features and reduces the amount of data. Pooling or sub-sampling has several methods. The proposed CNN model performed max-pooling in the pooling layers for the intermediate feature map reduction. The pooling layers have no training parameters. However, there were several hyperparameters, including the window size f, stride s, max, and average pool. The window size of the pooling specifies the f × 1 window for 1D max-pooling.

3.1.3 Activation function

A rectified linear unit (ReLU) was used as the activation function of each layer of the proposed deep learning model; it can be represented as follows:

f(x)=max(0,wx+b),

where x represents the feature map, w is the weight, and b denotes the bias [16]. ReLU demonstrates a robust training performance and produces consistent gradients, which aid gradient-based learning.

Dropout and batch normalization were conducted to reduce overfitting in the proposed CNN model for the automatic prediction of PLMs using a single-lead ECG. To reduce overfitting in the network model, dropout randomly eliminates nodes in a network, thereby preventing complex adaptations on the training data [17]. In this study, batch normalization was conducted on the input ECG signal before training the proposed CNN model, as expressed in Eq. (3).

xb=α·(xi-μσ2+ɛ)+β,

where ɛ is the small random noise, μ is the mini-batch mean, σ is the mini-batch variance, α denotes the scale parameter, and β represents the shift parameter. Both α and β are trainable and updated in an epoch-wise manner [18].

### 3.2 Architecture and Implementation

The proposed deep learning model was a three-layer structure comprising three convolutional and pooling layers in the CNN (Figure 1). The first convolutional layer had 20 filters with the size of 50 × 1 array, and the output feature map has the size of 951 × 20 array. The second convolutional layer had 16 filters with the size of 30 × 1 array, and the output feature map was 446 × 16 array. The last convolutional layer had eight filters with the size of 10 × 1, and the output of this layer has the size of 214×8 array. Subsequently, we used a fully connected layer with the softmax activation as a final discriminator for the PLM prediction from a single-lead ECG signal. ReLU activation and max pooling (2 × 1) were used for all the layers. For real-time implementation, we attempted to design a simple and easy model of the CNN.

For this study, the PSG data were processed using MATLAB (ver. R2018b) software. The proposed deep learning model was implemented using the Keras library [19] with TensorFlow [20] backend. A workstation with Intel CPU (i9-9900X @3.5 GHz) and Nvidia GPU (GeForce RTX 2080 Ti) was used to train and evaluate the deep learning model.

### 3.3 Evaluation Measures

For the assessment of the proposed deep learning model for PLM prediction using a single-lead ECG signal, the following evaluation measures were used: precision, recall, and F1-score. The F1-score evaluates the prediction accuracy of a class according to the class equality. To obtain the F1-score, two evaluation measures, precision and recall, are combined. These are defined as follows:

precision=TPTP+FP,andrecall=TPTP+FN,

where TP, FP, and FN denote true positive, false positive, and false negative, respectively. They are determined for each periodic leg movement event.

The F1-score, which is known to be appropriate for an unbalanced dataset, is computed based on the sample proportion of the precision and recall as follows:

F1=2×presicion×recallprecision×recall.

Table 3 shows the results of the proposed deep learning model for the automatic prediction of PLM patients using a single-lead ECG signal. The performance of the proposed deep learning model was represented by the recall, precision, F1-score, and accuracy for the training and the test set.

Figure 2 shows the graphs of the learning accuracy and the losses of the proposed deep learning model for PLM prediction. We achieved stable and robust performances for the training and the test set.

This study proposed a novel approach for the automatic prediction of PLM patients by deep learning using a single-lead ECG signal. A CNN model was used for the deep learning, and its performance was evaluated using a clinical dataset measured from a control group and patients with PLMs. We achieved a high performance with an accuracy of 99.8% on the training set and 99.2% on the test set.

PLMs are considered prevalent in old people above 60 years; however, no prediction method is available for PLM patients yet. This study is an alternative study in which a CNN is applied to an intelligent system for PLM prediction using a single-lead ECG signal. The proposed approach has some advances, such as a strong performance, simultaneous usability in laboratory and home sleep monitoring, and easy implementation. Owing to motion artifacts in ECG signals, the proposed approach can precisely discriminate between normal and abnormal ECGs for the automatic prediction of PLMs based on deep learning. An ECG signal is an essential and important clinical information source for not only nocturnal PGS study at a sleep laboratory but also for portable PSG for home sleep monitoring. The proposed approach for the automatic prediction of PLM suggested a simple CNN architecture that can be easily implemented with real-world data.

However, this study has several limitations, including the small amount of data and the high computational power. For this study, we used the ECG signals of only 14 subjects. In a further study, a comparatively larger study population should be used to overcome this limitation. To calculate high-dimensional data abstraction, a CNN model requires a relatively high computational power than conventional machine learning methods. Therefore, in this study, we constructed and optimized a CNN model with a simple and small structure.

In summary, we proposed a novel method for the automatic prediction of PLM patients by a deep learning model using an ECG signal. The deep CNN model was constructed and evaluated by the dataset of the control and PLM patients for this study. We obtained very satisfactory performances on the training and test sets. In addition, we proposed an alternative method to predict PLM patients. Our results demonstrated the possibility of using the deep learning model with an ECG signal for PLM prediction. In addition, it showed that a single-lead ECG signal can be used as a discriminative and alternative signal for PLM patients. The proposed approach can be used as a sufficient and helpful prediction tool for sleep-related movements, including PLMs. In further studies, comparatively more diverse patients and larger datasets are required for insightful results.

### Acknowledgments

This research was financially supported by the Ministry of Trade, Industry and Energy (MOTIE) and the Korea Institute for Advancement of Technology (KIAT) through the National Innovation Cluster R&D Program (No. P0006697; Development of a Cardiopulmonary Monitoring System Using Wearable Device). This research was a result of a study on the “HPC Support” Project, supported by the ‘Ministry of Science and ICT’ and NIPA.

### Conflict of Interest

Fig. 1.

Architecture of the proposed deep learning model for PLM prediction.

Fig. 2.

(a) Accuracy and (b) loss functions of the proposed deep learning model for PLM prediction.

Table. 1.

Table 1. Characteristics of the study population.

MeasuresControl (n = 7)PLM (n = 7)p-value
Sex
Male44
Female33

Age (yr)49.4±5.949.6±5.9NS

Body mass index (kg/m2)22.2±1.822.4±1.9NS

PLM index (/hr)0.0±0.022.9±6.5<0.001

Total sleep time (hr)6.9±0.46.3±0.6NS

Sleep efficiency (%)88.1±4.988.7±5.6NS

Values are presented as mean±standard deviation..

NS, not significant..

Table. 2.

Table 2. Information of the training and test sets.

DatasetTraining setTest setTotal
Number of subjects10414
Control group527
PLM group527

Age (yr)48.5±6.752.0±3.849.5±6.1

Body mass index (kg/m2)22.5±2.121.9±1.622.3±2.0

PLM index (/hr)10.6±12.213.6±16.011.5±12.8

Total sleep time (hr)6.5±0.76.8±0.56.6±0.6

Total episodes30,3247,58237,906

Values are presented as mean±standard deviation..

Table. 3.

Table 3. Performance of the proposed deep learning model for PLM prediction.

DatasetsEpisodesPrecisionRecallF1-scoreAccuracy
Training setCTR1.001.001.000.998
PLM1.001.001.00

Test setCTR1.001.001.000.992
PLM1.001.001.00

1. H. Scofield, T. Roth, C. Drake, "Periodic limb movements during sleep: population prevalence, clinical correlates, and racial differences," Sleep, vol. 31, no. 9, pp. 1221-1227, 2008. https://doi.org/10.5665/sleep/31.9.1221
2. D. B. Boivin, J. Montplaisir, G. Poirier, "The effects of L-dopa on periodic leg movements and sleep organization in narcolepsy," Clinical Neuropharmacology, vol. 12, no. 4, pp. 339-345, 1989. https://doi.org/10.1097/00002826-198908000-00012
3. O. Lapierre, J. Montplaisir, "Polysomnographic features of REM sleep behavior disorder: development of a scoring method," Neurology, vol. 42, no. 7, pp. 1371-1374, 1992. https://doi.org/10.1212/WNL.42.7.1371
4. S. Ancoli-israel, D. F. Kripke, W. Mason, O. J. Kaplan, "Sleep apnea and periodic movements in an aging sample," Journal of Gerontology, vol. 40, no. 4, pp. 419-425, 1985. https://doi.org/10.1093/geronj/40.4.419
5. T. C. Wetter, V. Collado-Seidel, T. Pollmacher, A. Yassouridis, C. Trenkwalder, "Sleep and periodic leg movement patterns in drug-free patients with Parkinson’s disease and multiple system atrophy," Sleep, vol. 23, no. 3, pp. 361-367, 2000. https://doi.org/10.1093/sleep/23.3.1c
6. B. B.. Koo, S. Sillau, D. A.2nd Dean, P. L. Lutsey, S. Redline, "Periodic limb movements during sleep and prevalent hypertension in the multi-ethnic study of atherosclerosis," Hypertension, vol. 65, no. 1, pp. 70-77, 2015. https://doi.org/10.1161/HYPERTENSIONAHA.114.04193
7. N. J. Douglas, S. Thomas, M. A. Jan, "Clinical value of polysomnography," The Lancet, vol. 339, no. 8789, pp. 347-350, 1992. https://doi.org/10.1016/0140-6736(92)91660-Z
8. E. Rauhala, J. Virkkala, S. L. Himanen, "Periodic limb movement screening as an additional feature of Emfit sensor in sleep-disordered breathing studies," Journal of Neuroscience Methods, vol. 178, no. 1, pp. 157-161, 2009. https://doi.org/10.1016/j.jneumeth.2008.11.019
9. M. A. King, M. O. Jaffre, E. Morrish, J. M. Shneerson, I. E. Smith, "The validation of a new actigraphy system for the measurement of periodic leg movements in sleep," Sleep Medicine, vol. 6, no. 6, pp. 507-513, 2005. https://doi.org/10.1016/j.sleep.2004.12.010
10. T. Prill, J. Fahrenberg, "Simultaneous assessment of posture and limb movements (e.g., periodic leg movements) with calibrated multiple accelerometry," Physiological Measurement, vol. 27, no. 10, pp. N47-N53, 2006. https://doi.org/10.1088/0967-3334/27/10/N02
11. T. C. Wetter, G. Dirlich, J. Streit, C. Trenkwalder, A. Schuld, T. Pollmacher, "An automatic method for scoring leg movements in polygraphic sleep recordings and its validity in comparison to visual scoring," Sleep, vol. 27, no. 2, pp. 324-328, 2004. https://doi.org/10.1093/sleep/27.2.324
12. R. Ferber, R. Millman, M. Coppola, J. Fleetham, C. F. Murray, C. Iber, et al., "Portable recording in the assessment of obstructive sleep apnea. ASDA standards of practice," Sleep, vol. 17, no. 4, pp. 378-392, 1994. https://doi.org/10.1093/sleep/17.4.378
13. American Academy of Sleep Medicine, "The AASM Manual for the Scoring of Sleep and Associated Events: Rules, Terminology and Technical Specifications (version 2.0), 2012," Available https://aasm.org/clinical-resources/scoring-manual/
14. Y. LeCun, Y. Bengio, G. Hinton, "Deep learning," Nature, vol. 521, no. 7553, pp. 436-444, 2015. https://doi.org/10.1038/nature14539
15. S. Kiranyaz, T. Ince, M. Gabbouj, "Real-time patient-specific ECG classification by 1-D convolutional neural networks," IEEE Transactions on Biomedical Engineering, vol. 63, no. 3, pp. 664-675, 2016. https://doi.org/10.1109/TBME.2015.2468589
16. V. Nair, G. E. Hinton, "Rectified linear units improve restricted Boltzmann machines," in Proceedings of the 27th International Conference on Machine Learning, Haifa, Israel, , pp. 807-814.
17. N. Srivastava, G. Hinton, A. Krizhevsky, I. Sutskever, R. Salakhutdinov, "Dropout: a simple way to prevent neural networks from overfitting," Journal of Machine Learning Research, vol. 15, no. 56, pp. 1929-1958, 2014.
18. S. Ioffe, C. Szegedy, "Batch normalization: accelerating deep network training by reducing internal covariate shift," in Proceedings of the 32nd International Conference on International Conference on Machine Learning, Lille, France, , pp. 448-456.
19. Keras: the Python deep learning API, Available https://keras.io/
20. M. Abadi, P. Barham, J. Chen, Z. Chen, A. Davis, J. Dean, et al., "TensorFlow: a system for large-scale machine learning," in Proceedings of the 12th USENIX Symposium on Operating Systems Design and Implementation (OSDI), Savannah, GA, , pp. 265-283.

Urtnasan Erdenebayar received his B.S. in Computer science from Huree University, Ulaanbaatar, Mongolia, in 2007 and M.S. in Electronic engineering from Inha University, Incheon, Korea, in 2010, respectively. He also received his Ph.D. in Biomedical Engineering from Yonsei University, Seoul, Korea, in 2018. Since 2018, he is a Postdoc researcher at the Department of Biomedical Engineering, Yonsei University. His research interests are artificial intelligence, deep learning, machine learning, digital healthcare, digital medicine, data science, and biosignal processing.

E-mail: edenbyra@yonsei.ac.kr

Jong-Uk Park received his B.S. in Biomedical engineering from Konyang University, Daejeon, Korea, in 2008 and M.S. in Biomedical Engineering from Yonsei University, Wonju, Korea, in 2012, respectively. He is currently Ph.D. candidate at Department of Biomedical Engineering, Yonsei University. He has been working on research related to sleep signal analysis, algorithm development and signal processing.

E-mail: pjwwhite01@naver.com

SooYong Lee received his Ph.D. in Mathematics from the Kyunghee University, Seoul, Korea, in 1992. He also received his Ph.D in Computer Science from the Yonsei University, Seoul, Korea, in 2004. He is a faculty member at Yonsei University, Wonju, Korea. Since 2004, he has been working on research related to artificial intelligence, machine learning and data mining.

E-mail: 0691@yonsei.ac.kr

Eun-Yeon Joo received the M.D., M.S., and Ph.D. degrees in Neurology from the Ewha Womans University, Seoul, Korea, in 1997, 2001, and 2005, respectively. She served as an intern and resident in neurology at Ewha Womans University Hospital, Neurology Department, Seoul Korea from 1997 to 2001. She was a visiting scholar with the Northwestern University Hospital, Sleep Center, Chicago, IL, USA. Since 2007, she has been a faculty member of Neurology, Samsung Medical Center, the Sungkyunkwan University, School of Medicine, Seoul, Korea.

E-mail: eunyeon.joo@gmail.com

Kyoung-Joung Lee Lee received the B.S., M.S., and Ph.D. degrees in electric engineering from the Yonsei University, Seoul, Korea, in 1981, 1983, and 1988, respectively. He was an international fellow at Case Western Reserve University, USA, in 1993. Since 1989, He has been a faculty member with the Biomedical Engineering Department, Yonsei University, Wonju, Korea. He is the coauthor of five books, more than 130 articles, and more than 30 inventions. His research interests include medical instrument, biosignals processing, and bio-system modelling.

E-mail: lkj5809@yonsei.ac.kr

### Article

#### Original Article

International Journal of Fuzzy Logic and Intelligent Systems 2020; 20(2): 138-144

Published online June 25, 2020 https://doi.org/10.5391/IJFIS.2020.20.2.138

## Prediction Method of Periodic Limb Movements Based on Deep Learning Using ECG Signal

Urtnasan Erdenebayar1 , Jong-Uk Park1 , SooYong Lee2 , Eun-Yeon Joo3 , and Kyoung-Joung Lee1

1Department of Biomedical Engineering, College of Health Science, Yonsei University, Wonju, Korea
2Department of Liberal Education, Yonsei University, Wonju, Korea
3Department of Neurology, Samsung Medical Center, Sungkyunkwan University School of Medicine, Seoul, Korea

Correspondence to:Kyoung-Joung Lee (lkj5809@yonsei.ac.kr)

Received: December 31, 2019; Revised: April 8, 2020; Accepted: May 15, 2020

This is an Open Access article distributed under the terms of the Creative Commons Attribution Non-Commercial License (http://creativecommons.org/licenses/by-nc/3.0/) which permits unrestricted noncommercial use, distribution, and reproduction in any medium, provided the original work is properly cited.

### Abstract

In this study, we demonstrated a novel method to predict a patient with periodic limb movements (PLMs) based on a deep learning model using an electrocardiogram (ECG) signal. A convolutional neural network (CNN) model was used to distinguish between the PLM and control subjects through morphological analysis of an ECG signal. The constructed CNN model consisted of convolutional, pooling, and fully connected layers. For this study, polysomnography (PSG) data that were measured from 14 subjects at the Samsung Medical Center were used. The subjects were divided into control group (4 males, 3 females) and PLM group (4 males, 3 females). To train and evaluate the CNN model, the ECG dataset was collected during the PSG study, and it was normalized and segmented at a duration of 10 s. The training and test sets consisted of 30,324 and 7,582 segments, respectively. The CNN model presented a prediction performance with an F1-score of 100.0% for the test sets. We obtained robust results that demonstrated the possibility of the automatic screening of PLM patients using the CNN model with an ECG signal.

Keywords: Periodic limb movement disorder, Convolutional neural network, Deep learning, Electrocardiogram

### 1. Introduction

Periodic limb movements (PLMs) are regarded as repetitive and episodic movements caused by specific muscle atonia during sleep. PLM episodes are repeated four or more times consecutively, with the duration of one episode that ranges from 0.5 to 5 seconds. The interval between two episodes is from 5 to 90 seconds. Frequent occurrence of PLMs (e.g., the average number of PLMs per hour) may be lead to arousal or sleep fragmentation, which can affect personal health and wellbeing [1]. Furthermore, PLMs are known to be related to several other disorders, including cardiovascular disease, hypertension, depression, narcolepsy, rapid eye movement disorder, and Parkinson’s disease [26]. Thus, early and easy diagnosis of PLMs is clinically crucial to prevent other associated diseases.

Nocturnal polysomnography (PSG) is the standard diagnostic test for sleep disorders, including PLMs and restless legs syndrome. In PSG, various equipment are attached to the body of the patient to measure various bio-signals, such as electroencephalogram (EEG), electrooculogram (EOG), electrocardiogram (ECG), and electromyogram (EMG). In addition, the PSG test can accurately and objectively diagnose all sleep-related disorders based on the bio-signals recorded during sleep [7]. However, PSG tests are expensive and inconvenient and require sleep experts. Most importantly, sleep experts require annotating the PLMs manually, which is a remarkable task, and the annotation results may differ according to the experience and proficiency of the sleep expert.

A few studies have proposed alternative methods for scoring PLMs based on accelerometry, EMG, and film sensors [811]. King et al. [9] proposed a novel approach to measure PLMs using an Actiwatch (Cambridge Neuro-Technology Ltd., Cambridge, UK). They demonstrated the potential of the continuous measurement of PLMs for monitoring and treatment. Prill and Fahrenberg [10] investigated a method based on multiple accelerometry for PLM assessment. However, these studies required additional devices or multiple sensors and their performance was not sufficient. Finally, Wetter et al. [11] developed an automatic scoring method based on an EMG signal during PSG. They achieved an accuracy of 92.5% for PLM episodes. Portable PSG is essentially used for home sleep monitoring to diagnose sleep disorders [12]. Portable or home PSG only requires four channel physiological signals: ECG, respiratory, SpO2, and photoplethysmography. Therefore, a novel algorithm based on a single-lead ECG signal is required for PLM monitoring in laboratory and home.

In this study, using a single-lead ECG signal, we proposed a novel approach for the automatic prediction of PLM patients by deep learning. A convolutional neural network (CNN) was used as the deep learning model. For the performance evaluation, a clinical dataset obtained from control and patient groups with PLMs was used.

### 2.1 Study Population

For this study, 14 subjects were enrolled, and all of them underwent nocturnal PSG recordings. All the PSG recordings were obtained by using a polygraphic amplifier (N7000; Embla, Iceland) over an average period of 7.5 hours at the Samsung Medical Center, Seoul, Korea (Table 1). The PSG data comprise numerous biosignals, including EEG, EOG, EMG, ECG, chest and abdominal respiration, airflow, oxygen saturation, and snoring. The signals were recorded at a sampling rate of 200 Hz and segmented into units of 30 seconds. Sleep disorders, including PLMs, were labeled according to the criteria of the American Association of Sleep Medicine [13]. All the PSG recordings were approved by the Institutional Review Board of Samsung Medical Center (IRB No. 2012-01-063).

### 2.2 Dataset

The ECG signals of the subjects in each group were collected using a single-lead transducer and then resampled at 100 Hz; they consisted of 1,000 samples per episode. The study population was randomly divided into training (10 subjects, 30,324 events) and test (4 subjects, 7,582 events) sets to train and evaluate the constructed deep learning model (Table 2).

### 3.1 Deep Learning Model

Deep learning can be useful for modeling the characteristics of human sleep patterns, particularly sleep-related movements during sleep, such as PLMs. A CNN is a most common deep learning model known to present outstanding performance in computer vision and pattern recognition [14]. In this study, an optimal CNN model for PLM prediction was designed and optimized via trial and error. Thus, the proposed deep learning model comprised a three-layer CNN model.

3.1.1 Conveolutional layer

The proposed CNN model used one-dimensional (1D) convolutional and pooling layers. In this layer, feature maps were extracted from the ECG signal. The 1D convolutional filters were applied in different sizes and numbers to each layer. A 1D convolution layer can be represented by the convolution operation expressed in Eq. (1).

$xkl=bkl+∑i=1Nwkl-1*yil-1,$

where $xkl$ denotes the k-th feature map in layer l, $bkl$ is the bias of the k-th feature map in layer l, and $yil-1$ represents the i-th feature map in layer l − 1. Further, $wkl-1$ is the k-th convolutional kernel from all the features in layer l − 1 to the kth feature map in layer l, N denotes the total number of features in layer l − 1, and (*) indicates a vector convolution [15].

3.1.2 Pooling layer

A pooling layer performs logical functions to increase the discriminative power of the features and reduces the amount of data. Pooling or sub-sampling has several methods. The proposed CNN model performed max-pooling in the pooling layers for the intermediate feature map reduction. The pooling layers have no training parameters. However, there were several hyperparameters, including the window size f, stride s, max, and average pool. The window size of the pooling specifies the f × 1 window for 1D max-pooling.

3.1.3 Activation function

A rectified linear unit (ReLU) was used as the activation function of each layer of the proposed deep learning model; it can be represented as follows:

$f(x)=max(0,wx+b),$

where x represents the feature map, w is the weight, and b denotes the bias [16]. ReLU demonstrates a robust training performance and produces consistent gradients, which aid gradient-based learning.

Dropout and batch normalization were conducted to reduce overfitting in the proposed CNN model for the automatic prediction of PLMs using a single-lead ECG. To reduce overfitting in the network model, dropout randomly eliminates nodes in a network, thereby preventing complex adaptations on the training data [17]. In this study, batch normalization was conducted on the input ECG signal before training the proposed CNN model, as expressed in Eq. (3).

$xb=α·(xi-μσ2+ɛ)+β,$

where ɛ is the small random noise, μ is the mini-batch mean, σ is the mini-batch variance, α denotes the scale parameter, and β represents the shift parameter. Both α and β are trainable and updated in an epoch-wise manner [18].

### 3.2 Architecture and Implementation

The proposed deep learning model was a three-layer structure comprising three convolutional and pooling layers in the CNN (Figure 1). The first convolutional layer had 20 filters with the size of 50 × 1 array, and the output feature map has the size of 951 × 20 array. The second convolutional layer had 16 filters with the size of 30 × 1 array, and the output feature map was 446 × 16 array. The last convolutional layer had eight filters with the size of 10 × 1, and the output of this layer has the size of 214×8 array. Subsequently, we used a fully connected layer with the softmax activation as a final discriminator for the PLM prediction from a single-lead ECG signal. ReLU activation and max pooling (2 × 1) were used for all the layers. For real-time implementation, we attempted to design a simple and easy model of the CNN.

For this study, the PSG data were processed using MATLAB (ver. R2018b) software. The proposed deep learning model was implemented using the Keras library [19] with TensorFlow [20] backend. A workstation with Intel CPU (i9-9900X @3.5 GHz) and Nvidia GPU (GeForce RTX 2080 Ti) was used to train and evaluate the deep learning model.

### 3.3 Evaluation Measures

For the assessment of the proposed deep learning model for PLM prediction using a single-lead ECG signal, the following evaluation measures were used: precision, recall, and F1-score. The F1-score evaluates the prediction accuracy of a class according to the class equality. To obtain the F1-score, two evaluation measures, precision and recall, are combined. These are defined as follows:

$precision=TPTP+FP, and$$recall=TPTP+FN,$

where TP, FP, and FN denote true positive, false positive, and false negative, respectively. They are determined for each periodic leg movement event.

The F1-score, which is known to be appropriate for an unbalanced dataset, is computed based on the sample proportion of the precision and recall as follows:

$F1=2×presicion×recallprecision×recall.$

### 4. Result

Table 3 shows the results of the proposed deep learning model for the automatic prediction of PLM patients using a single-lead ECG signal. The performance of the proposed deep learning model was represented by the recall, precision, F1-score, and accuracy for the training and the test set.

Figure 2 shows the graphs of the learning accuracy and the losses of the proposed deep learning model for PLM prediction. We achieved stable and robust performances for the training and the test set.

### 5. Discussion

This study proposed a novel approach for the automatic prediction of PLM patients by deep learning using a single-lead ECG signal. A CNN model was used for the deep learning, and its performance was evaluated using a clinical dataset measured from a control group and patients with PLMs. We achieved a high performance with an accuracy of 99.8% on the training set and 99.2% on the test set.

PLMs are considered prevalent in old people above 60 years; however, no prediction method is available for PLM patients yet. This study is an alternative study in which a CNN is applied to an intelligent system for PLM prediction using a single-lead ECG signal. The proposed approach has some advances, such as a strong performance, simultaneous usability in laboratory and home sleep monitoring, and easy implementation. Owing to motion artifacts in ECG signals, the proposed approach can precisely discriminate between normal and abnormal ECGs for the automatic prediction of PLMs based on deep learning. An ECG signal is an essential and important clinical information source for not only nocturnal PGS study at a sleep laboratory but also for portable PSG for home sleep monitoring. The proposed approach for the automatic prediction of PLM suggested a simple CNN architecture that can be easily implemented with real-world data.

However, this study has several limitations, including the small amount of data and the high computational power. For this study, we used the ECG signals of only 14 subjects. In a further study, a comparatively larger study population should be used to overcome this limitation. To calculate high-dimensional data abstraction, a CNN model requires a relatively high computational power than conventional machine learning methods. Therefore, in this study, we constructed and optimized a CNN model with a simple and small structure.

In summary, we proposed a novel method for the automatic prediction of PLM patients by a deep learning model using an ECG signal. The deep CNN model was constructed and evaluated by the dataset of the control and PLM patients for this study. We obtained very satisfactory performances on the training and test sets. In addition, we proposed an alternative method to predict PLM patients. Our results demonstrated the possibility of using the deep learning model with an ECG signal for PLM prediction. In addition, it showed that a single-lead ECG signal can be used as a discriminative and alternative signal for PLM patients. The proposed approach can be used as a sufficient and helpful prediction tool for sleep-related movements, including PLMs. In further studies, comparatively more diverse patients and larger datasets are required for insightful results.

### Fig 1.

Figure 1.

Architecture of the proposed deep learning model for PLM prediction.

The International Journal of Fuzzy Logic and Intelligent Systems 2020; 20: 138-144https://doi.org/10.5391/IJFIS.2020.20.2.138

### Fig 2.

Figure 2.

(a) Accuracy and (b) loss functions of the proposed deep learning model for PLM prediction.

The International Journal of Fuzzy Logic and Intelligent Systems 2020; 20: 138-144https://doi.org/10.5391/IJFIS.2020.20.2.138

Characteristics of the study population.

MeasuresControl (n = 7)PLM (n = 7)p-value
Sex
Male44
Female33

Age (yr)49.4±5.949.6±5.9NS

Body mass index (kg/m2)22.2±1.822.4±1.9NS

PLM index (/hr)0.0±0.022.9±6.5<0.001

Total sleep time (hr)6.9±0.46.3±0.6NS

Sleep efficiency (%)88.1±4.988.7±5.6NS

Values are presented as mean±standard deviation..

NS, not significant..

Information of the training and test sets.

DatasetTraining setTest setTotal
Number of subjects10414
Control group527
PLM group527

Age (yr)48.5±6.752.0±3.849.5±6.1

Body mass index (kg/m2)22.5±2.121.9±1.622.3±2.0

PLM index (/hr)10.6±12.213.6±16.011.5±12.8

Total sleep time (hr)6.5±0.76.8±0.56.6±0.6

Total episodes30,3247,58237,906

Values are presented as mean±standard deviation..

Performance of the proposed deep learning model for PLM prediction.

DatasetsEpisodesPrecisionRecallF1-scoreAccuracy
Training setCTR1.001.001.000.998
PLM1.001.001.00

Test setCTR1.001.001.000.992
PLM1.001.001.00

### References

1. H. Scofield, T. Roth, C. Drake, "Periodic limb movements during sleep: population prevalence, clinical correlates, and racial differences," Sleep, vol. 31, no. 9, pp. 1221-1227, 2008. https://doi.org/10.5665/sleep/31.9.1221
2. D. B. Boivin, J. Montplaisir, G. Poirier, "The effects of L-dopa on periodic leg movements and sleep organization in narcolepsy," Clinical Neuropharmacology, vol. 12, no. 4, pp. 339-345, 1989. https://doi.org/10.1097/00002826-198908000-00012
3. O. Lapierre, J. Montplaisir, "Polysomnographic features of REM sleep behavior disorder: development of a scoring method," Neurology, vol. 42, no. 7, pp. 1371-1374, 1992. https://doi.org/10.1212/WNL.42.7.1371
4. S. Ancoli-israel, D. F. Kripke, W. Mason, O. J. Kaplan, "Sleep apnea and periodic movements in an aging sample," Journal of Gerontology, vol. 40, no. 4, pp. 419-425, 1985. https://doi.org/10.1093/geronj/40.4.419
5. T. C. Wetter, V. Collado-Seidel, T. Pollmacher, A. Yassouridis, C. Trenkwalder, "Sleep and periodic leg movement patterns in drug-free patients with Parkinson’s disease and multiple system atrophy," Sleep, vol. 23, no. 3, pp. 361-367, 2000. https://doi.org/10.1093/sleep/23.3.1c
6. B. B.. Koo, S. Sillau, D. A.2nd Dean, P. L. Lutsey, S. Redline, "Periodic limb movements during sleep and prevalent hypertension in the multi-ethnic study of atherosclerosis," Hypertension, vol. 65, no. 1, pp. 70-77, 2015. https://doi.org/10.1161/HYPERTENSIONAHA.114.04193
7. N. J. Douglas, S. Thomas, M. A. Jan, "Clinical value of polysomnography," The Lancet, vol. 339, no. 8789, pp. 347-350, 1992. https://doi.org/10.1016/0140-6736(92)91660-Z
8. E. Rauhala, J. Virkkala, S. L. Himanen, "Periodic limb movement screening as an additional feature of Emfit sensor in sleep-disordered breathing studies," Journal of Neuroscience Methods, vol. 178, no. 1, pp. 157-161, 2009. https://doi.org/10.1016/j.jneumeth.2008.11.019
9. M. A. King, M. O. Jaffre, E. Morrish, J. M. Shneerson, I. E. Smith, "The validation of a new actigraphy system for the measurement of periodic leg movements in sleep," Sleep Medicine, vol. 6, no. 6, pp. 507-513, 2005. https://doi.org/10.1016/j.sleep.2004.12.010
10. T. Prill, J. Fahrenberg, "Simultaneous assessment of posture and limb movements (e.g., periodic leg movements) with calibrated multiple accelerometry," Physiological Measurement, vol. 27, no. 10, pp. N47-N53, 2006. https://doi.org/10.1088/0967-3334/27/10/N02
11. T. C. Wetter, G. Dirlich, J. Streit, C. Trenkwalder, A. Schuld, T. Pollmacher, "An automatic method for scoring leg movements in polygraphic sleep recordings and its validity in comparison to visual scoring," Sleep, vol. 27, no. 2, pp. 324-328, 2004. https://doi.org/10.1093/sleep/27.2.324
12. R. Ferber, R. Millman, M. Coppola, J. Fleetham, C. F. Murray, C. Iber, et al., "Portable recording in the assessment of obstructive sleep apnea. ASDA standards of practice," Sleep, vol. 17, no. 4, pp. 378-392, 1994. https://doi.org/10.1093/sleep/17.4.378
13. American Academy of Sleep Medicine, "The AASM Manual for the Scoring of Sleep and Associated Events: Rules, Terminology and Technical Specifications (version 2.0), 2012," Available https://aasm.org/clinical-resources/scoring-manual/
14. Y. LeCun, Y. Bengio, G. Hinton, "Deep learning," Nature, vol. 521, no. 7553, pp. 436-444, 2015. https://doi.org/10.1038/nature14539
15. S. Kiranyaz, T. Ince, M. Gabbouj, "Real-time patient-specific ECG classification by 1-D convolutional neural networks," IEEE Transactions on Biomedical Engineering, vol. 63, no. 3, pp. 664-675, 2016. https://doi.org/10.1109/TBME.2015.2468589
16. V. Nair, G. E. Hinton, "Rectified linear units improve restricted Boltzmann machines," in Proceedings of the 27th International Conference on Machine Learning, Haifa, Israel, , pp. 807-814.
17. N. Srivastava, G. Hinton, A. Krizhevsky, I. Sutskever, R. Salakhutdinov, "Dropout: a simple way to prevent neural networks from overfitting," Journal of Machine Learning Research, vol. 15, no. 56, pp. 1929-1958, 2014.
18. S. Ioffe, C. Szegedy, "Batch normalization: accelerating deep network training by reducing internal covariate shift," in Proceedings of the 32nd International Conference on International Conference on Machine Learning, Lille, France, , pp. 448-456.
19. Keras: the Python deep learning API, Available https://keras.io/
20. M. Abadi, P. Barham, J. Chen, Z. Chen, A. Davis, J. Dean, et al., "TensorFlow: a system for large-scale machine learning," in Proceedings of the 12th USENIX Symposium on Operating Systems Design and Implementation (OSDI), Savannah, GA, , pp. 265-283.