From Frequency Content to Signal Dynamics Using DNNs

This study developed a novel method for analyzing and decomposing a signal into its main dynamics for small and large timescales. Our proposal is based on a decoupled hybrid system of convolutional and recurrent neural networks that uses as inputs the power spectrum and spectrogram of a given signal, giving as output the dynamic behavior. We define the dynamic classification predicted of the signal using previously known dynamics characterized through training signals: periodic, quasi-periodic, aperiodic, chaotic, and randomness. We created a synthetic dataset comprising more than 50 training signals from different categories. For the real-world dataset, we used photoplethysmographic signals from 40 students obtained from a Spanish medical study. We tested the developed system’s performance in real biological and synthetical signals, obtaining noteworthy results. All the results are evaluated qualitatively and quantitatively. Still, given the novelty and the lack of similar works, we cannot compare reliably and rigorously our results with other works, at least quantitatively. We can retrieve from the exposed results in this work three key ideas: the DNN-based solutions are capable of learning and generalizing the dynamics behavior of signals; the proposal learned correctly to distinguish between the reference dynamics provided and find some unidirectional similarities in the aperiodicity cases; and the results obtained using real-world PPG signals reveal that biological signals seem to exhibit a multi-dynamic behavior that changes depending on the used timescale, being quasi-periodically dominant in the short-term and aperiodically dominant in the long-term.


I. INTRODUCTION
In recent years, the theory of nonlinear dynamical systems has gained momentum in the scientific community with chaos theory, sensor technology, and increasing computational power. The acquisition and analysis of vast amounts of data are already a reality. Understanding signal dynamics makes it possible to conjecture the mechanisms that trigger its generation and develop mathematical functional models that increasingly support more reliable reproductions and predictions. Among the data sources that have been the subject of The associate editor coordinating the review of this manuscript and approving it for publication was Ludovico Minati . dynamic studies are medical imaging and volumes [1], voice signals [2], radio signals [3], and, more specifically, biological signals, such as the EEG [4], [5], ECG [6], EMG [7] and PPG [8], [9], [10], the latter being the focus of this work.
In the context of physiological systems, the dynamic evolution of their biological responses has become particularly interesting in the last decade, mainly because nonlinear analysis tools have allowed the early diagnosis of pathological diseases or premature somatic disorders [11]. The multidimensional nature of biological signals involves nonlinear dynamics that combine deterministic and stochastic components [12]. The intrinsic complexity of inextricable coupling between multiple subsystems that comprise physiological VOLUME 10, 2022 This work is licensed under a Creative Commons Attribution 4.0 License. For more information, see https://creativecommons.org/licenses/by/4.0/ systems is a bottomless source of physiological information [13], [14], [15]. The dynamic richness of biological responses is a hallmark of the ability to functionally adapt to the organic needs of an unstable environment [16]. In this work, we primarily study PPG signal dynamics; this signal is easily accessible by a pulse oximeter and is a source of physiological information related to the cardiovascular system [17]. The PPG technique, an acronym for photoplethysmogram, dates back to the American physiologist Alrick Hertzman in the 1930s [18]. Hertzman devised a photoplethysmograph, which he described as a device that uses light absorption by transilluminated tissue to estimate blood volume. It is possible to record variations in the peripheral blood volume with each heartbeat using this optical technique [19]. The PPG signal, while seemingly simple, contains dynamic subtleties that make it extraordinarily complex. The PPG signal contains relevant physiological information that is not limited to heart rate or blood oxygen saturation and is broadly representative of clinical settings [20]. This optical monitoring technique has become a common diagnostic tool for some diseases, such as hypertension and coronary artery disease, because of its electronic simplicity, cost-benefit ratio, ease of signal acquisition, and above all, its noninvasive nature [21]. Technological advances have made it possible to easily access experimental data by observing natural and biological phenomena. New mathematical analysis techniques have been translated into computational algorithms capable of deciphering dynamic behaviors and, perhaps more interestingly, their temporal variations or, in other words, their dynamic variation with timescale. Over time, various dynamical behaviors have been typified, from the most regular, such as pendulum motion, to the most random, at the atomic level, in agreement with the laws of quantum mechanics [22]. Within these two ends of the spectrum, there is a whole range of processes that, as they approach true randomness, enhance their dynamic complexity in terms of the unpredictability or variability of repetitive patterns [23]. Future research may reveal new behaviors in dynamic systems. In either case, real-world processes often exhibit the mixing of different behaviors at different timescales. Dynamical transitions uncover modulation mechanisms of biological rhythms that faithfully reflect an individual's physiological state in the case of dysfunctional disorders. Therefore, analyzing the nonlinear dynamics present in a biological signal can be a paradigm shift in modeling the physiological processes that originate from it.
The attempt toward a unifying framework for the differentiation of dynamic behavior has been reflected in an excellent work by Toker et al. [24]. However, the automatization of the dynamic identification process is reduced to discriminate, with certain variations, between chaos and non-chaos according to a whole tool kit from nonlinear time series analysis. In the case at hand, as far as we know, few research works have endeavored to resolve the dynamic richness hidden in biological signals, and even less at different timescales, particularly as concerns the PPG signal [25], [26], [27]. Some approaches directly tackle the modeling of the morphology of the PPG signal [28], [29], [30], [31], [32]. In previous work, we looked at the behavior of the PPG signal dynamics from a stochastic perspective by modifying the 0-1 test [10]. We also carried on with the study of its chaoticity level using methods based on DNNs [9].
This study aimed to evaluate the dynamic composition of the PPG signals. Future work will be the same with other biological signals, given the clinical interest in understanding the underlying physiological mechanisms that give rise to the dynamics of each biological signal in question. The originality of our proposal lies in the use of deep neural networks (DNNs) that use the power spectrum and spectrogram of reference signals to approximate the dynamics present in the input signal. The DNNs learn the dynamics in a supervised manner using reference signals. The reference signal's database compiles 60 different signals divided by categories. They are periodic, quasi-periodic, aperiodic, random, and chaotic signals. Many reference signals allow a complete dynamic study of the PPG signals, achieved in previous work with a less exhaustive demonstration [9]. Once the DNNs retain the dynamical singularities of the reference signals, the system provides a combined (mixed) dynamical characterization of the input signals on large and small timescales. In the field of PPG signals, previous studies have used similar classification systems to detect cardiovascular pathologies based on features extracted from the time domain [33].
The remainder of this paper is organized as follows. Section II describes the databases used to train and test the system, the proposed neural network, its architecture, and the training process. Section III presents the obtained results, both graphically and numerically, for various experimental settings and analyzes and interprets the obtained results. Finally, in Section IV, we briefly outline the conclusions drawn from this study and suggest future research directions.

