Usefulness of Artificial Neural Networks in the Diagnosis and Treatment of Sleep Apnea-Hypopnea Syndrome

Sleep apnea-hypopnea syndrome (SAHS) is a chronic and highly prevalent disease considered a major health problem in industrialized countries. The gold standard diagnostic methodology is in-laboratory nocturnal polysomnography (PSG), which is complex, costly, and time consuming. In order to overcome these limitations, novel and simplified diagnostic alternatives are demanded. Sleep scientists carried out an exhaustive research during the last decades focused on the design of automated expert systems derived from artificial intelligence able to help sleep specialists in their daily practice. Among auto - mated pattern recognition techniques, artificial neural networks (ANNs) have demon - strated to be efficient and accurate algorithms in order to implement computer-aided diagnosis systems aimed at assisting physicians in the management of SAHS. In this regard, several applications of ANNs have been developed, such as classification of patients suspected of suffering from SAHS, apnea-hypopnea index (AHI) prediction, detection and quantification of respiratory events, apneic events classification, auto - mated sleep staging and arousal detection, alertness monitoring systems, and airflow pressure optimization in positive airway pressure (PAP) devices to fit patients’ needs. In the present research, current applications of ANNs in the framework of SAHS manage - ment are thoroughly reviewed.


Introduction
In their daily practice, physicians must frequently decide a definitive diagnosis or the most suitable treatment using several variables from multiple clinical data sources, which is a highly complex task. A huge amount of valuable healthcare-related information is currently available, from symptoms reported by the patient and details stored in their clinical history to biochemical data and outcomes from biomedical recordings or medical images. In this context, machine learning methods are essential to maximize the usefulness of medical data in order to expedite decisions and avoid misdiagnosis. In the last decades, the increasing development of computers and artificial intelligence has led to the use of decision support expert systems in the common clinical practice of several fields of medicine [1,2]. The huge number of studies published in the context of biomedical engineering during the last years clearly shows this trend.
Bayesian theory was one of the first mathematical frameworks used to implement decision support systems. Regarding the classification of an item, according to the Bayes' decision rule, the predicted class must be the one that maximizes a posteriori probability in order to minimize the classification error. A major goal is to model the statistical characteristics of the problem under study, leading to expert systems able to assist physicians in decision-making processes. Among pattern recognition algorithms, conventional statistical classifiers, such as discriminant analysis [3] or logistic regression (LR) [4], and more recently artificial neural networks (ANNs) [5], have been widely applied. The widely known statistical classifiers assume that the class density function of input data is known a priori. Assumptions such as normal distribution, homoscedasticity, linearity, independency, or stationarity decrease the complexity of the classifier, minimize the classification error, and improve the performance. Nevertheless, these assumptions are not always consistent in real-world pattern classification problems, especially when working with limited datasets. Conversely, when using ANNs, no assumptions are made about the probability density functions of input features and the training data is used directly to optimize the decision rule [6]. Nevertheless, ANNs are characterized by a complex design stage. Both statistical and ANNs approaches have its advantages and limitations. However, the ability to model complex nonlinear problems, which are very common in biological systems, have made ANNs widely used in medical applications.
The first attempt to model information processing in biological systems by means of ANNs was carried out by McCulloch and Pitts in 1943 [7]. Since then, ANN-based algorithms have significantly evolved and their use in the field of medicine has increased considerably, particularly since the late 1990s. Some computer programs in the context of statistical medicine already include ANNs among their functionalities, which has contributed to increase their use in medical research. Nevertheless, "neural network" remains frequently a confusing term for many healthcare-related researchers. The implementation of an ANN has to be carried out by means of advanced software and some expertise is required to set up properly the userdependent input parameters. However, once designed, they are reliable and easy to use tools, even by nontrained personnel. In addition, once optimized, the computational time is small, which is a major feature in order to speed up decision making.
Sleep research and particularly sleep-related breathing disorders (SBD) is a field in which the application of automated pattern recognition algorithms has increased exponentially during the last years due to the need for automating their complex diagnostic processes. Particularly challenging is the management of sleep apnea-hypopnea syndrome (SAHS). The gold standard technique for SAHS diagnosis is in-lab nocturnal polysomnography (PSG). During PSG, several neuromuscular and cardiorespiratory signals (up to 32 biomedical recordings) are monitored and stored for subsequent interpretation by trained personnel, which is a highly complex and time-consuming task [8]. In addition, accessibility to diagnosis and treatment is limited due to insufficient resources, both human (trained specialists) and technical (specialized sleep units), which have led to large waiting lists [9]. In this context, automated computer-aided diagnosis systems have emerged as very useful tools to deal with complex rules involving several biomedical recordings simultaneously, in order to expedite diagnosis and treatment [10][11][12]. Among all the machine learning-based tools, ANNs have been widely applied in the context of SAHS and merit a thorough analysis.
In order to analyze the usefulness of ANNs in the management of SAHS, an exhaustive review of the studies published during the past decade has been carried out. The review is structured as follows. First, the most relevant tasks regarding the ANNs learning process are outlined in Section 2. In this regard, some user-dependent decisions involving the ANN design and major issues concerning the training and testing processes are detailed. Second, in Section 3, the most relevant applications of ANNs are analyzed, including automated diagnosis, sleep staging, and treatment monitoring.

