The heart rate (HR) is a widely used clinical variable that provides important information on the health status as it is also related to the individual’s blood pressure [
1]. For example, a large continuous increase in blood pressure, which in turn leads to an increase in HR, may be a risk factor for primary hypertension or a symptom of coronary heart disease [
2]. In addition, there are also studies showing that to maintain the resting HR at values substantially lower than the tachycardia threshold, traditionally defined as between 90 and 100 beats per minute (BPM) is advisable [
3], despite the difficulty of defining the optimal HR for each individual.
On the other hand, the photoplethysmography (PPG) signal can be used to detect blood volume changes in microvascular tissue [
4] and is often used in a non-invasive way to make measurements on the skin surface. This technology is integrated into a multitude of medical devices to measure oxygen saturation, blood pressure, or cardiac output, as well as to evaluate the autonomic nervous system activity and to detect peripheral vascular diseases [
5]. The PPG measurement requires only a few optoelectronic components: a light source to illuminate the tissue (i.e., the user’s skin) and a photodetector that measures the small variations in light intensity associated with changes in blood volume. However, the interaction of light with biological tissue is very complex and includes optical processes of scattering, absorption, reflection, transmission, and fluorescence [
6]. Therefore, it is not so easy to isolate the desired component in the PPG wave. In addition, the wavelength of the light source is also important in the interaction with the tissue [
7]. Tissue is mainly composed of water that strongly absorbs light in the ultraviolet range and in the longer infrared wavelengths. However, there is a range in the absorption spectrum of water that allows the visible red light and the shorter wavelengths of the infrared range to pass more easily through the tissue, and thus blood volume can be measured at these wavelengths. For this reason, red or short infrared light sources are often used for PPG measurement [
8]. Moreover, the wavelength also determines the depth at which the light penetrates the tissue, as the intensity of the optical radiation depends on it [
9].
On the other hand, the autonomic nervous system is one of the main systems in the human body for maintaining the homeostasis [
10]. The activity of the sympathetic system increases when a person is faced with changes or stressful situations. However, the parasympathetic activity increases during rest and relaxation [
11]. The HR is controlled by modulations of both the sympathetic and parasympathetic systems [
12], mainly influenced by a person’s circadian rhythms to maintain the homeostasis [
13]. Consequently, in addition to the physiological conditions of the person and their circadian rhythms, the interaction with the environment and the psychological state of the person affect the balance of the autonomic nervous system, and this will be reflected in the user’s HR [
14]. Therefore, HR provides information for predicting changes in the user’s state, especially for people who are so affected by stimuli and changes.
Background
People with ASD suffer from sensory sensitivity problems that affect their behavior, attention span, and social interactions [
15]. Therefore, measuring their HR can help to detect changes in their state that may be caused by the presence of a negative stimulus in the environment. In addition, people with ASD are very reluctant to use foreign bodies, so the use of invasive systems, such as electrodes, for the measurement of physiological signals, such as HR, is not recommended as these devices will be difficult for people with ASD to tolerate them. Thus, the use of PPG for the acquisition of the HR in people with ASD could be useful because it is less invasive in the person’s space and in terms of the simplicity of the measurement.
However, the PPG signal contains more information than is desired to extract, in addition to noise. The PPG signal has two main components, a pulsatile component attributed to cardiac changes in blood volume, and a slowly varying basal component attributed to respiration, sympathetic nervous system activity, and thermoregulation. The pulsatile component is often referred to as the “AC” component, due to its oscillatory behaviour-like AC power, and its fundamental frequency depends mainly on the HR, while the basal component is referred to as the “DC” component, due to its basal behaviour-like DC power, because it varies very slowly as its contributors have a lower frequency [
16].
Figure 1 shows a picture of a PPG sensor placement on the user’s wrist and its working principles. It can be seen how the emitter sends the light pulses, and, after a series of optical phenomena, the light is reflected onto the photoreceptor. A schematic of the two components, described above, composing the PPG signal is also shown in
Figure 1.
Due to the sensitivity of the PPG signal to the movements of the user’s arm, wrist, and fingers, when the user is performing tasks that involve constant movements of any of these parts, the PPG signal is corrupted and therefore the HR computed starting from the raw measurements significantly deviates from the real value [
17]. The shown PPG sensor uses reflection detection. This principle is described by the Beer–Lambert law [
18], from which the PPG measurement is defined in Equation (
1), where
and
are the input and the reflected output intensities to the skin, respectively;
represents the reflection/absorption coefficient of the different tissues;
c is the concentration of the different tissues; and
d represents the path length of the reflected light. Therefore,
and
d depend on the wavelength of the light, while
c and
d may vary in time if movements occur.
According to Equation (
1), there are thus two main sources of the motion artifacts: on the one hand, the displacement of the sensor relative to the skin (Mmec), which causes a change in the angle of incidence and the light path and which would correspond to the
d term in Equation (
1). On the other hand, the internal deformation and structural change of certain tissues due to finger movement (Mvascular), which produces an artifact in the signal and which would correspond to the c term.
Figure 2 shows a simplified model of the previous point, where it is shown that the total motion artifacts are the sum of the artifacts caused by the displacement of the sensor and the artifacts caused by the changes in the microvascular tissues due to the movement of the fingers.
In the literature, several works present solutions for the removal of motion artifacts in the PPG signal. One of these solutions is explained in [
19]. It proposes an algorithm for the removal of motion artifacts with the use of multiple PPG sensors with different wavelengths, one of them green, which will be in charge of measuring the user’s PPG signal, and another infrared, whose signal will be used as a motion reference. The proposed method performs a motion removal process based on the continuous wavelet transform (CWT), followed by HR estimation and signal reconstruction. The authors show results with low mean absolute error (MAE) in healthy users performing different activities with low physical intensity. Another work using different wavelengths is the one carried out in [
20]. The authors propose the use of four sensors oriented in different directions that also have multiple PPG channels: one red, one green, and one infrared. In addition, a magneto-inertial measurement unit (M-IMU) is also incorporated to acquire the acceleration signal. When small or no motion is present, the HR is calculated from the PPG signal of the green sensor. In the case of motion, the PPG signal will be a mixture of the different sensors, which are oriented in different directions and measure different depths depending on the wavelength. An independent component analysis (ICA) algorithm is used to extract the pulsatile component of each sensor. Lastly, the FFT is applied to the component with the largest mean value to find the HR.
On the other hand, solutions based on the use of accelerometers to remove motion artifacts are also presented in the literature. In [
21], a method that combines HR estimation with notch filtering is proposed. First, an adaptive least mean square algorithm (LMS) is applied to perform noise cancellation, which preliminarily reduces motion artifacts by using the acceleration signals of the three axes (x, y, and z) together with the PPG signal. Lastly, a notch filter is applied to subtract the frequencies associated with motion artifacts from the frequency response of the PPG signal, obtaining a separate noise-free signal. Similar work is carried out in [
22]. The authors present a new algorithm based on spectral subtraction. For this purpose, the spectral component of the motion artifacts is estimated from the acceleration signals of the three axes (x, y, and z), and these components are removed from the frequency response of the PPG signal. This removes the peaks in the frequency response caused by the motion artifacts.
An alternative approach to the previously described techniques is the use of machine learning (ML) for HR detection from a PPG signal. ML can outperform adaptive filtering techniques due to its ability to learn autonomously, its ability to generalize to previously unseen data, its possibility to handle complex and non-linear features relationships, its flexibility in feature selection, and its scalability for large volumes of data. The work presented in [
23] proposes the use of supervized learning using neural networks to face the problem without the need to use acceleration signals. Different peaks within the frequency spectrum of the raw PPG signal are selected, and a probability that each peak corresponds to the HR peak is assigned. Then, features are extracted and selected to train a three-layer neural network with 22 neurons in the hidden layer that will be in charge of estimating the HR value. Another work using ML techniques is [
24]. It proposes the use of a four-layer deep neural network, two of which are convolutional neural network layers, together with two long short-term memory (LSTM) layers, followed by a dense output layer acting as a single-neuron regression layer, to predict the HR value from the PPG signal.
This paper is organized as follows. The Materials and Methods section describes the experimental setup and the proposed algorithm.
Section 2.1 presents the used setup to obtain the HR by means of the PPG in people with ASD. In
Section 2.2, a procedure to approach the identified problem is proposed.
Section 2.3 explains the protocol for signal acquisition and processing to train the predictive models of the algorithm.
Section 2.4 and
Section 2.5 detail the training process of the classification and regression model, respectively.
Section 2.6 describes the final architecture of the proposed algorithm.
Section 3 shows the results obtained with several users in the validation stage of the algorithm. Lastly, in
Section 4 and
Section 5 the obtained results are discussed and the conclusions of the paper are outlined.