II. MATERIALS AND METHODS
Subsection II-A includes the data to train and check the DNN system proposed, reference signals, and biological data to study real-world PPG signals. Subsection II-B describes the newly proposed method for dynamic behavior classification based on DNN. Subsection II-C describes the main parameters employed on the DNN-based system as a full system architecture.

A. DATASETS
This section describes the databases used for the dynamic identification of biological signals. On the one hand, the synthetic database with all the reference signals will train and validate the neural network, encapsulating the dynamic essence of a characteristic behavior: periodic, quasi-periodic, aperiodic, chaotic, and random. The database had ten different signals to account for fine subtleties in the specific behavior of each reference signal (cf. § II-A1). By contrast, a database of real-world biological signals (cf. § II-A2) acquired from a nationwide project experiment to identify acute emotional stress biomarkers is used to evaluate its dynamic behavior. From all biological signals recorded experimentally in this pilot project, only the dynamic behavior of the PPG signal is reported. Following the master research line, we aim to infer the physiological mechanisms governing and regulating the hemodynamics driven by the cardiovascular system from the PPG signal dynamics.

1) REFERENCE SIGNALS (SYNTHETIC DATASET)
To date, no unambiguous criteria clearly define complexity [23], [34]. Complexity is a system with multiple components interacting inextricably [35]. In physiological systems, different organic functions involve numerous active and coordinated organic components at different spatiotemporal scales, ranging from cellular to visceral. Because it is practically impossible to dissociate the functionality of each part concerning the whole, a reasonable proposal is to evaluate the time response of the constituent parts' joint (macroscopic) action. Thus, physiological system behavior varies between regular (periodic) and very irregular (random) dynamics. However, a meaningful measure of complexity moves between these two ends, where the system exhibits a greater exchange of information in cross-coupling its components. The structural richness of the coupling can be quantified using different thermodynamic complexity measures, such as those based on information theory [12]. In this sense, a previous step was identifying repetitive temporal patterns that encode their dynamic variability through a quantitative measure.
The primary purpose of this study is the dynamic typification of the repetitive patterns present in the PPG signal according to five major dynamic categories, as stated earlier in a preliminary work [9]. Future studies will expand the dynamic classification of other biological signals. The dynamic typology includes periodic dynamic behavior (the most regular) and random dynamic behavior (the most irregular or erratic) through intermediate behavioral regimes, such as chaotic, quasi-periodic, and aperiodic. The latter, in turn, is broken down into two sub-classes: open aperiodic behavior, without any particular constraints, and specific aperiodic behavior, associated with strange nonchaotic attractors (SNAs) [36]. As regularity is lost, the degrees of freedom increase until, eventually, even losing determinism as it occurs with random dynamics.
Ten different signals were set up for each dynamic category and generated analytically. All signals retained a similar behavioral pattern in each category but with heterogeneous structural and temporal variations. The generated signals contain 150,000 points or observations (samples). Their dynamic congruence was verified using a previously formulated procedure [10]. The spectrum of dynamical behaviors could exhibit most of the dynamical behaviors found in the phenomena of the natural world, except for the fruitful dynamism present in the dynamical transitions between stable regimes. A representative example of each dynamic reference category is shown in Fig. 1, with the categories ranked in the order of decreasing regularity-periodic, quasi-periodic, aperiodic, chaotic, and random-.