Artificial neural networks
ANNs are mathematical models inspired in the information processing capabilities of the nervous system designed to accomplish a predetermined task specified by the user [13,14]. They were built to implement useful brain functions into a pattern recognition algorithm, such as parallel processing, distributed memory/storage, and environmental flexibility. ANNs are characterized by a fast and effective processing, learned from a preceding training process. During the learning or training stage, a wide set of known representative samples are used in order to model the statistical properties of the problem under study and accordingly compose the structure of the network. Figure 1 illustrates a common network architecture of interconnected nodes arranged in layers simulating the brain's neuronal synapses.
The following advantages can be obtained when ANNs are applied for pattern recognition problems: (i) no prior assumptions about the data distribution are made as ANNs adjust themselves to the particular problem constrains during the learning process [15], (ii) ANNs are universal estimators able to match any function with arbitrary accuracy [16], and (iii) they are nonlinear algorithms able to model real-world complex relationships [15].
There are two major classes of ANNs: feedforward multilayered networks and radial basis function (RBF) networks. Both types of ANNs are capable of approximating any continuous functional mapping by means of several units (neurons) arranged in different layers [17]. The main difference is the way hidden units are activated, i.e., how the input data is used to compute the output of each unit. In feedforward ANNs, there is a fixed (usually nonlinear) activation function, whereas in RBF ANNs, the activation of each unit depends on the radial distance (typically Euclidean) between the input vector and a prototype vector (center) [18].
The multilayer perceptron (MLP) is the most widely used feedforward ANN in computer-aided medical research. Indeed, feedforward networks, particularly MLP, are the most popular ANN in the framework of SAHS management [19][20][21]. A particular implementation of MLP networks involving Bayesian inference during the learning process (BY-MLP), which increase the generalization ability and allow for relevance analysis of input variables, has demonstrated to be useful in this context [22]. Similarly, probabilistic neural networks (PNN), which also integrates the Bayes' theory into the learning process, have been recently applied in the SAHS diagnosis problem [23]. In addition, RBF ANNs [24,25], such as learning vector quantization (LVQ), which is a precursor of self-organizing maps using the Hebbian learning-based approach [26,27]; fuzzy neural networks (FNN), which incorporate the fuzzy inference system (FIS) into the learning process [26,28,29]; self-organizing maps (SOM) and adaptive resonance theory (ART) models, which are likely the most common unsupervised ANNs [30,31]; and recurrent neural networks (RNN), which allow for closed-loop connections between units (feedback) [32], have been also applied in the framework of automated SAHS management.
Next, an overview of the conventional multilayered network architecture is provided, as well as the most important issues regarding the design, training, and validation stages common to all approaches in the ANN-based framework. Figure 2 shows a flow diagram summarizing these stages.

Network design: architecture of a neural network
The so-called neuron is the basic element within an ANN, which comprises its elementary mathematical functions [17]. ANNs are composed of multiple interconnected nodes arranged in different levels or layers leading to a massive parallel structure. The first level is called the   input layer. Neurons in the input layer process directly the feature vectors or patterns that feed the ANN. Similarly, each output from every neuron in a layer feeds neurons composing the subsequent layer, leading to a distributed complex structure. The last level of the network, whose nodes provide the output of the ANN, is called the output layer. The remaining internal levels are called hidden layers. Both the number of hidden layers and the number of nodes are flexible and are determined during the learning process. The feedforward architecture is the most widely used, where each neuron in a layer is connected to every neuron on the next layer but neither connections between units in the same level nor closed-loops (feedback) are allowed. Therefore, data is always moving forward from one layer to the next, i.e., from the input to the output.
There is not a predetermined network architecture known to be a priori the best for any problem under study in terms of performance. The mathematical operation accomplished by each neuron is always the same. Therefore, the functionality of the ANN, i.e., the way in which a particular problem is addressed, is determined by the strength of the link between each pair of neurons. This strength is characterized by the coefficients of the ANN, the so-called weights, which are optimized during the training stage. Similar to the process of memory, weights represent the information stored in the network, whereas the optimization procedure represents the learning process or statistical inference [18].
As aforementioned, the structure of an ANN depends on the number of hidden layers, the number of neurons per layer, and the connectivity strength among them. Regarding the number of levels, it is common to construct ANNs with a single hidden layer because it has been demonstrated that this architecture is able to achieve universal approximation [33]. This is a userdependent decision, whereas the number of neurons and the connectivity degree (weights) are both determined automatically during the learning process. Regarding the number of nodes in the hidden layer, it is commonly optimized by means of a hold-out or cross-validation approach using the data in a training dataset. In this regard, it is supposed that the complex the problem, the higher the number of neurons. Notwithstanding, even a small network with a reduced number of nodes can model complex problems and reach high prediction ability. In addition, the following design issues must be addressed before the learning process [17]: the output coding scheme, the error function used in the network training, and the activation function of neurons in the hidden and output layers. The hyperbolic tangent function is a common activation function for neurons in the hidden layer since it has been demonstrated that it provides fast convergence of training algorithms [13,17]. Figure 3 shows a common schema of a single neuron (perceptron) with a sigmoid activation function. Regarding the learning process, the scale conjugate gradient (SCG) is a common method for updating the adjustable parameters of the ANN (weights and biases) during the training stage.

Classification and regression approaches
According to the mathematical nature of the output, ANNs can be applied to address two main kinds of problems: classification and regression. Regarding the classification approach, the goal of the ANN is to estimate the class membership for an input feature pattern among a set of predefined discrete categories. Conversely, in a regression task, the goal of the ANN is to estimate a continuous variable.
In the context of binary classification problems, an output layer with just a single neuron is needed. Regarding, for instance, a 2-class SAHS diagnosis problem, all input patterns are assigned to one of two mutually exclusive classes: SAHS positive (class C 0 or positive class) or SAHS negative (class C 1 or negative class). A possible target coding scheme would be the following: t = 0 for the positive class and t = 1 for the negative class. This architecture can be used also in regression problems, where the variable to be approximated is unidimensional and continuous. In the context of SAHS diagnosis, the goal of a regression ANN could be to estimate the apnea-hypopnea index (AHI).
Due to a highly flexible architecture, most of the ANNs can be used to model both classification and regression problems by just modifying certain design characteristics [17]. The main difference between classification and regression ANNs is linked with the nature of the function to be approximated. The output of an ANN is provided in terms of probability in a classification task while it is an estimate of a continuous variable in a regression context. Accordingly, optimization procedures differ from one approach to another. Regarding a binary classification approach, the activation function of the output neuron could be a nonlinear function with output values ranging [0, 1], e.g., sigmoid functions such as the logistic or the hyperbolic tangent.
In this regard, the network output can be interpreted as the probability that the input feature pattern belongs to one class or another according to the Bayes' theorem. Conversely, addressing a regression task, the network output values must be continuous and nonnegative. Therefore, a linear activation function ranging [0, ∞) would be suitable.
Regarding the error function governing the learning process, the cross-entropy error function is widely used in the context of binary classification, whereas the sum-of-squares error function is commonly used for regression purposes [17].

