A Medical Cloud-Based Platform for Respiration Rate Measurement and Hierarchical Classification of Breath Disorders

The measurement of human respiratory signals is crucial in cyberbiological systems. A disordered breathing pattern can be the first symptom of different physiological, mechanical, or psychological dysfunctions. Therefore, a real-time monitoring of the respiration patterns, as well as respiration rate is a critical need in medical applications. There are several methods for respiration rate measurement. However, despite their accuracy, these methods are expensive and could not be integrated in a body sensor network. In this work, we present a real-time cloud-based platform for both monitoring the respiration rate and breath pattern classification, remotely. The proposed system is designed particularly for patients with breathing problems (e.g., respiratory complications after surgery) or sleep disorders. Our system includes calibrated accelerometer sensor, Bluetooth Low Energy (BLE) and cloud-computing model. We also suggest a procedure to improve the accuracy of respiration rate for patients at rest positions. The overall error in the respiration rate calculation is obtained 0.53% considering SPR-BTA spirometer as the reference. Five types of respiration disorders, Bradapnea, Tachypnea, Cheyn-stokes, Kaussmal, and Biot's breathing are classified based on hierarchical Support Vector Machine (SVM) with seven different features. We have evaluated the performance of the proposed classification while it is individualized to every subject (case 1) as well as considering all subjects (case 2). Since the selection of kernel function is a key factor to decide SVM's performance, in this paper three different kernel functions are evaluated. The experiments are conducted with 11 subjects and the average accuracy of 94.52% for case 1 and the accuracy of 81.29% for case 2 are achieved based on Radial Basis Function (RBF). Finally, a performance evaluation has been done for normal and impaired subjects considering sensitivity, specificity and G-mean parameters of different kernel functions.