a: PERIODIC SIGNALS
Periodic signals have a strictly repetitive regular pattern for every specific fixed and finite time, known as a period. Unlike the previous study [9], in which we used a basic triangular cycle that included a discontinuity, we generated ten periodic signals (see Fig. 1a for a representative sample) from parametric analytical models because many of them have a dynamic equivalent in the real world.

b: QUASI-PERIODIC SIGNALS
Quasi-periodic signals showed a seemingly repetitive pattern, irregular periodicity, and dynamic recurrence. If the data precision is infinite, the pattern never repeats, and its dynamics run along a tori in the phase hyperspace.
Biological regulation is a vital sign of organic homeostasis. Physiological systems are forced to continually rebalance themselves according to their organic demands at any given time. Therefore, it is hardly surprising that many biological signals show nonlinear oscillations at small timescales that are not strictly periodic but rather quasi-periodic, as with the PPG signal. Based on the PPG signal, we investigated whether these deviations from periodicity are due to nonlinear deterministic dynamics-chaotic or nonchaotic-or nonlinear stochastic dynamics. Both cases stem from nonlinear coupling at large timescales of the multiple systemic components involved in the organic re-equilibrium.
Ten quasi-periodic signals were generated based on continuous and discrete parametric models (see Fig. 1b for a representative sample).

c: APERIODIC SIGNALS
An aperiodic signal has non-self-similar repetition, even with infinite precision data. The opposite of a periodic signal is an aperiodic signal, although mathematically, it can be considered a periodic function with an infinite period. Aperiodic signals do not have only one particular frequency. Instead, they spread over a continuous range of frequencies.
However, the diversity of aperiodic behaviors from a physiological perspective has yet to be explored. In recent years, dynamic transitions in complex systems have attracted the attention of physicians and clinicians. A pathological state or aging leads to greater dynamic regularity (physiological rigidity) than a healthy state where dynamic hatching is greatest in chaos [35, and references therein].
Twenty aperiodic signals are generated to cover the greater dynamic structure of aperiodic behavior. Ten correspond to no apparent well-defined dynamic structure (see Fig. 1c for a representative sample)-we have called these aperiodic (pure) signals-and ten fall into what is called strange nonchaotic attractors (SNAs) (see Fig. 1d for a representative sample) [36], [37], [38], [39]. SNAs are particularly interesting in the context of PPG signals because most known SNAs result from quasi-periodically forced dynamics, which are also characteristic of PPG signals at small timescales. This forcing causes a dynamic transition to chaotic behavior. During this transition, the dynamics are chaotic-like and yet predictable in time. It has an aperiodic fractal dynamic. However, they do not satisfy the dependence property sensitive to initial conditions [39], which is the distinguishing feature of deterministic chaos.

d: CHAOTIC SIGNALS
The characteristic footprint of chaotic behavior is the sensitivity of certain deterministic functions for small changes in the initial state. The initial uncertainty-an arbitrarily small change or perturbation-grows exponentially with time, and it is impossible to predict the system's final state after the observation period begins [40]. Ten known chaotic signals (see Fig. 1e for a representative sample), including timedelayed systems, have been generated since many real-world systems, such as the cardiovascular system, utilize nonlinear delayed control loops in their self-regulation process [14].

e: RANDOM SIGNALS
Random signals also called stochastic signals, contain uncertainty in their parameters [41]. Because of this uncertainty, a precise mathematical relationship cannot describe a random signal. Instead, the signal value may be expressed only in certain describable probabilities of occurrence at a particular time. Thus, a continuum of frequencies can be used to characterize the function [42]. More precisely, random signals are non-deterministic and are, therefore, most often analyzed using statistical techniques that require the treatment of the random parameters of the signal with probability distributions [41]. Ten random signals (see Fig. 1f for a representative sample) were generated by combining different probabilistic distributions, including not in all cases, linear and nonlinear correlations.