Standardization of input patterns
Normalization of input feature values is an important task in nonlinear pattern recognition methods [34]. Bounded similar input magnitudes are needed to accomplish suitable weight initialization. Input patterns are composed of features parameterizing different properties of the problem under study, e.g., the influence of recurrent apnea events typical of SAHS on cardiorespiratory signals. Usually, several features of different nature are involved in order to obtain as much information as possible, e.g., sociodemographic, anthropometric, clinical, and/or variables from automated feature extraction algorithms. Therefore, their values may differ significantly and thus they must be normalized. In this regard, simple linear rescaling can be used to standardize (zero mean and unit variance) the magnitudes of each input feature by subtracting its mean and dividing by its standard deviation.

The training process: learning the problem under study
Training is the most important stage when working with ANNs. The aim of the training process is to adapt the ANN to the problem under study by computing some adjustable parameters.
The training or learning process can be (i) supervised, in which the learning process is guided by a static mapping between input patterns and known targets; (ii) reinforced, in which a performance function assesses the accuracy of the current output instead of knowing the actual target values; and (iii) unsupervised, in which ANNs adapt themselves to input patterns with no kind of feedback [35]. In the context of medical decision support systems, the supervised approach is the most widely used. When using supervised learning, it is essential to know the target or actual output value for a wide set of input patterns. The dataset of examples used during the learning stage is referred to as the training set. According to this training input-output pairs, the network weights are tuned to fit the input to its corresponding target. It is important that the training set would be large enough to represent fairly the problem under study.
The backpropagation learning is the most commonly used methodology for updating weights in feedforward ANNs due to its computational efficiency [17]. Using this approach, all weights are updated every time an input pattern is fed from the training dataset in order to minimize an error function. First, the network weights are initialized randomly. During a supervised learning process, the training samples (input-target pairs) are fed into the network and the error function is computed, i.e., the difference between the estimated output value and the desired target according to a predefined suitable function. Then, the values of the network weights are modified in order to minimize the error. This procedure is repeated throughout several iterations, which are set by the user. Once the training process is finished, all network weights already have a fix value, i.e., there is a single optimized ANN able to carry out the task for which it was designed.

Generalization ability and the problem of overfitting
Once optimized, an ANN is able to process new input patterns independent of the training dataset. In this regard, it is noteworthy that the goal of the training stage must be to build a general statistical model of the problem under study rather than to learn data samples from a particular training set. This is an essential characteristic common to all pattern recognition techniques and it is required to achieve good generalization ability. Generalization accounts for the ability to make good predictions for new unknown inputs [17].
In addition to the user's capability to accomplish appropriate design and optimization procedures, the performance or generalization ability of an ANN is influenced by three main factors [13,36]: (i) the size and completeness of the training dataset, i.e., whether the learning samples account for all the variability of the environment or problem of interest; (ii) the number of adjustable parameters in the model; and (iii) the complexity of the problem under study. The nature of the problem or model complexity is linked with the number of adjustable parameters in the ANN (network weights) and it cannot be controlled. Theoretically, the harder the problem, the more complex the ANN. In this regard, it is important to achieve a compromise between the generalization ability and complexity. An ANN with a small number of parameters, i.e., low flexibility, may lead to an underfitted model, insufficient to reach high generalization. On the contrary, an ANN with a large number of weights may lead to an overfitted model that matches a particular training dataset, resulting in poor generalization. Underfitting can be avoided by increasing the flexibility, whereas overfitting requires the training set to grow accordingly to the network complexity [13].
In the same way, the optimization of an ANN is closely related to the bias-variance tradeoff. A too simple or inflexible model will have a large bias and may lead to underfitting. Conversely, models with a high variance provide high flexibility but could adapt to the noise present in the training set, leading to overfitting. Bias and variance are both complementary characteristics and thus the best generalization is obtained when a compromise between the conflicting requirements of small bias and small variance is achieved [15,17].
A way to reduce both bias and variance simultaneously is to increase the number of training samples. As a result, model complexity increases, which minimizes the bias. At the same time, constrains imposed by the training data will be more rigorous, thereby also reducing variance. As mentioned earlier, to achieve this goal the size of the training set should increase in accordance with model complexity [17]. Nevertheless, this requirement cannot always be achieved in real-world applications because the size of the training set is usually fixed and limited. Therefore, finding the optimum model complexity is a major issue. In order to deal with this optimization problem, a new trade-off arises: simpler models are preferred but smoothing mapping is needed to prevent from poor generalization [13,17]. In this regard, regularization techniques allow the ANN to control the effective complexity of the model by reducing the number of adjustable parameters during the training set. Weight decay and early stopping are common approaches of regularization. Weight decay is probably the most widely used, consisting on adding a penalty term to the error function in order to penalize complex mappings.
An additional issue regarding the training sample size is called the course of dimensionality [17]. This term refers to the relationship between the size of the training set and the dimension of the feature space, i.e., the number of variables in the input feature vector. The course of dimensionality states that the number of training samples needed to characterize the underlying problem grows exponentially as the number of input features increases. Therefore, the size of the training dataset must also increase according to the input space dimension in order to enhance generalization ability and avoid overfitting [18].
As previously stated, the size of the training set in real-world applications is fixed and usually limited, especially in the field of medicine. In this regard, dimensionality reduction techniques contribute to address the problem of overfitting due to the curse of dimensionality. An ANN fed with fewer input features needs to optimize fewer parameters (weights) and these are more likely to be properly characterized by a limited training dataset. The aim of dimensionality reduction algorithms is to compose a reduced subset of the most significant features governing a model. To achieve this goal, a fitness metric (relevancy, redundancy, completeness, or accuracy, among others) is used to obtain the optimum feature subset. There are several feature selection methodologies but principal component analysis and stepwise feature selection are likely the most widely used in medical applications.