Introduction
Different studies show the importance of monitoring and analyzing the respiration signals in fields such as medicine and physiology [1][2][3][4]. Today about 7% of the population of developed countries suffer from Chronic Obstructive Pulmonary Disease (COPD), and it is a growing problem in developing countries. For example, an estimated of 3.7 million people live with COPD in UK, predicted to increase by one-third by 2030, costing £1.2 billion/y [ 3]. Moreover, professionals in breathing and sleep centers are demanded to assist people with shortness of breath, cardiovascular problems, such as hypertension, atherosclerosis, stroke, heart failure, cardiac arrhythmias, and sudden infant death syndrome (SISD). Therefore, a real-time monitoring of the respiration rhythm plays an important role in both diagnosis and treatment of different disorders. Remote monitoring also helps in prevention and early diagnosis of adult diseases, such as obesity, diabetic ketoacidosis (DKA), brain disorders as well as abnormal breathing of newborns at home. There are different conventional methods for respiration rate measurement including spirometer, body volume changes, nasal thermocouples, impedance plethysmography, inductance pneumography, strain gauge measurements of thoracic circumference, whole-body plethysmography [ 4], pneumatic respiration transducers, the fiber-optic sensor method [ 5], the Doppler radar [ 6], and electrocardiogram (ECG)-based derived respiration measurements [7][8][9]. However, in spite of their accuracy, these methods are expensive and inflexible, which may bring discomfort to the patients and physicians.
One recent development is the use of motion sensors to detect the small movements of the chest wall that occur during expansion and contraction of the lungs. In preliminary trials on hospital patients, it has been shown that with proper signal processing; this approach can produce results that match closely the measurements of nasal cannula pressure [ 10]. In [ 11] an accelerometer and pressure sensors are mounted on the body to obtain the respiratory rate. In this work the data was collected by the data acquisition card, and then the processing has been done in Labview software. A validation of respiratory signal derived from suprasternal, notch acceleration has been investigated by [ 12] for different body positions. In this paper, the spirometry and strain gauge respirometers (SGR) signals were filtered through an 8th order Butterworth bandpass filter with cut-off frequencies 0.1 Hz and 1 Hz. In order to remove noise from accelerometer data, they used an 8th order Butterworth low-pass filter with a cut-off frequency of 1 Hz. The precision of each sample was 8 bits while the sampling rate was 2000 Hz. The authors show that the respiration rate from the accelerometer has 1.55% error with respect to the spirometer. Their data storage and processing is performed on a computer with their custom build LabVIEW Virtual Instrument. In [ 13] the respiratory component is also extracted from the accelerometer mounted on the suprasternal notch of subjects. The vibrations are recorded with a transducer electronic data sheets (TEDS) lightweight piezoelectric accelerometer. The results demonstrate the feasibility of implementing an accelerometry-based portable device for respiration recording. The data acquisition is done with a compact system and data was stored in a laptop. Recently, [ 14] proposed a fusion method for accelerometer and gyroscope signals to calculate the respiration rate. They considered two types of exercises and the respiration rate errors are calculated as 4.6% and 9.54% for the treadmill and leg press, respectively.
In addition to obtaining an accurate respiration rate, several methods have been also suggested for identification of respiration disorders, such as sleep apnea. In fact, statistical features of different signals, such as nasal air flow, the thorax and abdomen effort signals, Electroencephalography (EEG), and ECG are mostly used in the detection. In [ 15] various feature sets are analyzed and a combination of classifiers are used based on the arterial oxygen saturation signal (SpO 2 ) and the ECG in order to evaluate sleep quality and apnea detection. The Bagging with REP Tree classifier achieved 79.75% and 85.89% of sensitivity and specificity respectively, while the overall accuracy obtained 84.40%. In [ 16] the authors applied the wavelet transforms and an artificial neural network (ANN) algorithm to the EEG signal in order to identify sleep apnea episodes. Recently, [ 17] proposed a method which used Melfrequency cepstral coefficients (MFCC) as features extracted from respiratory sounds. They applied support vector machine classifier to distinguish normal, obstruction pathology airway and parenchymal pathology. They achieve an average classification accuracy of 90.77%.
Indeed, there are several methods for classification of normal and sleep apnea breathing patterns. However, in this paper five different types of respiration disorders either with or without apnea are considered and remotely classified using hierarchical SVM, based on the best extracted features from accelerometer sensors data. SVM introduced by Vapnik [ 18] in 1995, is a set of related supervised learning methods used for classification, regression and ranking. SVM classifiers are trained by a learning method from optimization theory which makes a learning bias obtained from statistical learning theory [18][19][20]. Nonlinear problems in SVM are solved by mapping the n-dimensional input space into a high dimensional feature space in which a linear classifier is constructed which acts as a nonlinear classifier in input space [ 19]. In this work, different types of SVM classifiers are evaluated on five different breathing disorders, and finally the accuracy, sensitivity, specificity and G-mean parameters are calculated for distinguishing of healthy and unhealthy subjects.
The advanced low-cost and energy efficient data transport architectures for body sensor networks allow the doctors and physicians monitor their patient remotely with serious focus and effect on successful results in healthcare [ 21]. Therefore, in this paper we address a primary advance in this capability through development of a platform. It delivers required accuracy, continuous monitoring at low cost, and cloud computing for breathing disorders classification. Indeed, in each breathing cycle the volume of the thoracic cavity is changed, resulted from the displacements of the rib cage and diaphragm. Hence, we employ an accelerometer sensor mounted on the subject's chest to capture the movement of the rib cage while also providing more comfort compared to other locations, such as suprasternal notch. The previous approaches are primarily based on the use of offline data loggers and on-board signal processing. However, in our system we use cloud computing which can offer significant advantages over traditional methods, including increased on-line accessibility, scalability, automatic failover and fast automated recovery from failures.
The accelerometer data is transmitted via Bluetooth Low Energy (BLE) to PC/smartphones and then it is sent to the cloud to be processed and saved, immediately. The algorithms and models run on the backend and feed the application with relevant data in a reasonable amount of time. It is worth mentioning that in case of network disconnection, the data is saved in the intermediate interface. Therefore, the physicians can track the patients wherever they are with devices such as smartphones, tablets or the web regardless of their proximity to the patients. Moreover, in this study the accuracy of respiration rate compared to previous works [ 14], [ 12] has been improved in view of rest conditions as well as providing a classification for different breath problems. The overall proposed system is represented in Figure 1. Respiration rate analysis and classification methods are explained in details in the next sections. In Section 2, a new method is used to accurately calculate the respiration rate. In Section 3, the hierarchical SVM has been applied on respiration signals which derived from the accelerometer to classify different types of the respiration patterns. Experimental results are presented and discussed in Section 4. In Section 5, normal and impaired respirations classification is investigated. Finally, Section 6 concludes the paper.