2) REAL-WORLD PPG SIGNALS (BIOLOGICAL DATASET)
This paper focuses only on a single biological signal, the photoplethysmographic (PPG) signal; future publications will describe the results for more biological signals. The PPG signal was chosen because it is easily accessible through a pulse oximeter. The information provided allows us to monitor vital physiological signs, mainly about the cardiovascular system and, overall, the cardiorespiratory system. In its original version, the pulse oximeter is an optical device for detecting blood volume changes in the microvascular bed of tissue, in our case, the middle finger of the left hand. Today, selfcare, a culture that improves the quality of life and promotes the sustainability of the healthcare system, encourages the widespread use of wearable pulse oximeters for home healthcare. New genera of pulse oximeters, such as contactless, aim at better ergonomic fitting to daily life events. The medical device industry is committed to getting out of the hospital and improving the population's quality of life through personal self-diagnosis at home. New pulse oximeters and PPG-based biomedical applications will likely emerge shortly, with more thorough screening for the patient's physiological condition. For a review of biomedical applications and PPG meteoric advancement PPG in health monitoring, the reader is referred to the works of John Allen [43] and Toshiyo Tamura [44], respectively, and most recently, an extensive compilation of significant contributions edited by Panicos Kyriacou and John Allen [45].
A better understanding of PPG signal dynamics would reveal the intricate physiological mechanisms involved in the cardiovascular system, facilitating biomedical applications for a more accurate early diagnosis of possible cardiorespiratory pathologies. The PPG signal is complex. It is composed of a peripheral pulse synchronized to each heartbeat (AC component of the PPG signal) and modulated by a quasi-DC component. The quasi-DC component varies slowly owing to respiration, vasomotor activity, and vasoconstrictor waves [46]. As we will show later, the mutual coupling between the components is intricate and operates at different timescales to regulate the blood volume based on physiological needs. The dynamic transition between small and large timescales encloses the entire structural frame that explains the dynamic modulation of the heart rate to safeguard the functional homeostasis of the body smoothly. The transfer of information from large to small timescales can uncover a natural self-organizing mechanism and an efficient mechanism for conducting or releasing energy (heat transfer).
This database records PPG signals from 40 students, between 18 and 30 years old and non-regular consumers of psychotropic substances, alcohol, or tobacco, selected to participate in a national research study [47], [48]. All signals captured from the middle finger of the left hand and sampled at a frequency of 250 Hz [47], say, sampling time t = 4 ms with the psychophysiological telemetric system ''Rehacor-T'' version ''Mini'' from Medicom MTD Ltd [47]. According to the experimental protocol, we had 40 mins or 600,000 observations or measurements for each PPG signal. Figs. 2a-2b depict, for illustrative purposes, two segments of PPG signals acquired from two randomly chosen individuals, identified as subjects 33 and 37. The seemingly regular sequence of PPG cycles hides variations, in many cases extremely subtle, making the PPG signal a very complex signal inherent to each subject.

B. DYNAMIC BEHAVIOR CLASSIFICATION
This study proposes a classification DNN-based system to infer the dynamic behavior of each signal used from their segments. The proposed CNN uses a decoupled perspective to classify input signal dynamics. As inputs of the general system, the spectrograms and power spectrums of input signal segments are used as a block. The decoupling of the problem allows the classification of simple dynamics using only the power spectrum calculation to make the first general classification. Then, using the spectrogram of the signal segment of interest and those surrounding it, more complex features are obtained, defining erratic dynamics, such as chaotic dynamics. Therefore, we divide the complete system into two subblocks: the coarse dynamics predictor block (cf. § II-B1) and the complex dynamics refinement block (cf. § II-B2).
The complete system receives input time segments of a fixed length of the input signal. It produces a normalized . Complete proposed architecture. The shown figure tries to clarify the connection between the different stages of the system, plotting the Coarse dynamics predictor and the Refine dynamics predictor as yellow blocks. The coarse dynamics stage tries to distinguish between Periodicity, Quasi-periodicity, and what we call others (complex dynamics). At the same time, the Refine dynamics predictor reuses the output of the Coarse dynamics and its output to predict the complex dynamics that represent the ''others'' category, if they exist.
likelihood vector that describes the dynamic behavior of the input segments in terms of the trained dynamics with probabilities ranging from 0 to 100%. It is important to note that the complete system takes care of the full range of previously explained dynamics, but the used sub-blocks divide the proposed task. The coarse dynamics predictor block uses the most straightforward cases to discern between periodic or quasi-periodic behaviors and others (two types of aperiodic, chaotic, and random behaviors). This first analysis helps to discern between simple dynamics to refine the prediction. The complex dynamics refinement block uses previously determined features and information to constrain the remaining dynamics. This block adds the time variable to the prediction using spectrograms to add more complex features to the system in a normalized domain. The entire system decomposes the signal within the full range of dynamics. A schematic of the entire system is shown in Fig. 3.
It is important to recall that the analysis of the dynamics of time series using DNNs is not usually studied by the scientific community, as far as the authors know, but from other perspectives [10], [26], [33], [49].

1) COARSE DYNAMICS PREDICTOR BLOCK
The first CNN proposed the use of a classic 1D encoder configuration that uses residual stages based on the idea stated by He et al. [50]. This type of architecture is widespread in classification tasks, such as regression [51], [52] and indoor localization [53] or other ones [54], [55], [56]. In addition, the first block of the system is a preprocessing custom block that uses the input segments of the signal. It uses the FFT transform to obtain its power spectrum, which subsequently passes to the 1D convolutional encoder that processes the features of the signal spectrum, using them to make the first prediction of the dynamics. Fig. 4 shows a schematic of the proposed block.

2) COMPLEX DYNAMICS REFINEMENT BLOCK
The second refinement block is more complex than the coarse block. This second block processes the spectrograms of the signal; therefore, it needs to process 2D information in the In this case, we can see that the block uses a power spectrum signal as input that we encode using a 1D residual CNN encoder. After this, we use fully connected layers plus Leaky ReLU activations to predict a likelihood vector that helps select between the three main dynamic categories.

