This paper introduces an ECG signal detection system based on deep fusion. First, genetic programming-based evolutionary programming was used to solve problems with deep-learning fusion algorithms. In the proposed method, the CNN models used for fusion are coded as genetic programming (GP) programs [
18]. These programs are binary trees whose nodes have embedded deep operators, such as convolution for fusion of ECG leads. During the evolutionary process, these trees evolve and the best variants for fusing ECG lead information are calculated at the software level. Finally, the best sample for fusing leads is extracted. To create an ECG-based detection system, this thesis conducts a full analysis of the ECG signal to maintain the system’s generalization. To this end, the signal’s frequency information is obtained via wavelet frequency conversion, and the similar information is calculated. Because CNN has a convolution filter, it is a model made for images; thus, in this paper, a method for converting the raw ECG signal to an image is presented. Then, signals are converted into images using a mixed conversion and given to CNN trees as frequency information. The proposed system’s performance was evaluated on a dataset of 10,000 arrhythmia patients (Chapman) [
19]. This dataset includes 11 different types of arrhythmias, which are measured with a 500 Hz frequency.
The flowchart of the proposed method is shown in
Figure 2. The innovation of the proposed method to diagnosis arrhythmia using the ECG signal of individuals is based on drawing a trajectory as a figure for each 12-ECG signal leads. Since the ECG signal is periodic, frequency analysis on it can give useful information about this signal. For this, frequency analysis was performed using the wavelet packet transform on each of the 12-ECG signal leads. Then, cross-correlation was calculated between leads 1 to 12 to describe relations between various leads. To extract the ECG signal trajectory, a repetitive pre-processing was calculated on 12 cross-correlation signals, and their spectrogram was extracted. Finally, a trajectory was drawn for these 12 signals, and the output of the trajectory was saved as a figure. These figures are used to produce features as input to the CNN tree. The CNN tree is then developed based on the GP paradigm.
3.4. Feature Learning Using the Evolutionary CNN Tree
It was stated in the previous chapter that the
gene, in the
sample is a mapping function in the form of a CNN tree, which is used to extract the structural features from
signal. The representation of the CNN tree encoded in the
gene, as well as its functions and terminals, will be explained here. The representation of the CNN model in the form of GP trees is addressed in [
20]. This article used a modified version of it per [
20], which utilizes the morphological convolutional functions in this tree, and it is appropriate for QRS complex analysis in the ECG signal.
Figure 6 shows an instance of the CNN tree. As displayed in this figure, the surface of this tree comprises a variety of layers. There is an input layer in the leaf nodes of this tree that receives the
signal as the input. Afterward, there is a morphological convolutional layer, which is normally followed by a pooling layer. In this tree, a node can be a layer of the combination of morphological convolutional/pooling. Before the root layer, there is a concatenation layer. Finally, there is the root layer, which is the output layer. In this tree, the convolution layer carries out the operation of extracting the structural features using the morphological operators, which is fully explained in the next chapter. The pooling layer is used after the convolution layer to reduce the output dimensions of the convolution. Additionally, the concatenation layer connects two input layers together. The output layer is the same as the flatten layer in the CNN, which forms the feature diagram.
Table 1 shows the set of functions used in the CNN tree. First, the functions used to change the numerical space of the features include convolution (Conv), square root (SQRT), addition (ADD), rectified linear unit (ReLU), subtraction (Sub), and absolute (Abs), among which Conv is the most important function. This function is responsible for applying the morphological operators to the input ECG signals. On account of their special geometrical characteristics, the morphological functions, such as dilation and erosion, are capable of perfectly analyzing the complexities of ECG signals, including QRS complex. The morphological operators, such as erosion and dilation, are beneficial for analyzing the shape-oriented signals due to their theoretical framework and lower computational complexity [
21,
22]. The morphological operators, i.e., erosion and dilation, are the restricted form of counter-harmonic mean morphology [
23].
If
is the input signal (
),
shows the coordinates of an entry inside it.
in Equations (2) and (3) is the counter-harmonic mean morphology filter that is expanded as follows.
The ∗ equation indicates the convolution operations, and
shows the kernel function. The convolution operations are formulated in the Conv function as follows using the counter-harmonic mean morphology filter.
The types of the operations of this function are determined with respect to the amount considered for , ( linear, pseudoerosion, pseudodilation).
The Sub and Add functions carry out the weight addition and subtraction operations of two signals based on the weights of and . Two input ECG signals might have different measurements. Thus, the ECG signal will be cut using the aforementioned function to obtain two ECG signals of the same size. The Sqrt, ReLU, and Abs functions are used to change the amount of ECG signal and change the numerical space of the respective sample. In the new networks, the ReLU is preferred over the activating Sigmoid function for hidden layers for two reasons.
First, it is simple and easy to use. Second, it does not cause a local minimum problem. In this function, in the case the input amount is less than zero, the output will be the same as the input, and in the case the input is less than or equal to zero, then the output will be zero. The ReLU function has a fixed derivative for all inputs greater than zero. This fixed derivative accelerates the network’s learning. The Concat1, Concat2, Concat3, and Concat4 functions are used in the concatenation layer, which receives several ECG signals as input and displays them as a diagram in the output. The MaxP function performs a downsampling operation on the ECG input signal. This function can reduce the dimensions of the received ECG signal.
Table 2 shows the list of the terminals and the range of the authorized amounts used for them in the nodes of the leaves of the CNN tree.
The ECG input signal is displayed through the measurement of
. The
,
, and
terminals show the convolution filter and the second input of Conv. Taking into account that the used morphological filter is a matrix in the shapes of a diamond, disk, line, rectangle, square
and
are added to the Sub and Add functions as inputs, and their amounts range between 0.000 to 1.000.
and
are the same size as the MaxP kernel functions. Their amounts will evolve randomly and during execution of the GP algorithm.