Respiration Rate Analysis
In this section, we describe a procedure to estimate the respiration rate at rest positions. Figure 2 shows the signal processing methods applied on the accelerometer sensor data to be validated with a reference i.e., SPR-BTA spirometer.
In order to make sure that the sensors' readings are accurate enough to be processed, we calibrate our accelerometer sensor using least square method proposed by [ 22]. Due to inherent deficiency or aging problems in cyber-biological systems, sensors calibration is suggested. Calibration, which is defined as the process of mapping raw sensor readings into corrected values, can be used to compensate the systematic offset and gain [ 23]. Generally, calibration of sensors requires experience and special accurate tools; however, a straightforward method to calibrate an accelerometer is performed at 6 stationary positions [ 22]. We need to collect a few seconds of accelerometer raw data at each position. Then the least square method is applied to obtain the 12 accelerometer calibration parameters. The calibration procedure is simple, and needs to be executed once. The calibration procedure can be briefly explained as: = . ( where: • Vector is accelerator sensor raw data collected at 6 stationary positions • Vector is the known normalized Earth gravity vector.
• Matrix is the 12 calibration parameters that is determined as below: In our experiments, the accelerometer sensor is mounted on the subject's chest for respiration rate analysis. The raw sensor data is filtered through a 10th order Butterworth low pass filter with cut of frequency 1 Hz; and spirometer signal is smoothed with window size 30. Figure 3a, depicts a part of respiration signals from sensor and spirometer for the normal breathing pattern of a 30 years old man. As can be seen, even though two signals seem similar, there is an unwanted cumulative error [ 14] over time that affected their synchronization. We found out that this type of error on signals occurs when two signals have different sampling frequency. Although, the sampling rates of accelerometer and spirometer are both set to 50 Hz, due to architecture of the inertial measurement unit (IMU), there might be a small difference between the sampling rate and measured frequency. So, to compare the respiration rate, it is essential to ensure that both signals have identical frequencies. For this purpose after rational fraction estimation, we resample our data by an anti-aliasing low pass FIR filter during the resampling process. In our experiments, the sampling rate of the accelerometer sensor was set to 50 Hz, however; the data was logged with about 52.5 Hz (measured frequency). With resampling process explained above, we could compensate the time lead about 0.05 per second ( Figure 3). It is worth noting that for resampling process the system automatically checks the number of samples in each analysis window to find the measured frequency of the sensor. Then, to find the best starting point between accelerometer and spirometer, the peak of their cross correlation is obtained while also used for synchronization of two respiration signals. Now, the respiration rate can be computed based on the number of local maxima in the breath signals per minute.

Respiration Pattern Classification
The main preprocessing steps for breath patterns classifications are calibration, filtering and resampling explained in Section 2. Once the data are processed, they must be collated and labeled based on the different classes such as Normal, Bradapnea, Tachypnea, Cheyn-stokes, Kaussmal, and Biot's respiration patterns. Then a hierarchical structure is built for modeling the classification problem. This is a tree like structure describing the patterns we are trying to classify. At each level of the tree, a SVM classifier is used based on the extracted features and data are separated into one of the branches. Once we reach a leaf node, a final classification is made. The classification structure is shown in Section 4 in more details.

Feature Extraction
Features can be thought of as statistically unique elements of the sensor data, which are used to differentiate diverse classes or states. In the proposed system, classes are the different respiration patterns inferred from various types of breath disorders such as Normal, Bradapnea, Tachypnea, Kaussmal and two types of constraint breathing, such as Cheyn-stokes and Biot's respiration patterns. Features such as energy, mean, maximum, standard deviation, inter-axes correlation and number of local maxima are calculated on both three axes (x, y, z) of the accelerometer and the magnitude of them �Mag = �x 2 + y 2 + z 2 �. The features are listed in Table 1. The S i corresponding to the signal, and n is number of samples. Besides, we extract the Approximate Entropy (ApEn) from the accelerometer signals as one of the main feature in our classifier explained in the next subsection. Indeed, there are a vast number of diverse features providing freedom in selection that best suit each application. A window of a fixed length (10 s) shifted in increments of 2 s was experimentally selected. We asked the subjects to pause breathing for at least 3 s to simulate the apnea in Cheyn-stokes and Biot's breathing patterns (in our experiments, no subject paused breathing more than about 5 s). The best features are extracted based on the obtained accuracy resulted from the training set.