FIGURE 5.
Complex dynamics refinement block proposed architecture. This figure centers attention on the Refine dynamics block, showing its architecture and composition in depth. As we can see, to improve the analysis of the Coarse predictor, we provide a long-range analysis of signal frequency context using the spectrograms of the signal around a temporal window. Using these spectrograms along with LSTM cells, this block analyzes the temporal features that define the trend changes, improving the quality of the features provided by the Coarse predictor.
format of spectrograms. To provide an additional context, the block that helps with more erratic dynamics uses three spectrograms of the input signal covering three windows before and after the segment with a 50% overlap. This last procedure helps the network visualize the signal's continuity, and the power of the functions learned over time.
The proposed architecture uses a 2D convolutional residual encoder. It constitutes the time-independent feature extractor that feeds an LSTM layer covering the three input spectrograms over time, ensuring it considers the time context of the signal. In addition to the coarse architecture, the first block performs preprocessing, which in this case finds the spectrogram of the input signal segments. It then passes the spectrograms to a time-distributed convolutional extractor that feeds the LSTM blocks in the different time steps selected, which in this case is three, because there are three spectrograms. The features obtained by the LSTM blocks were combined with those obtained from the coarse block to refine the prediction of the most complex possible dynamics. Fig. 5 shows a schematic of the proposed block and a detailed layer-by-layer network analysis.

C. FULL SYSTEM ARCHITECTURE
This subsection comments on aspects of the full system. Once the input time segment is introduced into the system, it is first processed to obtain the signal spectrum over the frequencies and spectrograms. After the signal is preprocessed, the power spectrum enters the coarse-predictor sub-block, composed of a 1D encoder. The 1D encoder is formed by multiscale residual blocks that obtain the latent space representation L of the input power spectrum. This latent space represents high-complexity features extracted by the encoder through the signal spectrum. The encoder layers are multiscale blocks that capture the spectrum's high-and low-frequency internal variations from a signal point of view. Once the latent space is obtained, these features pass through fully connected layers to obtain the final prediction between the three easier dynamics: periodic, quasi-periodic, and others (aperiodic pure, SNA, chaotic, and random).
When the coarse predictor provides the first classification, the refinement predictor stage process with the spectrograms of the segments 0 − t, −0.5 − t, and t − +0.5 as input passes the spectrograms through a time-distributed 2D convolutional feature extractor to model the complex features extracted through the spectrograms. After extracting the time features, they pass through an LSTM layer that receives the features sequentially in chronological order, considering the time context. Finally, the LSTM features were obtained through the entire sequence of spectrograms. These features were combined with those obtained in the coarse predictor to produce a final feature vector. This vector feeds the final classification of the fully connected layers that use a final softmax layer to predict the dynamics, in these cases, the complex ones. Table 1 summarizes the architecture of the proposed system in detail. The reason for proposing this architecture is that it perfectly fits the problem it is trying to solve and poses an advantageous feature that can help solve it. The main features to comment on are as follows: • Decoupled perspective: The decoupled perspective allows for efficient distribution of the number of filters and network capacity along with the complexity of the dynamics. The first part of the network is a lightweight one that discerns between less complex dynamics, and the second part is a more intensive architecture that uses the previous information of the first part to discern between more complex dynamics.
• Normalized space for inputs: The inputs used were in a normalized space represented by the frequency spectrum or spectrograms, allowing variable signal segments to calculate the network's input. This feature allows us to analyze the used signals in short or long segments, which, in the case of the PPG signal, could mean near a quasi-periodic dynamic or a long aperiodic dynamic, as we showed in previous studies [9].
• Residual and multiscale structures: The residual structures used help alleviate the information loss problem that suffers the deep CNN architectures, a well-known problem, helping preserve all the signal features [57]. In addition, the multiscale structures proposed to capture all the high and low-frequency features of the spectrogram or power spectrum help to define complex and easier dynamics. Recall that providing an accurate prediction of dynamics is vital to preserving all the information across low and high frequencies because the high frequency is fundamental, especially for complex dynamics, and low and medium for any of them.
Section III shows the result of the proposed architecture's capacity test.