Validation and test processes: model selection and performance assessment
In order to estimate the actual prediction ability of an ANN, the learning, model selection, and performance assessment stages must be carried out using independent datasets, i.e., the so-called training, validation, and test datasets. The goal of model selection is to obtain the optimum network configuration by comparing the performance of several ANNs with different values of the design parameters, i.e., number of neurons in the hidden layer and usually the regularization parameter. The hold-out method is commonly used for this purpose because it avoids a biased estimation of the results [36]. In the hold-out method, the initial population/dataset is split into three independent groups for training, validation, and testing purposes. The network weights are adjusted in the training set for different configurations of the adjustable parameters specified by the researcher, i.e., multiple ANNs are really trained, whereas the performance of each individual ANN is computed in the validation set to determine the optimum ANN for the problem under study. Since there is a random initialization of weights, the training process is frequently repeated several times to avoid a potential bias linked with this arbitrary decision. Thus, the performance metric for model selection from the validation set is averaged across all the repetitions. Nevertheless, this procedure can lead also to some overfitting so the selected optimum ANN has to be further assessed in an independent test set composed of unseen data samples [17].
It is worth to notice that, unfortunately, several studies from the literature do not implement a suitable validation of their proposed methodology, providing biased overoptimistic results [37]. On the other hand, sometimes the initial dataset is not large enough to properly derive the three independent subpopulations. In such cases, cross-validation techniques allow for training and validating the models in the same training set without biasing the selection of the optimum model. Bootstrap, leave-one-out, and k-fold cross-validation are common algorithms to deal with small populations under study.

Clinical applications of NNs in the context of sleep apnea-hypopnea syndrome
ANNs have been applied to model problems in several fields, such as industrial processes optimization, economic and financial modeling, chemistry, physics, biology, or medicine, among others [38][39][40][41][42]. In the framework of SAHS management, automated expert systems based on ANNs have been mainly applied to classify patients suspected of suffering from SAHS (binary classification: no SAHS vs. SAHS), to categorize the severity of the disease (multiclass classification: no SAHS, mild, moderate, and severe), to estimate the AHI (regression of a continuous variable), to detect and quantify respiratory events (normal breathing vs. apneic), and to categorize apneic events (central, obstructive, and mixed). ANNs have been also used to implement automated sleep staging and arousal detection, which are very useful functionalities incorporated in current commercial software applications for sleep analysis. In addition, ANNs play an important role in alertness monitoring systems and they are already integrated in positive airway pressure (PAP)-based treatment devices to fit user's airflow needs, which are major issues for patients suffering from SBDs.
Most research in the field of SAHS focus on binary classification in order to determine the presence or absence of the disease. Similarly, some studies also applied ANNs for multiclass classification in order to characterize SAHS severity according to predefined discrete categories. Conversely, despite of its higher information about the severity of the disease, only a few studies have been carried out to estimate the AHI using a regression approach (continuous function).
Regarding the nature of the input data, ANNs aimed at assisting in SAHS diagnosis first used anthropometric and clinical features to compose input patterns [19,43]. However, the increasing research in the context of biomedical signal processing allows physicians to derive essential information directly from signals monitored during the PSG [44]. In this regard, blood oxygen saturation (SpO 2 ) from oximetry and heart rate variability (HRV) from electrocardiogram (ECG) are the most widely used. In addition, airflow from both thermistor and nasal pressure, abdominal and chest movements, snoring sounds, and EEG have been also studied. Alternatively, in order to avoid sleep studies, automated signal processing of speech recordings and even image analysis for facial recognition have been also assessed as an alternative to PSG-derived signals to assist in the detection of SAHS.
The main goal of computer-aided tools for SAHS management is to simplify and speed up the diagnostic methodology, in order to alleviate large waiting lists and increase accessibility of patients to diagnostic resources. Current research focuses on analyzing a reduced set of biomedical recordings, which are preferably obtained at patient's home using existing commercial portable devices. Therefore, powerful tools are needed to obtain as much information as possible from this reduced subset of signals. In this regard, ANNs allow researchers to manage several features derived from the signals under study and thus they are suitable and reliable tools to help physicians in the diagnosis of SAHS. In order to obtain complementary information, different automated signal processing methods have been applied, such as common statistics (mean, median, variance, skewness, kurtosis), time domain analyses (detection and quantification of respiratory events), frequency domain analyses (Fourier analysis, time-frequency maps, wavelet transform, bispectrum), and/or nonlinear methods (entropy measures, Poincaré plots, complexity measures), among others, both individually or jointly.