Approximate Entropy (ApEn) Feature
ApEn is a technique introduced by Pincus [ 24] to quantify the regularity/irregularity of a signal. It has been applied to describe changes in physical activity measures as well as other movement tasks [ 25]. ApEn has two user-specified parameters: , a positive integer, indicates the length of compared window, and is the tolerance range. It is worth mentioning that, although and are critical in determining the outcome of ApEn, there is no established consensus for choosing these parameters in short data sets, especially for biological data [ 25]. In our experiments we set and to 5 and 0.15, respectively.

Features Description
Mean , where s i corresponds to the samples, i = 1, … , n , where s i corresponds to the samples, i = 1, … , n Inter-axis Correlation where 1i and 2i are samples from two axes, i = 1, … , n , where s i corresponding to the samples, i = 1, … , n

Approximate Entropy
For each ≤ − + 1, let ( ) be ( − + 1) −1 times the number of vectors within r of which means [ 26]: ApEn is obtained from the Equation (7) as follow [ 24]: The ApEn calculation returns a nonnegative number where higher value shows irregularity of the signal and more regularity resulted from the lower ApEn. Note that, ApEn can be used for small data samples even in real time [ 24] which makes it suitable for our cloud-based monitoring platform.

Hierarchical Support Vector Machine Classification
A support vector machine is based on constructing one or a set of hyperplane in a high dimensional space, which can be used for classification purposes. SVM constructs linear functions from a set of labeled training dataset. The linear separator is constructed considering maximum distance from the hyper plane to a fraction of the data points, named support vectors [ 19] and shown in Figure 4. SVM is designed for binary-classification problems with training samples. Each sample is indicated by ( , ) where ( i = 1, 2, … , n). For a given data set: where is either 1 or −1, indicating the class to which , belongs, and is a d-dimensional real vector. The notation refers to the Cartesian product of copies of , which is a d-dimensional vector space over the field of the real numbers.
The decision boundary of a linear classifier can be written as follows: where is a weight vector and is a bias. There are many linear separators; however the SVM aims to obtain the maximum-margin hyperplane from any data point. Indeed, this distance from the decision boundary to the closest data point determines the margin of the classifier. The linear classifier is defined as: Designing linear separator is to find the best and which maximize the geometric margin (2/|| ||), considering ( + ) ≥ 1 for all ( , ), = 1, … . This can be reformulated as a minimization problem as follow: . . ( + ) ≥ 1, = 1, … Indeed, this problem is a convex quadratic optimization with quadratic function subject to linear constraints which can transformed into the Lagrangian dual with the Karush-Kuhn-Tucker (KKT) conditions. Lagrange multiplier is linked with every inequality of the linear constrains in the primal problem as follow: Usually only a small parts of are not zero, the corresponding samples are support vectors. Optimal classification function is: presents the number of the support vectors. In order to improve linear separability, the original input space is mapped into a high dimensional space which is known as feature space. In this case the decision function of the classifier becomes: A kernel function � , � = ( ) � � gives the inner product value of and in the feature space. Therefore the final function becomes: Three types of kernels are evaluated in this paper which are: The SVM performance depends on the choice of the kernel function to transform data from input space to a higher dimensional feature space. There are no defined rules for choosing the kernel type, except satisfactory performance by simulation study [ 19]. Figure 4 depicts the whole system flow of breath disorder recognition architecture.

Experimental Results and Data Analysis
In this section, we provide experimental results on 12-bit resolution data derived from SensorTag [ 27] with three-axis low-power KXTJ9 accelerometer sensor (Figure 5a). The data is transmitted via CC2541 BLE, a new standard that allows Bluetooth equipment to run for long time on a single coin cell battery. It is worth noting that our node is fully radio type approved for US, Europe, Japan and Canada. The received sensors data are stored in the cloud in order to real-time or further analysis. The SPR-BTA spirometer signal is used as our reference measures the oral breathing only (Figure 5b), so a nose clip was used to prevent nasal breathing during recordings. The Go!Link USB sensor interface is used as the data logger of our spirometer.