1) TRAINING
This subsection explains the training steps for the systems mentioned above. First, all the reference signals created to represent the dynamics of interest and previously explained to train our system were applied. This training must be decoupled and not end to end. First, the coarse dynamics predictor block predicts the easiest dynamics and uses its features in the complex dynamics refinement block that detects the most difficult dynamics. If the reference signals come from the real-world labeled signals, training for classification on a given dynamic is tricky, as they are generally not unique dynamics and can vary due to the effects of the measurement sensor or the environment. In training the network with the synthetic dataset, the data divide into three classical sets of training, validation, and test, with a proportion of 80% training, 10% validation, and 10% test. It chooses this division because the validation and test sets typically range from 20 to 40 percent of the datasets.
Next is defining the essential training characteristics and parameters. 1) Optimizer. It uses an Adam (adaptive moment estimation) optimizer [58]. Adam is used because it combines the advantages and avoids the drawbacks of other previous optimizers such as [59] and [60], which in layman's terms, mean that Adam is an adaptable optimizer that makes use of the first and second moments of the gradient, helping to learn without static learning rates. Despite this, Adam must define the user's first learning rate as a starting point for modification. This adaptation factor helps to avoid unoptimized training, which is a major problem. The initial learning rate was 10 −4 . The networks were trained for 200 epochs with 50 samples and the best-evaluated weights of a validation set. The total training time was approximately eight h with an Intel R Core TM i7-9700K Processor 12M Cache, up to 4.90 GHz. 2) Loss Function. The proposed system uses training composed of input signal spectrums and spectrograms, and output likelihood vectors that classify these signals into dynamics. The proposed loss function for this multiclass classification task is categorical crossentropy, which measures the differences in the classifications between the predicted labels and the ground truth. The classical approximation of this loss is crossentropy (CE), as indicated in (1), namely, the binary classification between the distributions of p(x), the correct one, and the estimated q(x), associating the scores of similarity to the distributions used.
Cross-entropy loss measures the classification performance by assigning score levels between the network inputs and labeled distributions. There is a proportionally inverse relationship between the cross-entropy and prediction score. The ideal classifier had 0 crossentropy and a 100% score. This loss function is necessary to adapt the network outputs in activation because it cannot work with all types of activations. The most commonly used activation is sigmoid in the binary classification case, which outputs a score between 0 and 1. Softmax activation is typically used in the multiclass case because it guarantees a normalized vector of scores that sum 1. In our specific case, it performs multiclass classification, which leads us to use categorical-cross-entropy (CCE) loss, as defined by (2), and the last layer with softmax activation. Combining this loss and the softmax activation allows the previously mentioned output vector to be obtained through optimization, whose sum equals 1. The multiclass classification case implies that all labels are configured in one-hot encoding format, with only the positive class C p in the losses. Only the target element in vector t differs from the zero value t i = t p . By discarding the zero elements, the loss can be rewritten from equation (2) to (3), where C is the number of classes, s j is the score of each class, and s p is the score of positive classes.
Moreover, last is explain how the training is carry-out. First, it must train the uncoupled system, which means that the coarse and refinement predictors are trained separately. The coarse predictor uses the signal spectra obtained from signal segments, with a length of 5,000 samples representing a short timescale or 60,000 samples representing a large timescale. In the case where the refinement predictor is the same as the coarse one, three spectrograms substitute the spectrum. One spectrogram centers on the segment of interest, and the other two cover 50% of the original segment in the backward and forward directions to provide a better temporal context to the network. The training of these CNNs is performed using synthesized reference signals composed of periodic, quasi-periodic, aperiodic pure, strange nonchaotic attractors, and random and chaotic dynamics. Because these CNNs have been designed from a classification point of view, the problem to be solved is a multiclass classification, with five possible classes or dynamic behaviors to find, inferred at the output of the complete system.
All the segments of the input signal used have labels associated, linking these signals with concrete dynamics, which subsequently allows us to recognize multi-dynamics in non-single dynamic signals. It uses randomized training that combines training batches randomly with different dynamics to provide more variability in training. We use 80% of the signals for the training set, equal to 6,000,000 samples, and 20% for validation and testing, equal to 1,500,000 samples. Once the test set, with the reference signals, is applied for training, the system quantitatively evaluates using real-world PPG signals that combine multiple dynamics. This combination implies that it is normal not to obtain pure dynamics in the final results of these signals but, in contrast, to obtain a composite.

III. RESULTS AND DISCUSSION
Different experimental tests allowed us to perform the appropriate operation to correctly identify the different reference dynamic behaviors based on the proposed neural network and a qualitative and quantitative evaluation of the dynamic behavior of a PPG signal at different time scales. Results present both graphically and numerically.