SAHS diagnosis by means of ANNs
ANNs were first used in the context of SAHS detection in the late 1990s, when Kirby et al. [43] and El-Solh et al. [19] carried out retrospective analyses aimed at designing ANNs based on clinical and anthropometric variables from patients showing clinical suspicion of SAHS. Bayesian training has been applied to deal with overfitting of ANNs. In addition, Bayesian inference also allows the user to measure quantitatively the influence of each input feature in the output of the model. The effectiveness of this approach was assessed in the study by Marcos et al. [22]. A sensitivity of 87.76%, specificity of 82.39%, and accuracy of 85.58% were reached, significantly improving the performance achieved using the conventional maximum likelihood criterion (86.42% sensitivity, 62.83% specificity, and 76.81% accuracy). Similarly, Sánchez-Morillo et al. [47] applied a feedforward probabilistic ANN to classify patients into SAHS negative or SAHS positive using time, stochastic, spectral, and nonlinear features from nocturnal SpO 2 recordings. A sensitivity of 92.42%, specificity of 95.92%, and accuracy of 93.91% were reached in a single training set using leave-one-out cross-validation. In a recent study by Huang et al. [26], the automated analysis of the oxygen desaturation index of 4% (ODI4) from oximetry by means of a DT was proposed as an abbreviated method for SAHS screening. In this work, the authors assessed several pattern recognition techniques for automated diagnosis, including some ANNs, such as conventional backpropagation, (LVQ), and adaptive network-based fuzzy inference system (ANFIS  88.33% accuracy), and LVQ (80.67% sensitivity, 79.33% specificity, 80.00% accuracy) ANNs. In this study, conventional LR and k-nearest neighbors (k-NN) combined with genetic algorithms (GAs) and particle swarm optimization (PSO) also outperformed ANNs.
ECG recordings have been also widely used to assist in SAHS diagnosis. In the study by Khandoker et al. [23], the spectral content of HRV and ECG-derived respiration (EDR) time series from single-lead ECG recordings were analyzed by means of the wavelet transform. The authors proposed a binary SVM for classification (healthy vs. SAHS) and compared its performance with LDA, k-NN, and PNN. The proposed SVM classifier reached 100% accuracy in the test set, whereas the PNN showed poor classification performance (80% sensitivity, 50% specificity, and 70% accuracy) probably due to a suboptimal setting of the spread parameter (σ) of the Gaussian function. In a previous study by Khandoker et al. [48], the authors analyzed ECG short-term epochs from nocturnal PSG by means of wavelet decomposition to classify segments into normal breathing, obstructive apnea, and central apnea using a feedforward ANN.  [51], both time and spectral features from the R-to-R interval (RRi) and QRS area time series were used as inputs to a FFBB ANN aimed at discriminating between apneic and nonapneic segments. A sensitivity of 89%, specificity of 86%, and accuracy of 88% were reached in a minute-by-minute classification, whereas 100% accuracy was achieved when the whole recording is classified as normal or apneic. In a recent study, Nguyen et al. [52] proposed a binary ANN to differentiate apnea from normal sleep based on a hear rate complexity measure by means of the recurrence quantification analysis of HRV recordings. In addition, a SVM classifier and an ensemble combining the decisions from both binary classifiers by means of a confidence score (the weighted sum of the output scores of all binary classifiers) were also assessed. ANNs have been also involved in the detection and characterization of snoring and its reliability in SAHS diagnosis. In the study by Fiz et al. [53], a total of 22 features from time and frequency domains (number of snore episodes, average intensity, and power spectral density parameters) were used as inputs to a MLP ANN. A sensitivity of 87% and a specificity of 71% were achieved using a SAHS cutoff of 5 e/h, whereas 80% sensitivity and 90% specificity were reached for a cutoff of 15 e/h. In a recent study, Nguyen and Won [54] proposed a novel correlational filter ANN (f-MLP) to distinguish normal breathing patterns from snoring patterns during sleep. This ANN implements a correlational filter operation in the frequency domain in a first hidden layer aimed at improving the discriminant power of the spectral content of input patterns, followed by a second feedforward hidden layer. In this study, the authors reported that the f-MLP classifier reached an average accuracy of 96%, outperforming the conventional MLP approach (82% average accuracy).
EEG signals from nocturnal PSG and ANNs have been also used to detect SAHS. Tagluk et al. [55] estimated the quadratic phase coupling of EEG (C3-A2) using bispectral analysis and trained a MLP ANN to detect patients with SAHS. An overall diagnostic accuracy of 96.15% was reached. In the study by Liu et al. [31], both the EEG energy in the theta band and the pupil size were used as inputs to an ANN aimed at discriminating between SAHS patients and healthy subjects. The authors reported 91% overall accuracy in the classification of both groups. Similarly, in the study by Lin et al. [28], the EEG (C3-O1) signal power in the common frequency bands delta, theta, alpha, and beta were estimated by means of the discrete wavelet transform (DWT) and subsequently used to train a FFBB ANN in order to identify SAHS episodes. A sensitivity of 69.64% and a specificity of 44.44% were obtained. The EEG signal has been also used to classify apnea events into obstructive or central. Akṣahin et al. computed the synchronization (coherence and mutual information) between EEG channels (C4-A1 and C3-A2) and fed three different ANN-based binary classifiers: conventional FFBB, RBF, and distributed time-delay (DTD) ANNs [56]. The conventional FFBB ANN reached the highest performance in terms of the mean relative absolute error (MRAE = 0.145).
Features from both thoracic and abdominal effort signals have been also used to classify sleep apneas into obstructive, central, and mixed by means of ANNs. In the study by Fontela-Romero et al. [57], the wavelet coefficients from the DWT of the thoracic effort signal feed a Bayesian feedforward ANN, which achieved a mean accuracy of 83.78 ± 1.90%. Similarly, Tagluk et al. [58] analyzed the abdominal respiration signal by means of the wavelet transform and fed a FFBB ANN aimed at classifying apneic events into obstructive, central, and mixed. The proposed methodology achieved an overall accuracy of 78.5% (obstructive: 73.42%; central: 94.23%; mixed: 66.16%). In a recent study by Guijarro-Berdiñas et al. [59], the thoracic effort signal was used to reach the same goal. The DWT was applied to analyze the frequency content of the signal. The wavelet coefficients compose the input patterns of an ensemble of ANNs, which achieved an overall accuracy of 90.27 ± 0.79% (obstructive: 94.62%; central: 95.47%; mixed: 90.45%).
In the study by Weinreich et al. [60], the spectral entropy was used to analyze the frequency content of airflow recordings and feed an ANN trained to discern among SAHS, Cheyne-Stokes respiration, and normal breathing. An overall accuracy of 91.5% was reached in the classification of airflow patterns into obstructive apneas, periodic respiration, and normal breathing during non-REM sleep. Similarly, Várady et al. [61] trained a feedforward ANN to detect apneic events using respiratory signals. Data from both airflow and respiratory induc-tance plethysmography were used as inputs to the ANN. Up to 93% of input respiratory patterns were correctly classified into normal, apnea, or hypopnea, although no validation was performed.
ANNs have been also used to combine features from different biomedical recordings. In the study by Belal et al. [62], the correlation coefficients between the heart rate (HR), respiratory rate (RR), and SpO 2 signals were computed to detect apnea events in preterm infants in real time. Principal component analysis (PCA) was applied to the correlation coefficients and the components accounting for the 70% of the total variance of the input data fed the MLP ANN, yielding 81.85% sensitivity, 75.83% specificity, and 76.78% accuracy.
It is noteworthy that most studies in the context of SAHS use ANNs for classification purposes, whereas only a few studies apply regression ANNs to estimate the AHI. This is a more challenging task but also a more useful approach, since the AHI is currently a standardized parameter widely used by physicians to assess SAHS severity and to decide whether the CPAP treatment could be effective. In the aforementioned study by El-Solh et al. [19], the authors compared the agreement of two automated regression approaches with the actual AHI from PSG. Multiple linear regression (MLR) and a regression MLP ANN, both trained with anthropometric and clinical variables, were assessed. Significantly higher correlation was reached using the MLP ANN (0.852 vs. 0.509). In the same way, Marcos et al. [63] used spectral and nonlinear features from nocturnal SpO 2 recordings to feed a regression MLP ANN. High intraclass correlation coefficient was reported (ICC = 0.91), which outperformed the conventional MLR approach (ICC = 0.80). Similarly, in a recent study by Gutiérrez-Tobal et al. [25], regression MLP and RBF ANNs were trained to estimate the AHI from PSG using statistical, spectral, and nonlinear features derived from the airflow signal (thermistor). The estimated AHI from the MLP network reached the highest agreement with the PSG-derived AHI (ICC = 0.849 ± 0.002), improving both the RBF and the conventional MLR models.
A snore-based approach has been proposed by de Silva et al. [64] in order to estimate the actual AHI from PSG. Features from the automated analysis of snoring recordings (pitch, first formant, and the quantified recurrence probability density entropy) and the neck circumference were used as inputs to a FFBB ANN to predict the AHI. Averaged 91 ± 6% sensitivity and 89 ± 5% specificity were obtained using a cutoff of 15 e/h for positive SAHS, whereas for a cutoff of 30 e/h, 86 ± 9% sensitivity and 88 ± 5% specificity were achieved. In a similar subsequent study, de Silva et al. [65] proposed this methodology to characterize differences in snoring sounds due to gender and assessed its influence on the performance of a snore-based SAHS screening model. Using an output threshold of 15 e/h, the gender-dependent regression ANN resulted in increased sensitivity (up to 7% higher) and specificity (up to 6% higher) values compared with the gender-neutral model. In the study by Emoto et al. [66], a MLP ANN was used to predict the current value of the breathing sound signal using the preceding samples, i.e., the target output is the current sample, whereas the d-dimensional input feature pattern is composed by the preceding d samples of the breathing signal. In this way, the ANN was applied to distinguish snoring events from normal breathing comparing the network output with an optimized threshold. The proposed method reached an average sensitivity and specificity values of 89.2 and 87.4%, respectively.