Test Setup
The participants of this study were five males and six females aged 4 to 48 with Mean ± SD, 26.54 ± 11.9026. They were instructed how to perform each breath exercise before their recording sessions. The experimental trials lasted for about 45 min per subject. We asked the subjects to perform Normal, Bradapnea, Tachypnea, and Cheyn-stokes patterns, each for 2 min (6000 samples) and the other two types for 1 min with a 3 min rest interval. For simulating apnea in Cheyn-stokes and Biot's breathing exercises, we requested the participants to pause breathing for at least 3 s. The sensor was mounted on the subject's chest in the middle of sternum region (Figure 5c) and secured by a soft and elastic strap which is easy to attach and comfortable to wear. In the trial session, the subjects were in the lying position; however, the rest positions or activities in which rib cage is stationary could be considered.

Accelerometer Driven Respiration Validation
In this section, first the correlation between the spirometer and accelerometer signal is calculated on 11 different subjects with various ages, each for five types of breathing disorders. Next, the respiratory rate which recognized as important indicators of physical health or the exacerbation of medical conditions is calculated. In our test, the subjects are asked to perform six breathing patterns i.e., Normal, Bradapnea, Tachypnea, Cheyn-stokes, Kaussmal, and Biot's.
Bradapnea is regular in rhythm but slower than normal in rate. Tachypnea is the condition of rapid breathing, with respiration rate higher than 20 respirations per minute (rpm). Tachypnea may occur due to physiological or pathological problems [ 28]. Cheyn-stokes breathing pattern determined by gradually increasing, then decreasing the lung volume with a period of apnea. People suffering from central sleep apnea syndrome (CSAS) have the same breathing pattern at sleep [ 29]. Kussmaul which is defined as a rapid, deep and laboured breathing type usually occurs in diabetics in diabetic ketoacidosis [ 30].
Biot's breathing is characterized by periods of rapid respirations followed by regular periods of apnea. There are different reasons which causes Biot's breathing, such as damage to the medulla oblongata by stroke (CVA) or trauma, or pressure on the medulla due to uncal or tenorial herniation and prolonged opioid abuse [ 30]. Figure 6 shows samples of all normalized patterns extracted from spirometery and accelerometer.
The correlation of spirometer and accelerometer signals of all subjects for each breath pattern is shown in Figure 7. For example, in Normal pattern we have 22-minute data for 11 subjects and the correlation of the accelerometer and spirometer signals is achieved 0.83. According to Figure 7, the mean of the obtained correlations of all breathing patterns is 0.84 which shows a very close correspondence of the sensor and spirometer data.  According to the procedure explained in section 2, the average respiration rates are extracted from the 10-second windows for 11 subjects and 6 breath conditions. The overall error in respiration rate calculation is obtained 0.53% considering SPR-BTA spirometer as the reference. Thus, we could obtain better accuracy for respiration rate compared to [ 12], dual straingauge respirometers [ 31], and [ 14] in lying position using a single accelerometer. The details of the experiments are brought in Table 2. The average volume of air that was inhaled/exhaled per breath for each subject is also listed in Table 3. It confirms that the subjects were not over emphasizing the breathing movements. For instance, it can be seen that standard deviation in Cheyn-stokes breath is more than other types, meaning that subjects were correctly changed the air volumes in this exercise. Respiration per minute (rpm). Two kids were asked to perform only two breathing patterns out of Normal, Bradapnea and Tachypnea types. NA (Not Applicable) here means that the kids did not perform the trials.