A. REFERENCE SIGNALS (SYNTHETIC DATASET) EXPERIMENTAL PERFORMANCE TEST
To evaluate the accuracy and stability of the proposed DNN system, the DNN trains with 20% of the reference signals such that the network has all the testing dynamics that make up the experiment.
Periodic signals do not pose any problem to the DNN-based classification system. Their recognition is clear, as shown in Fig. 6a. In the case of quasi-periodic signals, the discriminating power of the system is evident, as shown in Fig. 6b.
However, in some intermediate stretches or ranges, it can observe weak dynamic inferences that correspond to the aperiodic behavior characteristics of SNAs. Some quasi-periodic reference signals are quasi-periodically forced systems operating at the boundary that marks the dynamic transition towards an SNA. As seen in Fig. 6c, the system correctly assigns a higher weight (70%) to the aperiodic signal (pure) but does not ignore a dynamic component typical of SNAs totaling 30%. Although both dynamics indeed share common properties as they are aperiodic signals, it can be suspect that the spurious attribution is because some of the pure aperiodic VOLUME 10, 2022 TABLE 2. Validation results with the reference signals. From left to right, the columns are the type of Testing signal, which represents the reference signal trend to evaluate, and Normalized matching-up vector weights, which represent the similarity of the output vector with each one of the considerate dynamic categories. The scores are expressed as a matching-up percentage of reference signals. signals come from the real world, such as speech signals. Real-world signals can contain dynamic traces of SNAs, which can confuse the classification process. In all events, the system assigns a higher dynamic bias to the right aperiodic option, as is also the case in Fig. 6d for the SNA-based aperiodic signals. Likewise, the system does not waiver the chaotic nature of a signal, as shown in Fig. 6e. However, at some short time spans, the system challenges the chaotic dynamics in defense of random dynamics (brief spikes of randomness). The same applies to random signals, where the system occasionally encounters patterns that induce peaks of chaoticity, as Fig. 6f illustrates, although it correctly discerns stochastic dynamics. Dynamical subtleties of the erratic behavior of SNAs, chaotic systems, and random systems entail a challenge in the dynamic discrimination process; however, the discriminating power of the proposed neural network exhibits remarkable performance. Table 2 lists the numerical values of the normalized matching-up vector (target pattern) output that contemplates the success rate of each possible dynamic behavior assigned to the input signal. The available dynamic behaviors are periodic, quasi-periodic, aperiodic (pure), aperiodic (SNA), chaotic, and random.

B. PPG SIGNALS DYNAMIC DISCRIMINATION EXPERIMENT
After confirming the good performance of the discriminant power of the signal dynamics, with validation conducted on the same reference signals, we identified the dynamic content present in the PPG signal at different timescales. As stated in Section II, we used 40 real-world PPG signals from healthy young people aged 18 to 30, complying with the experimental protocol defined by Aguiló et al. [47]. Unless stated otherwise, to avoid high-frequency noise and, to some extent, motion artifacts, all PPG signals are filtered with a simple Butterworth bandpass filter with cutoff frequencies of 0.01 and 15 Hz, as some studies have reported clinical information up to 15 Hz [43], [61].
Previous works first resolved the dynamic multi-scalability of the PPG signal. They embarked on the first analyses to reveal its dynamic complexity at large timescales, far removed from the quasi-periodic character present at small FIGURE 7. PPG signal used timescales. On a small timescale (5,000 points or 20 s), the quasi-regular pacing of PPG cycles can be seen. However, on a large timescale (60,000 points or 4 min), respiration-induced variations come into the dynamic spectrum, such as the intensity fluctuations marked in red.
timescales. As in [9], the timescale is stepped. In such a way, each temporal window encompasses an increasing number of PPG cycles, thus achieving a multiscale analysis mode, as illustrated in Fig. 7. The minimal temporal window for analysis defined the smallest timescale; in our experiment, it was 5,000 points (20 s). The maximal temporal window specifies the largest timescale in this study; in our case, it amounts to 60,000 points (4 min).
Based on the PPG signal complexity and, strictly speaking, the singular and exclusive dynamic variability of each individual, we chose to show in this work the specific results of three users that somehow represent in qualitative terms the dynamic variations found in the total of the analyzed 40 individuals. On a small timescale, the PPG signal shows an unambiguous quasi-periodic pattern owing to the quasi-periodic modulation of the respiratory function on the cardiovascular system, as shown in Figs. 8a-8c. However, depending on the subject, the prevalence of quasi-periodic dynamics is more or less continuous but sometimes truncated, and there are interspersed aperiodic and random episodes.
A dynamic transition characteristic of the SNAs is observed in the case of aperiodic episodes. This suggests that the subject's psychosomatic state, such as an episode of stress or intense activity, could ''quasi-periodically'' force the quasi-periodic dynamics. To the extent of inducing a transition towards a more complex behavior, we are still determining if it would eventually become genuinely chaotic. These brief but intense shocks or bursts temporarily trigger the indices of aperiodicity and randomness and indicate the organism's response to exogenous or endogenous stimuli. It adapts to the new circumstances and presumably restores the quasi-periodic regularity with other conditions once the excess organic requirements have been absorbed.
The dynamic paths are aperiodic on a large timescale, in coherence with the SNA dynamic features, as shown in Figs. 9a-9c. Nevertheless, depending on the individual, there is a certain latent quasi-periodicity, which could indicate the system's capacity to recover more or less quickly the normal operating conditions, which, of course, are governed by the unique characteristics of each individual. The ability to restore the dynamic regularity of the pre-stimulus cardiovascular system, which might be called normal operating conditions, is a key indicator of the biological health of the cardiovascular system.
The dynamic complexity inherent to large scales implies an infinity of subsystems that act simultaneously and without interruption. Including stochasticity as an essential part of the coordination process (we will report on this possibility in a future publication). A physiological system open to the unforeseen contingencies of a constantly changing environment requires flexibility in adapting while minimizing the energy consumption involved in the transition to new organic demands and its subsequent reestablishment. In this sense, the dynamics of an SNA, operating halfway between chaos and a more regular dynamic regime, emerge as a biological solution whose physiological implications are still unknown but deserve further study. Table 3 lists the numerical values of the normalized matching-up vector (target pattern) as the output. This value considers each possible success rate of the dynamic behavior assigned to the input signal. It shows the PPG signals that serve as illustrative examples and the average of all 40 PPG signals that participated in the experiment. The mean values show the prevailing characteristic dynamics of SNAs at the expense of occasional episodes linked to secondary but no less important dynamic trends in the PPG signal dynamic evolution. Because of averaging such a large time window, these dynamic collateral behaviors, whose physiological impact is evident, are masked. Nevertheless, this study reinforces the hypothesis already suggested in previous works [9], [10] of the multi-dynamic (multiscale) character present in the PPG signal. In some way, this dynamic multi-scalability confirms the information transfer from large to small timescales, whereby a wide variety of subsystems contribute to the regulatory mechanisms of the cardiovascular system.