Automated analysis of PSG: sleep staging and sleep/wake automated detection
In order to identify and quantify the number of respiratory events per hour of sleep and derive the AHI, several neuromuscular and cardiorespiratory recordings from the overnight PSG have to be analyzed. However, the interpretation of a PSG is a complex and laborious task even for trained personnel. In this regard, ANNs have demonstrated to be reliable as well as accurate tools to analyze both the macrostructure (automated sleep staging) and the microstructure (transient pattern detection) of sleep [67]. In the context of sleep staging, nonlinear dynamic measures from EEG in combination with pattern classification algorithms have demonstrated to reach clinically significant results in sleep disorders diagnosis, treatment monitoring, and drug efficacy assessment [68]. In fact, a number of automated algorithms are currently implemented into commercialized software tools for PSG analysis. Nevertheless, the performance of automated pattern recognition algorithms varies greatly depending on the number of stages involved in the classification task, from 2 (wake vs. sleep) to 5 (wake, REM, N1-N3) states (6 classes if the conventional Rechtschaffen and Kales classification is used). In addition, the accuracy is also influenced by the number and kind of recordings involved in the classification task (EEG, EOG, and/or EMG). Table 2 summarizes the main characteristics of significant studies focused on applications of ANNs for automated sleep staging, arousal quantification, and drowsiness detection.
In the study by Becq et al. [69], the relative power in the common frequency bands of the EEG (C3-A2), as well as the overall variance of EEG and EMG signals, was used to feed a 6-class MLP ANN. The proposed method reached the same performance as a k-NN classifier, achieving 28 ± 2% error rate. Ventouras et al. [70] trained a MLP ANN to detect sleep spindles using a bandpass filtered EEG channel (Cz) without feature extraction. The classifier achieved 80.2% sensitivity and 95.0% specificity in the whole sleep record after a consensus agreement among independent scorers. In the study by Caffarel et al. [71], an ANN-based commercial software using a single-channel EEG (Cz-A1) was assessed. The overall agreement between automated and manual scoring was relatively low in a 4-class classification task (kappa = 0.305) and slightly better in a 2-class classification task (kappa = 0.449). In a later study by Ebrahimi et al. [72], wavelet decomposition and ANNs were used to perform 4-class sleep staging using the EEG signal. An overall sensitivity of 84.2 ± 3.9%, specificity of 94.4 ± 4.5%, and accuracy of 93.0 ± 4.0% were reported. Wavelet coefficients from the EEG (P3-P4) and a backpropagation ANN were also used in the study carried out by Sinha [73]. expert scorers. In a subsequent similar study [75], the same wireless system achieved an overall agreement of 72.6% in a 4-class approach (Wake, REM, light, and deep sleep). Tagluk et al. [76] used bandpass filtered EOG and EMG recordings as inputs to a feedforward ANN in a 5-class classification task, achieving an overall accuracy of 74.7 ± 1.63%. Similarly, using statistical, spectral, and nonlinear features from EEG and EMG signals and an ensemble classifier based on multiple MLP ANNs, 64% overall performance was achieved for wakefulness, movement, and intermediate sleep detection, while 82% accuracy was reached for deep and paradoxical sleep detection [77]. In the study carried out by Charbonnier et al. [78], 85.5% overall accuracy was reached using EEG-, EOG-, and EMG-derived features as inputs to an ensemble of 4 MLP ANN for 5-class automated sleep staging.
In the study by Álvarez-Estevez and Moret-Bonillo [79], two EEG channels (C2-A2 and C4-A1) and the submental EMG channel were analyzed to automatically detect arousals in the context of SAHS classification. For these signals, the energy in the conventional frequency bands was computed by means of the Fourier transform and four automated expert systems were trained: Fisher's linear and quadratic discriminants, a SVM, and a feedforward ANN. The ANN reached the highest performance, achieving 92% accuracy and 0.0921 ± 0.0098 error rate.