Results and Performance Evaluation of Hierarchical SVM Classification
The proposed classification method is performed by using a cloud-computing and the results are sent to our monitoring platform. We categorized breathing data into six classes based on the features evaluations. Considering the proposed tree structure in Figure 8, first, the data are automatically separated into G11 and G12 groups, employing the assigned labels in "Labelling" section (see Figure 4) and then are passed in to the second and third levels.
Corr(x, y) Max(Mag) 100 SD(y) P(y) 100 SD(y) Mean(y) 100 Max(x) ApEn(y N ) 100  We have evaluated the performance of the proposed classification while it is individualized to every subject (case 1) as well as considering all subjects (case 2). Five samples of extracted features and accuracies in training phase for an individual subject are listed in Table 4 and the highlighted row corresponds to the best selected features. Table 5 also provides the best extracted features in terms of training accuracy while the system is trained with all subjects' data. The accuracies in both tables are achieved while the training set is the same as validation set. All simulations were carried out using the Radial Basis kernel Function (RBF) with σ = 1 and A in Tables 4 and 5 denotes the training accuracy calculated by our SVM classifier for each branch. We used linear and non-linear SVM classifiers on each level of our tree structure while training the system with randomly chosen 70% of the data. The performance evaluation is done by testing the remaining 30% of the data.
In Figure 8, G ij represents the j th group and f ik is the k th feature of the i th branch. Figure 9a shows the energy along axes y of the accelerometer versus the correlation of dimension x and y. The ApEn is applied on the normalized data while energy performs on x, y and z dimension after removing DC levels. Figure 9 shows the nonlinear trend plots for the different features in all branches of our classification structure while only a single system was trained with all subjects' signals (case 2).
There are totally 168 and 42 training trials for G 11 and G 12 for training subject's data individually. The numbers of trials for training all subjects' data are 1680 and 378, respectively. We calculate all combinations of defined features in each branch and then select the one with the best SVM training accuracy.
The processing window for testing data was experimentally selected to be 10 s in order to include at least one complete cycle including pause period (Apnea) for Cheyn-stokes and Biot's breathing patterns. As we mentioned before, the window is shifted in increments of 2 s. The average classification accuracy of 94.50% was obtained for RBF kernel function for 11 subjects while the proposed classification is individualized to every subject. In this case, the system is effectively tuned to every individual and the subjects can either perform training at home or during periodic visits to breath specialist or a physician. The classification performance of 81.29% was also attained when only a single system was trained with all subjects' data. As performance of SVM depends on the choice of the kernel function, we also evaluate the linear and polynomial degree 3 of kernel functions. Figure 10 demonstrates the differences of kernel function for features Max(z) and SD(y) as an example. Table 6 shows the selected features and accuracy for three types of kernel function in both cases 1 and 2. It also shows that the best training accuracy for each classifier obtained with different feature set. The classification of the dataset using the selected features in case 1 gives an average test accuracy of 94.52%, 93.15% and 84.93% for RBF, polynomial and linear kernel functions, respectively. In case 2, the test accuracy of the single system is 81.29%, 78.12% and 69.95% for RBF, polynomial and linear kernel functions, respectively. Therefore, we conclude that for our system (in both cases) the radial basis function results in better accuracy rather than the other two methods.

Normal and Impaired Respirations Classification
In another aspect, our classification problem could be modeled as a binary classification for detecting healthy (positive) or unhealthy (negative) subjects. In this case, , , , stand for true positives, false positives, false negatives and true negatives correspondingly. The performance of the classifier was quantified based on its sensitivity, specificity and the overall accuracy. It is worth mentioning that sensitivity is also called positive class accuracy or true positive rate, while specificity called negative class accuracy or true negative rate.
Another parameter often used is the geometric mean of sensitivity and specificity (G-mean) which is defined as the square root of the product between sensitivity and specificity as Equation (18). The average values of sensitivity, specificity and geometric mean of SVM classifications for 11 subjects with different kernel functions are shown in Table 7. Table 8   Therefore, the best classification parameters are achieved for distinguishing between Normal and impaired respiration patterns while using RBF kernel function.

Conclusions
In this paper, we presented an accurate, reliable and real-time respiration monitoring system. In fact, early identification through such portable monitoring systems and timely treatment of exacerbations can decrease the hospital admissions and slow deterioration while reducing early mortality and disease costs [ 32]. We presented a procedure to obtain the respiration rate with negligible error i.e., 0.53% for rest positions. The results reveal the potential of remote accelerometer based respiration monitoring as a simple, convenient and low-cost method. Besides, a hierarchical SVM has been proposed to classify five types of respiratory problems for the purposes of diagnosis. Three different kernel functions are evaluated and finally, the radial basis function (RBF) was shown to outperform the classification accuracy of linear and polynomial functions. We also tested our method for normal and impaired breathing classification and the comparison demonstrated that RBF kernel function is again better in terms of accuracy, specificity, sensitivity and G-mean. The results permit to consider SVM analysis as a promising methodology to study the respiratory patterns in patients with breath disorders. Utilizing cloud computing which provides vast pool of computation power and unlimited storage space let the physicians share information together and precisely diagnosis the breathing diseases. As a future work, we are going to add respiratory therapy in the platform is such a way that professional experts can remotely monitor the patient's progressing in performing the prescribed breathing exercises.

Author Contributions
This paper is part of a Ph.D. thesis written by Atena Roshan Fekr under supervision of professors Zeljko Zilic and Katarzyna Radecka. Majid Janidarmian is participated in the hierarchical classification algorithm, experimental results and also contributed regarding final paper structure.