IV. CONCLUSION
This paper proposes a neural network-based dynamic classification system to track the dynamics in signals of various natures at different timescales. We initially tested its effectiveness using a biological signal, the PPG signal, with 40 PPG signals acquired from 40 healthy young individuals.
Future research will extend the analysis to other biological signals and signals picked up from outer space.
The neural network was trained with 60 reference signals covering, in their multiple variants, the most common dynamic behaviors found in nature's physical phenomena: periodic, quasi-periodic, aperiodic (pure), without apparent structure, aperiodic (SNA), chaotic, and random (stochastic). After training the neural network, the classification system can decipher a priori the dynamic composition of any complex signal at different timescales, as proven for PPG signals. The PPG signal followed a predominantly quasi-periodic dynamic trend at small timescales, capturing the dynamic quasi-regular of the heart rate. However, at large timescales, the governing dynamics respond to a singular aperiodic behavior referring to SNAs. The dynamic complexity involving SNAs could explain the physiological mechanism that naturally allows the heart rate to adapt to physiological needs at any given time. The dynamic transition to chaotic behavior-the most complex behavior that preserves determinism in its dynamic evolution-via an SNA stems from quasi-periodic driving.
This work advocates a DNN-based system as an alternative with unprecedented potential for the real-time analysis of the dynamic evolution of signals. For biological signals, such as PPG signals, the early identification of certain dynamic trends would facilitate the early diagnosis of cardiorespiratory abnormalities or stress episodes, to mention a few physiological disorders. Therefore, it is crucial to further refine the classification system with more reference cues that introduce new dynamic phenomenological variants. Moreover, new neural network layers more subtly characterize dynamic transitions between steady states, which are barely perceptible in signal morphology.

INFORMED CONSENT STATEMENT
The study included 40 students from Universidad Politécnica de Madrid (UPM) between ages 18 and 30. All signals were captured from the middle finger of the left hand and sampled at a frequency of 250 Hz; that is, the sampling time t = 4 ms. The UPM Ethics Committee approved the study protocol, and participants provided written informed consent. They were instructed to avoid using any psychotropic substance, alcohol, or tobacco, to avoid physical exercise 24 h before each session, to get up two hours before starting the sessions, and consume a light breakfast without coffee or tea.
JAVIER DE PEDRO-CARRACEDO received the Ph.D. degree in biomedical engineering from the Universidad Politécnica de Madrid (UPM), Madrid, Spain, in 2020.
He is currently a Senior Lecturer with the Departamento de Automática, Escuela Politécnica Superior (EPS), Universidad de Alcalá (UAH), Alcalá de Henares, Spain. His research interests include complex networks, optical bistability, line coding performance, digital chaos generation, nonlinear control, nonlinear analysis of biological signals, dynamic systems, and nonlinear time series analysis. DAVID FUENTES-JIMENEZ received the degree in electronics engineering, the master's degree in electrical engineering, and the Ph.D. degree in artificial intelligence from the Universidad de Alcalá (UAH), Alcalá de Henares, Spain. He works as a Research Scientist with NaturalVox, S.A.U., specializing in face and voice biometry. His research interests include computer vision, signal processing, and data science. He has collaborated actively with researchers in several other disciplines of computer vision and signal processing, particularly in 3D reconstruction, people detection with depth cameras, and signal dynamics. Commission. She has participated in over 30 EU projects so far. Her field of expertise covers a wide range of applications in the domains of ICT applied to different sectors like health and social inclusion, including personalization of services, data interoperability, semantics, and accessibility of ICT. She has co-coordinated the Action Group D4, ''Age-Friendly Environments'' of the EIP on AHA. In March 2018, she co-founded the Biomedical and Health Informatics IEEE women in engineering committee. She has authored more than 100 scientific articles in national and international journals.
ANA P. GONZALEZ-MARCOS is currently a Full Professor with the Departamento de Tecnología Fotónica y Bioingeniería, ETSI Telecomunicación (ETSIT), Universidad Politécnica de Madrid (UPM), Madrid, Spain. She has authored more than 50 publications. Her research interests include, optical computing, chaos theory applied to optical communications, photonic sensors, nonlinear analysis of biological signals, and applications of complex networks to modeling mammalian retina.