Driver's drowsiness detection
A relevant application of ANNs in the context of SAHS is the detection of drivers' fatigue and/ or drowsiness, which is an important issue for patients suffering from SBD. In this regard, different physiological signals have been used to monitor alertness, such as spectral analysis of HRV (90% accuracy) [85] and EEG (0.913 ± 0.027 correlation between actual and estimated alertness levels) [86], wavelet coefficients of EEG combined with features from EOG and EMG (97-98% 3-class overall accuracy) [87], and time, spectral, and wavelet features from single-lead EEG [88]. Neuromuscular (EEG, EOG, EMG) and cardiac (ECG) signals have been analyzed predominantly in order to detect drowsiness, though additional physiological recordings (oximetry, skin conductance), physical measures (eye movement/blinks, face and mouth images), and driver's performance measures (steering wheel movements) have been also proposed as inputs to different pattern recognition methods, specially Bayesian networks, SVMs, and ensembles of linear classifiers [89][90][91]. The main limitation of these automated algorithms is that a great amount of data is needed to perform an accurate training of the pattern recognition method. Nonetheless, alertness monitoring systems are already incorporated in many high-end vehicles.

Neural networks and continuous positive airway pressure
The incorporation of automated decision support systems in the common clinical practice of SAHS diagnosis is still very limited. Conversely, the implementation of artificial intelligencebased expert systems in treatment devices for sleep-related breathing disorders therapy increased significantly during the last decade. In this regard, the exponential technological development of continuous positive airway pressure (CPAP) devices relies on the automated analysis of breathing patterns by means of expert systems, most of them based on ANNs. Currently, CPAP is the primary preferred treatment of mild, moderate, and severe SAHS and thus it is considered the standard of care. During CPAP treatment, a continuous pressure of air is delivered to the patient's upper airway to keep patency [92]. Though nonintrusive, simple, and effective, the device delivers an unnecessary constant high pressure during the whole night whatever the actual patient's needs, which decreases comfort and in turn treatment compliance. This is the main limitation of CPAP and thus the most relevant improvements during the last years focused on the modulation of the pressure delivered by the device in order to fit patient's needs. In this regard, the major companies operating in the SAHS therapy market incorporated to their devices automated algorithms to monitor and modulate the breathing gas pressure. Nevertheless, most manufactures provide no technical data about the design and implementation of their automated signal processing algorithms and thus they are blackboxes hard to interpret and assess.
As aforementioned, determining the optimal therapeutic pressure has been a major goal of research regarding CPAP treatment. Different respiratory-related signals have been assessed for automated regulation of the pressure. Airflow, SpO 2 from oximetry, HRV, pharyngeal wall vibration, and snoring sounds have been involved in automated algorithms aimed at detecting airflow limitation and respiratory events. Among them, the analysis of the airflow profile is the most widely used method [93,94]. In this regard, several algorithms have been patented during the last years, which reflect the increasing interest of leading companies in this field. In the patent by Norman et al. [93], a pretrained ANN fed with shape-based features from the airflow signal is used to detect the presence of airflow limitation in each individual patient's breath. Eklund et al. [95] granted a patent for automatically adjusting the flow pressure when respiratory events are detected. To achieve this goal, an ANN is fed with respiration-related variables. In a recent granted patent, Waxman et al. [96] proposed a Large Memory Storage and Retrieval (LAMSTAR) neural network to process patient's physiological data in order to predict breathing events and control the airway pressure level supplied to the user. This algorithm reached high prediction ability within the 30 s preceding the respiratory event [96]. Similarly, in the patent by Hedner et al. [97], the authors describe a pattern recognition system based on a plurality of ANNs aimed at controlling the therapy breathing support in order to increase its effectiveness. Leading companies, such as Philips Respironics, ResMed, or Fisher & Paykel, incorporated these algorithms into their CPAP devices. Nevertheless, additional research is still needed to further assess whether these technological advances can effectively improve CPAP adherence.
Automatic detection of wake and sleep states is a novel approach for enhancing patient's comfort [98,99]. In the study carried out by Ayappa et al. [98], the authors proposed an ANN to detect irregular respiration characteristics of sleep/wake transitions. In this study, the CPAP flow signal is parameterized by means of breath timing and amplitude measures, which subsequently feed the ANN in order to detect irregular breathing. This algorithm is used in the commercial system SensAwake TM (Fisher & Paykel, Auckland, NZ) in order to automatically decrease the therapeutic pressure when the patient is awake [99]. This ANN has demonstrated to be effective for sleep onset and awakening detection, though there is still little if any evidence supporting its actual long-term influence on patient's comfort and CPAP compliance.
In order to obtain the optimal CPAP pressure level for a patient, an individual titration procedure is needed. This technique is aimed at estimating the continuous pressure that normalizes the patient's sleep and breathing during in-lab PSG, which contributes to increase the large waiting lists. Therefore, alternative methods are demanded. In this regard, El-Solh et al. [100] designed and trained a GRNN aimed at estimating the most effective continuous pressure using demographic and anthropometric variables (those from the Hoffstein formula, i.e., age, gender, BMI, neck circumference, and AHI). The authors reported high agreement between the optimal pressure determined by standard titration during overnight PSG and the pressure predicted by the ANN. In a later randomized study, El-Solh et al. [101] reported that this ANN can be effectively used to guide CPAP titration. The authors showed that automated titration procedures using this methodology reached the optimal CPAP pressure at a shorter time interval compared to conventional PSG-based titration, as well as lower titration failure.

Conclusion
Researchers carried out an exhaustive study during the last decades focused on the design of automated expert systems derived from artificial intelligence able to help physicians in their daily practice. Accordingly, several computer-aided decision support systems have been proposed to overcome limitations of the standard diagnostic methodology for SAHS. Among all the automated prediction methods, ANNs are probably the most widely used pattern recognition algorithm in the context of SAHS management. Their flexibility to model complex nonlinear problems and their higher generalization ability allow ANNs to reach higher performance rates both in classification and regression problems. In this regard, several applications of ANNs have been developed, such as classification of patients suspected of suffering from SAHS, AHI estimation, detection and quantification of respiratory events, apneic events classification, automated sleep staging and arousal detection, alertness monitoring systems, and airflow pressure optimization in PAP-based devices. On the other hand, the most common limitation of ANNs relates to the interpretation of the results in terms of the significance of the variables involved in the model. In this way, ANNs are most times viewed as blackboxes that are not able to generate understandable rules, which is the main weakness of neural-based classifiers. Conversely, both decision trees and probabilistic networks also reach high performance by providing interpretable rules and relationships between input variables.
Regarding input features, ANNs are able to deal with high-dimensional spaces composed of several features. This is especially useful when working with a lot of data sources providing information about the problem under study, such as symptoms reported by the patient, physical examination, sleep questionnaires, or PSG, among others. However, it is important to highlight that, sometimes, researchers try to compose a wide initial feature set in order to gather as much information as possible, including features from signal processing algorithms regardless of their relevance or clinical meaning. In this way, feature selection strategies are very useful to distinguish the more significant ones. In addition, dimensionality reduction algorithms allow ANNs to deal with the curse of dimensionality problem and to control overfitting. Nevertheless, just a few studies apply feature selection techniques before the classification stage.
ANNs have yielded reliable and accurate applications in the context of SAHS detection. Nevertheless, it is noteworthy that, in the last years, there is a trend to use different pattern recognition algorithms, particularly SVMs and ensemble classifiers. SVMs have emerged as powerful tools able to achieve significantly high performance both in classification and regression problems. They are kernel-based maximum margin classifiers, i.e., the decision boundary is determined by a subset of the training data samples in a transformed space in which the margin (the distance between the boundary and the closest samples) is maximized. In this way, the optimization problem is relatively straightforward [18]. Several recent studies have demonstrated the usefulness of SVMs in the framework of SAHS management [102][103][104][105]. Moreover, in the present research, some studies were reviewed reporting that SVM-based classifiers reached higher accuracy than ANNs [23,45,52]. Unlike ANNs, SVMs are capable to minimize both structural and empirical risk, leading to higher generalization ability even when working with limited training datasets [103]. On the other hand, they are also characterized as blackboxes and usually higher computational time is needed to optimize the classifier [27]. Unfortunately, there are few studies assessing the performance of different classification approaches in the same conditions (population under study and equal optimization of input parameters), leading to biased results and poor generalization. Open access databases, such as the Physionet or the Sleep Heart Health Study (SHHS), provide a common benchmark to properly assess the performance of different methodologies using the same data. Nevertheless, these databases are limited and most studies are carried out using no publicly available datasets, which restricts comparisons.
In addition, it is also noteworthy that ensemble classifiers, from the simplest majority vote to the more complex bagging, boosting, and stacking algorithms, have been recently introduced in the context of SAHS in order to improve classification performance [106,107]. It is obvious that misclassified samples are not always the same when using different classification algorithms. Accordingly, improved performance may be reached when working with several classifiers at the same time. In this way, ensemble algorithms take advantage of the information provided by all the classifiers involved in the classification or regression task. The studies by Guijarro-Berdiñas et al. [59] and Nguyen et al. [52] demonstrated the reliability and efficacy of ANN-based ensembles. Nevertheless, further research is still need in order to exploit the full potential of this approach in the context of SAHS diagnosis.