# Automatic Modulation and Recognition of Robot Communication Signal Based on Deep Learning Neural Network

Authors: Xiaoguang Zou; Xiaoyong Zou
Journal: Journal of Sensors
 (2022)

---

## Abstract

In order to solve the problem that the traditional method of manually extracting expert features for communication signal recognition has large limitations and low accuracy under low signal-to-noise ratio, this paper proposes an automatic modulation and recognition method of robot communication signal based on deep learning neural network. In this method, the received signal is preprocessed to obtain the complex baseband signal including in-phase component and quadrature component. The signal is used as the data set of the input convolution neural network model. The model structure and the super parameters such as convolution kernel, step size, characteristic graph, and activation function are adjusted through multiple training, and the trained model is used to extract and recognize the features of the communication signal. It realizes the identification and classification of seven types of digital communication signals: 2FSK, 4FSK, BPSK, 8PSK, QPSK, QAM16, and QAM64. The experimental results show that the average recognition accuracy of the seven signals has reached 94.61% when the signal-to-noise ratio is 0 dB.Conclusion. The algorithm is proved to be effective and has high accuracy under the condition of low signal-to-noise ratio.


---

## Body

## 1. Introduction

Recognition of communication signal modulation has a wide range of application requirements in modern wireless communication, and its typical application options are as follows: (1) In noncollaborative communication, the receiver cannot use the communication parameters effectively, especially the modulation mode, because the receiver does not know the sender’s communication parameters. As tracking actions such as demodulation are performed, communication signal modulation recognition is widely used in noncollaborative communication options such as electronic countermeasures, communication intelligence, signal recognition, and electronic control. (2) In the cognitive radio system, it is hoped that the communication receiver will reach the universal level. The receiver will be able to receive the information sent by the sender accurately [1]. Recognition of signal modulation is a key technology in the general receiver model. Only by correctly defining the signal modulation mode can information such as the signal bandwidth of the signal transmitter be calculated more accurately and thus facilitate subsequent operations. By signal demodulation and decoding. Therefore, studies to determine the modulation of communication signals are very important [2]. In today’s increasingly complex environment of wireless communication, the space of electromagnetic signals is becoming more and more complex, the amount of information transmitted is increasing, and signal change is accelerating. Therefore, the study of automatic communication modulation signal recognition in high-speed modulation patterns is of great application [3].In the noncooperative communication system and cognitive radio platform, the automatic modulation identifier of communication signal is a very key system component. The recognition performance of the modulation identifier is related to the normal and effective operation of the whole communication system. In this paper, it is a novel and ingenious method to realize communication signal modulation recognizer based on artificial neural network and graphics processing unit (GPU) platform. It is an innovative idea to combine communication signal modulation recognition with the current hot artificial intelligence technology. Figure1 shows a robot communication control device based on deep learning neural network.Figure 1
A robot communication control device based on deep learning neural network.


## 2. Literature Review

Zhu et al. proposed a modulation recognition algorithm that can effectively recognize BPSK (binary phase shift keying) and QPSK (quadrature phase shift keying) signals from the perspective of average likelihood ratio for the first time. The algorithm estimates the carrier phase offset through ALRT and deduces the log likelihood ratio classification criteria to complete signal recognition [4]. Two years later, on this basis, they studied a quasi-optimized log likelihood ratio recognition algorithm, which further improved the recognition accuracy of BPSK and QPSK signals under the interference of additive white Gaussian noise (AWGN). Li et al. proposed a new PSK (phase shift keying) modulation classifier based on the maximum a posteriori probability criterion, which treats signal amplitude and noise variance as unknown deterministic variables and combines GLRT and ALRT to improve signal recognition performance [5]. Zeng et al. proposed a modulation recognition algorithm based on HLRT for multiple input multiple output (MIMO) scenarios. The algorithm first uses the channel estimation technique based on independent component analysis to estimate the relevant channel parameters, then uses the linear filter based on the minimum mean square error criterion to divide the MIMO channel into several subchannels, and uses the weighted sum rule to recombine the likelihood functions under each assumption to form a global likelihood function, so as to improve the algorithm performance [2]. Liu et al. studied the modulation recognition algorithm when the channel state information is unknown in the multicarrier scenario. First, the energy detector is used to confirm the working subcarriers, then the expectation maximization algorithm is used to estimate the channel state information, and finally, the HLRT function is constructed according to the estimated parameters to realize signal recognition [6]. Although the above modulation recognition algorithms can achieve high recognition rate, compared with the pattern recognition methods based on feature extraction, these algorithms have high computational complexity and are difficult to be applied in practical engineering projects. Therefore, how to reduce the computational complexity of these algorithms is also an important research direction of researchers. Arunkumar et al. studied an automatic modulation recognition algorithm based on normalized sixth-order cumulant. The algorithm simulates the channel propagation conditions in real scenarios. When the channel characteristic information is unknown, it successfully realizes the efficient recognition of BPSK, QPSK, 16QAM (quadrature amplitude modulation), and 64QAM [7].Based on the above analysis, this paper studies a method of combining complex baseband signal with CNN and proposes a CNN model. This method can automatically learn the signal characteristics directly from the data. The model first simulates and generates seven types of modulated signals under different signal-to-noise ratios and then processes the received signals into two channels of complex baseband IQ signals. After preprocessing the signals, the signals are used as the experimental data set. The data set is used to train the CNN model and adjust the super parameters. Finally, the trained CNN model is used to identify and classify the seven types of communication signals. Experiments show that the proposed method has better classification accuracy in the case of low signal-to-noise ratio, and the accuracy of classification and recognition method using convolution neural network after short-time Fourier transform is greatly improved.


## 3. Research Methods

### 3.1. Signal Modulation Model

There are three basic digital modulation modes: multiband frequency shift keying (MFSK), multiband amplitude shift keying (mask), and multiband phase shift keying (MPSK) [8, 9]. The three signals can be mathematically modeled as follows:
(1)sMFSKt=∑i=0N−1A0cos2πfct+2πfit+θ0·gTt−iT,(2)sMPSKt=∑i=0N−1A0cos2πft+θ0+θi·gTt−iT,(3)sMASKt=∑i=0N−1Aicos2πfct+θ0·gTt−iT,wherefc is the initial carrier frequency, θ0 is the initial phase, A0 is the initial amplitude of the carrier, N is the number of observed symbols, T is the symbol period, gT· is the waveform pulse formed in the symbol period, and fi∈f1,f2,⋯,fM is the modulation frequency; Ai∈A1,A2,⋯,AM is the modulation amplitude; 2π/Mm−1,m=1,2,⋯,M is the modulation phase.On this basis, multiband quadrature amplitude modulation (MQAM) simultaneously uses the amplitude and phase of the carrier to modulate the transmission data [10]. The MQAM expression is as follows:
(4)sMASKt=∑i=0N−1Aicos2πfct+θ0·gTt−iT.The general expression of the modulated signal obtained from (1)–(4) is as follows:
(5)st=At·cos2πfct+2πftt+θt+θ0,wherest represents continuous time series signal. According to formula (5), seven modulation models are obtained by changing its frequency, phase, amplitude, or other parameters.


### 3.2. Data Set Generation and Preprocessing

Digital down converter (DDC) is used to process the signal obtained from formula (5) to obtain a complex baseband signal including in-phase component and quadrature component. The general expression is as follows:
(6)In&=Ansinω0n+nωn+φn+φ0,Qn&=Ancosω0n+nωn+φn+φ0,whereIn represents the in-phase component of the modulated signal, and Qn represents the quadrature component of the modulated signal. After passing through the channel, the received signal yn can be described as the following equation:
(7)yn=∑i=1NCie−j2πfin−ki·In−ki+Qn−ki+vn,whereCi and ki represent subpath gain and delay, fi is Doppler frequency, and vn represents additive white Gaussian noise (AWGN) [11].In reality, in addition to channel noise, the accuracy of modulation signal identification is also affected by intersymbol interface (ISI) and frequency offset. Due to the existence of intersymbol crosstalk in the channel, in order to eliminate the impact of intersymbol crosstalk on the recognition accuracy, according to the Nyquist criterion, a raised cosine transmit filter (RCTF) is used to eliminate inter symbol crosstalk, so that each complex value signal passes through a raised cosine filter with a roll off coefficient of 0.4. The impulse response of the raised cosine filter is as follows:(8)hRCn=sinω0n·cosω0αnω0n·1−2aω0n/π2,whereα is the roll off coefficient of the raised cosine filter and f0 is the bandwidth of the filter.To sum up, this paper considers the pretreatment process of input data set under AWGN channel conditions as shown in Figure2.Figure 2
Schematic diagram of data set generation.


### 3.3. Working Principle of Modulation Recognition Method Based on Convolutional Neural Network

#### 3.3.1. Structure of Convolutional Neural Network

The process of modulation recognition using convolutional neural network structure is as follows: Firstly, the preprocessed seven types of modulation signals are processed into training set and test set, respectively; then, the CNN model is trained through the training set, and the super parameters of the CNN model are fine tuned. After the training, the CNN model is tested by inputting the test set, and finally, the digital communication signals are recognized and classified [12].Convolutional neural network is a multilayer neural network with forward feedback, which is composed of convolution layer, pooling layer, and full connection layer. The neurons of each layer in the convolutional neural network automatically extract features from the input data, so as to update the weights of neurons of each layer [13]. The working principle of the neuron is shown in Figure 3. The n input vectors x1,x2,⋯,xn and their corresponding weight vectors w1,w2,⋯,wn are used as the inner product, plus the bias b, and then, the output fx;w,b is obtained through the nonlinear activation function h∑iwixi+b. Convolutional neural network has the characteristics of local perception and weight sharing, which can reduce the number of training parameters and computational complexity [14].
(1)
Convolution layer is used to extract features from input data. The input data is generally the characteristic matrix. The convolution kernel size and moving step size of each convolution layer are manually set. Convolution operation is carried out through the convolution kernel and the characteristic matrix of the upper layer. After each data window is calculated, the convolution kernel shifts to the next position, and the output characteristic matrix is obtained by activating the function. The calculation formula of convolution layer is as follows:(9)Yjl=f∑xil−1∗kijl+bjl,Figure 3
Working principle of neuron.wherel is the number of network layers, f· is the activation function, x is the input vector matrix, k is the convolution kernel matrix, b is the bias, Y is the output matrix, and j is the number of characteristic graphs [15].
(2)
The pooling layer can effectively reduce the matrix size and latitude and further reduce the parameters in the full connection layer. The forward propagation process of the pool layer is similar to that of the convolution layer, and the size and step length of the sliding window matrix need to be manually specified. In this paper, the pool layer takes the maximum value of each sliding window as the output, and the output is also in the form of a three-dimensional matrix, as shown in the following formula:(10)Yjl=fωjlmaxxN×Ml+bjl,wherex is the matrix of input characteristics in the pool layer, and N×M is the size of the pool sliding window.
(3)
The full connection layer connects all neurons with all neurons of the upper layer and outputs a two-dimensional matrix form of1×N. Since the output dimension after passing through the full connection layer is different from the original input dimension, it is finally necessary to connect with softmax. For samples of specified categories, the probability of each category is finally calculated [16]. The probability that softmax regression marks sample xi as a category is as follows:(11)pyi=j∣xi;θ=eθjTx∑l=1keθjTx.Softmax cross entropy loss function is as follows:(12)Lθ=1M∑i=1M∑j=1kIyi=jlogeθjTx∑l=1keθjTx,whereyi is one hot code form, and if yi=j is true, then I·=1; otherwise, I·=1, k is the category, and M is the number of samples.When training the neural network, in order to minimize the cross entropy loss function, the adaptive moment (Adam) optimization algorithm is used to update the weights [17]. Adam has the advantages of both momentum algorithm and root mean square propagation (rmsprop) algorithm. By calculating the adaptive learning rate of the first-order moment estimation and second-order moment estimation of the loss function, the global optimal solution can be quickly obtained. The specific steps are as follows.Step 1.
Initialize the first-order moment estimation of loss function gradientmw=0, the second-order moment estimation of loss function gradient vw=0, the number of iterations t=0, and the training set D=xi,yi,i=1,2,⋯,N.Step 2.
Update iteration numbert⟵t+1.Step 3.
Randomly takeM subsets from training set D to obtain Dm,Dm=xi,yi,i=1,2,⋯,M. Carry out the feedforward operation of the neural network and calculate the output y∧i=fxi;w.Step 4.
Calculate the gradient∇L of the loss function.
(13)∇L=∂1/M∑i=1MLyi,y∧i+Ωw∂w,
whereLyi,y∧i is called loss function, which measures the difference between the real output and the expected output of the training sample, and Ωw is called L2 regularization term to prevent overfitting, as shown in the following formula.
(14)Ωω=12ω2.Step 5.
Updatemwt+1⟵β1mwt+1−β1∇Lt and calculate its correction value as follows:
(15)m¯w=mwi+11−β1+1.
Updatev¯wt+1⟵β2mwt+1−β2∇Lt2 and calculate its correction value as follows:
(16)v¯w=vwt+11−β2+1.Step 6.
Update weightwt+1≪wt−ηm¯w/vw+ε, where β1β2 is the weighted index, β1=0.9,β2=0.999, η is the learning rate to be fine tuned during training, and ε is the smoothing factor, ε=10−8 [18].Step 7.
Return to Step2 and continue training until the stop condition is reached.


#### 3.3.2. CNN-IQ Convolutional Neural Network Model

This paper presents a convolutional neural network model named CNN-IQ [19]. CNN’s model framework consists of one input layer, two convolution layers (Conv), two Maxpool layers, one fully connected (Fc) layer, and one softmax classifier. Finally, the modulation types of seven signals are output (see Table 1 for model parameters).Table 1
Parameters of CNN-IQ model.
LayerConvolution kernelStep lengthCharacteristic diagramOutputInput12∗1024Conv11∗21∗12562∗1024Maxpool11∗21∗22562∗512Conv22∗21∗12561∗511Maxpool21∗21∗21281∗128Fc2561∗256Softmax71∗7The input layer inputs a 2-dimensional matrix with the size of2×1024; Conv1 convolution kernel has a size of 1×2, a depth of 256, and a step size of 1×1. It is filled with all zeros. After convolution calculation, 256 2×1024 characteristic graphs are obtained. There are a total of 2×512×256×1×2+1=786432 connections in this layer. Maxpool1 sliding window size is 1×2, step size is 1×2, and all zero filling is used to obtain 256 2×512 characteristic graphs [20]. In conv2, the convolution kernel size is 2×2, the depth is 128, and the step size is 1×1. All zero filling is not used. The two convolution layers use the rectified linear unit (Relu) as the activation function. The activation function makes the whole neural network model nonlinear. After convolution calculation, 256 1×511 characteristic graphs are obtained. There are 1×511×256×2×2+1=654080 connections in this layer. The size of maxpool1 sliding window is 1×2, the step size is 1×1, and all zero padding is used to obtain 1281×128 characteristic graphs. The full junction layer is composed of 256 neurons in total. The full junction layer has 1×128×128×256+256=4184560 connections. Finally, the number of softmax layer output nodes is 7 [21]. In order to avoid over fitting, a dropout with P=0.5 is set at the full connection layer. The dropout method can randomly delete half of the neurons in the network while keeping the input and output neurons unchanged, which can further improve the reliability of the model and prevent over fitting.


## 3.1. Signal Modulation Model

There are three basic digital modulation modes: multiband frequency shift keying (MFSK), multiband amplitude shift keying (mask), and multiband phase shift keying (MPSK) [8, 9]. The three signals can be mathematically modeled as follows:
(1)sMFSKt=∑i=0N−1A0cos2πfct+2πfit+θ0·gTt−iT,(2)sMPSKt=∑i=0N−1A0cos2πft+θ0+θi·gTt−iT,(3)sMASKt=∑i=0N−1Aicos2πfct+θ0·gTt−iT,wherefc is the initial carrier frequency, θ0 is the initial phase, A0 is the initial amplitude of the carrier, N is the number of observed symbols, T is the symbol period, gT· is the waveform pulse formed in the symbol period, and fi∈f1,f2,⋯,fM is the modulation frequency; Ai∈A1,A2,⋯,AM is the modulation amplitude; 2π/Mm−1,m=1,2,⋯,M is the modulation phase.On this basis, multiband quadrature amplitude modulation (MQAM) simultaneously uses the amplitude and phase of the carrier to modulate the transmission data [10]. The MQAM expression is as follows:
(4)sMASKt=∑i=0N−1Aicos2πfct+θ0·gTt−iT.The general expression of the modulated signal obtained from (1)–(4) is as follows:
(5)st=At·cos2πfct+2πftt+θt+θ0,wherest represents continuous time series signal. According to formula (5), seven modulation models are obtained by changing its frequency, phase, amplitude, or other parameters.


## 3.2. Data Set Generation and Preprocessing

Digital down converter (DDC) is used to process the signal obtained from formula (5) to obtain a complex baseband signal including in-phase component and quadrature component. The general expression is as follows:
(6)In&=Ansinω0n+nωn+φn+φ0,Qn&=Ancosω0n+nωn+φn+φ0,whereIn represents the in-phase component of the modulated signal, and Qn represents the quadrature component of the modulated signal. After passing through the channel, the received signal yn can be described as the following equation:
(7)yn=∑i=1NCie−j2πfin−ki·In−ki+Qn−ki+vn,whereCi and ki represent subpath gain and delay, fi is Doppler frequency, and vn represents additive white Gaussian noise (AWGN) [11].In reality, in addition to channel noise, the accuracy of modulation signal identification is also affected by intersymbol interface (ISI) and frequency offset. Due to the existence of intersymbol crosstalk in the channel, in order to eliminate the impact of intersymbol crosstalk on the recognition accuracy, according to the Nyquist criterion, a raised cosine transmit filter (RCTF) is used to eliminate inter symbol crosstalk, so that each complex value signal passes through a raised cosine filter with a roll off coefficient of 0.4. The impulse response of the raised cosine filter is as follows:(8)hRCn=sinω0n·cosω0αnω0n·1−2aω0n/π2,whereα is the roll off coefficient of the raised cosine filter and f0 is the bandwidth of the filter.To sum up, this paper considers the pretreatment process of input data set under AWGN channel conditions as shown in Figure2.Figure 2
Schematic diagram of data set generation.


## 3.3. Working Principle of Modulation Recognition Method Based on Convolutional Neural Network

### 3.3.1. Structure of Convolutional Neural Network

The process of modulation recognition using convolutional neural network structure is as follows: Firstly, the preprocessed seven types of modulation signals are processed into training set and test set, respectively; then, the CNN model is trained through the training set, and the super parameters of the CNN model are fine tuned. After the training, the CNN model is tested by inputting the test set, and finally, the digital communication signals are recognized and classified [12].Convolutional neural network is a multilayer neural network with forward feedback, which is composed of convolution layer, pooling layer, and full connection layer. The neurons of each layer in the convolutional neural network automatically extract features from the input data, so as to update the weights of neurons of each layer [13]. The working principle of the neuron is shown in Figure 3. The n input vectors x1,x2,⋯,xn and their corresponding weight vectors w1,w2,⋯,wn are used as the inner product, plus the bias b, and then, the output fx;w,b is obtained through the nonlinear activation function h∑iwixi+b. Convolutional neural network has the characteristics of local perception and weight sharing, which can reduce the number of training parameters and computational complexity [14].
(1)
Convolution layer is used to extract features from input data. The input data is generally the characteristic matrix. The convolution kernel size and moving step size of each convolution layer are manually set. Convolution operation is carried out through the convolution kernel and the characteristic matrix of the upper layer. After each data window is calculated, the convolution kernel shifts to the next position, and the output characteristic matrix is obtained by activating the function. The calculation formula of convolution layer is as follows:(9)Yjl=f∑xil−1∗kijl+bjl,Figure 3
Working principle of neuron.wherel is the number of network layers, f· is the activation function, x is the input vector matrix, k is the convolution kernel matrix, b is the bias, Y is the output matrix, and j is the number of characteristic graphs [15].
(2)
The pooling layer can effectively reduce the matrix size and latitude and further reduce the parameters in the full connection layer. The forward propagation process of the pool layer is similar to that of the convolution layer, and the size and step length of the sliding window matrix need to be manually specified. In this paper, the pool layer takes the maximum value of each sliding window as the output, and the output is also in the form of a three-dimensional matrix, as shown in the following formula:(10)Yjl=fωjlmaxxN×Ml+bjl,wherex is the matrix of input characteristics in the pool layer, and N×M is the size of the pool sliding window.
(3)
The full connection layer connects all neurons with all neurons of the upper layer and outputs a two-dimensional matrix form of1×N. Since the output dimension after passing through the full connection layer is different from the original input dimension, it is finally necessary to connect with softmax. For samples of specified categories, the probability of each category is finally calculated [16]. The probability that softmax regression marks sample xi as a category is as follows:(11)pyi=j∣xi;θ=eθjTx∑l=1keθjTx.Softmax cross entropy loss function is as follows:(12)Lθ=1M∑i=1M∑j=1kIyi=jlogeθjTx∑l=1keθjTx,whereyi is one hot code form, and if yi=j is true, then I·=1; otherwise, I·=1, k is the category, and M is the number of samples.When training the neural network, in order to minimize the cross entropy loss function, the adaptive moment (Adam) optimization algorithm is used to update the weights [17]. Adam has the advantages of both momentum algorithm and root mean square propagation (rmsprop) algorithm. By calculating the adaptive learning rate of the first-order moment estimation and second-order moment estimation of the loss function, the global optimal solution can be quickly obtained. The specific steps are as follows.Step 1.
Initialize the first-order moment estimation of loss function gradientmw=0, the second-order moment estimation of loss function gradient vw=0, the number of iterations t=0, and the training set D=xi,yi,i=1,2,⋯,N.Step 2.
Update iteration numbert⟵t+1.Step 3.
Randomly takeM subsets from training set D to obtain Dm,Dm=xi,yi,i=1,2,⋯,M. Carry out the feedforward operation of the neural network and calculate the output y∧i=fxi;w.Step 4.
Calculate the gradient∇L of the loss function.
(13)∇L=∂1/M∑i=1MLyi,y∧i+Ωw∂w,
whereLyi,y∧i is called loss function, which measures the difference between the real output and the expected output of the training sample, and Ωw is called L2 regularization term to prevent overfitting, as shown in the following formula.
(14)Ωω=12ω2.Step 5.
Updatemwt+1⟵β1mwt+1−β1∇Lt and calculate its correction value as follows:
(15)m¯w=mwi+11−β1+1.
Updatev¯wt+1⟵β2mwt+1−β2∇Lt2 and calculate its correction value as follows:
(16)v¯w=vwt+11−β2+1.Step 6.
Update weightwt+1≪wt−ηm¯w/vw+ε, where β1β2 is the weighted index, β1=0.9,β2=0.999, η is the learning rate to be fine tuned during training, and ε is the smoothing factor, ε=10−8 [18].Step 7.
Return to Step2 and continue training until the stop condition is reached.


### 3.3.2. CNN-IQ Convolutional Neural Network Model

This paper presents a convolutional neural network model named CNN-IQ [19]. CNN’s model framework consists of one input layer, two convolution layers (Conv), two Maxpool layers, one fully connected (Fc) layer, and one softmax classifier. Finally, the modulation types of seven signals are output (see Table 1 for model parameters).Table 1
Parameters of CNN-IQ model.
LayerConvolution kernelStep lengthCharacteristic diagramOutputInput12∗1024Conv11∗21∗12562∗1024Maxpool11∗21∗22562∗512Conv22∗21∗12561∗511Maxpool21∗21∗21281∗128Fc2561∗256Softmax71∗7The input layer inputs a 2-dimensional matrix with the size of2×1024; Conv1 convolution kernel has a size of 1×2, a depth of 256, and a step size of 1×1. It is filled with all zeros. After convolution calculation, 256 2×1024 characteristic graphs are obtained. There are a total of 2×512×256×1×2+1=786432 connections in this layer. Maxpool1 sliding window size is 1×2, step size is 1×2, and all zero filling is used to obtain 256 2×512 characteristic graphs [20]. In conv2, the convolution kernel size is 2×2, the depth is 128, and the step size is 1×1. All zero filling is not used. The two convolution layers use the rectified linear unit (Relu) as the activation function. The activation function makes the whole neural network model nonlinear. After convolution calculation, 256 1×511 characteristic graphs are obtained. There are 1×511×256×2×2+1=654080 connections in this layer. The size of maxpool1 sliding window is 1×2, the step size is 1×1, and all zero padding is used to obtain 1281×128 characteristic graphs. The full junction layer is composed of 256 neurons in total. The full junction layer has 1×128×128×256+256=4184560 connections. Finally, the number of softmax layer output nodes is 7 [21]. In order to avoid over fitting, a dropout with P=0.5 is set at the full connection layer. The dropout method can randomly delete half of the neurons in the network while keeping the input and output neurons unchanged, which can further improve the reliability of the model and prevent over fitting.


## 3.3.1. Structure of Convolutional Neural Network

The process of modulation recognition using convolutional neural network structure is as follows: Firstly, the preprocessed seven types of modulation signals are processed into training set and test set, respectively; then, the CNN model is trained through the training set, and the super parameters of the CNN model are fine tuned. After the training, the CNN model is tested by inputting the test set, and finally, the digital communication signals are recognized and classified [12].Convolutional neural network is a multilayer neural network with forward feedback, which is composed of convolution layer, pooling layer, and full connection layer. The neurons of each layer in the convolutional neural network automatically extract features from the input data, so as to update the weights of neurons of each layer [13]. The working principle of the neuron is shown in Figure 3. The n input vectors x1,x2,⋯,xn and their corresponding weight vectors w1,w2,⋯,wn are used as the inner product, plus the bias b, and then, the output fx;w,b is obtained through the nonlinear activation function h∑iwixi+b. Convolutional neural network has the characteristics of local perception and weight sharing, which can reduce the number of training parameters and computational complexity [14].
(1)
Convolution layer is used to extract features from input data. The input data is generally the characteristic matrix. The convolution kernel size and moving step size of each convolution layer are manually set. Convolution operation is carried out through the convolution kernel and the characteristic matrix of the upper layer. After each data window is calculated, the convolution kernel shifts to the next position, and the output characteristic matrix is obtained by activating the function. The calculation formula of convolution layer is as follows:(9)Yjl=f∑xil−1∗kijl+bjl,Figure 3
Working principle of neuron.wherel is the number of network layers, f· is the activation function, x is the input vector matrix, k is the convolution kernel matrix, b is the bias, Y is the output matrix, and j is the number of characteristic graphs [15].
(2)
The pooling layer can effectively reduce the matrix size and latitude and further reduce the parameters in the full connection layer. The forward propagation process of the pool layer is similar to that of the convolution layer, and the size and step length of the sliding window matrix need to be manually specified. In this paper, the pool layer takes the maximum value of each sliding window as the output, and the output is also in the form of a three-dimensional matrix, as shown in the following formula:(10)Yjl=fωjlmaxxN×Ml+bjl,wherex is the matrix of input characteristics in the pool layer, and N×M is the size of the pool sliding window.
(3)
The full connection layer connects all neurons with all neurons of the upper layer and outputs a two-dimensional matrix form of1×N. Since the output dimension after passing through the full connection layer is different from the original input dimension, it is finally necessary to connect with softmax. For samples of specified categories, the probability of each category is finally calculated [16]. The probability that softmax regression marks sample xi as a category is as follows:(11)pyi=j∣xi;θ=eθjTx∑l=1keθjTx.Softmax cross entropy loss function is as follows:(12)Lθ=1M∑i=1M∑j=1kIyi=jlogeθjTx∑l=1keθjTx,whereyi is one hot code form, and if yi=j is true, then I·=1; otherwise, I·=1, k is the category, and M is the number of samples.When training the neural network, in order to minimize the cross entropy loss function, the adaptive moment (Adam) optimization algorithm is used to update the weights [17]. Adam has the advantages of both momentum algorithm and root mean square propagation (rmsprop) algorithm. By calculating the adaptive learning rate of the first-order moment estimation and second-order moment estimation of the loss function, the global optimal solution can be quickly obtained. The specific steps are as follows.Step 1.
Initialize the first-order moment estimation of loss function gradientmw=0, the second-order moment estimation of loss function gradient vw=0, the number of iterations t=0, and the training set D=xi,yi,i=1,2,⋯,N.Step 2.
Update iteration numbert⟵t+1.Step 3.
Randomly takeM subsets from training set D to obtain Dm,Dm=xi,yi,i=1,2,⋯,M. Carry out the feedforward operation of the neural network and calculate the output y∧i=fxi;w.Step 4.
Calculate the gradient∇L of the loss function.
(13)∇L=∂1/M∑i=1MLyi,y∧i+Ωw∂w,
whereLyi,y∧i is called loss function, which measures the difference between the real output and the expected output of the training sample, and Ωw is called L2 regularization term to prevent overfitting, as shown in the following formula.
(14)Ωω=12ω2.Step 5.
Updatemwt+1⟵β1mwt+1−β1∇Lt and calculate its correction value as follows:
(15)m¯w=mwi+11−β1+1.
Updatev¯wt+1⟵β2mwt+1−β2∇Lt2 and calculate its correction value as follows:
(16)v¯w=vwt+11−β2+1.Step 6.
Update weightwt+1≪wt−ηm¯w/vw+ε, where β1β2 is the weighted index, β1=0.9,β2=0.999, η is the learning rate to be fine tuned during training, and ε is the smoothing factor, ε=10−8 [18].Step 7.
Return to Step2 and continue training until the stop condition is reached.


## 3.3.2. CNN-IQ Convolutional Neural Network Model

This paper presents a convolutional neural network model named CNN-IQ [19]. CNN’s model framework consists of one input layer, two convolution layers (Conv), two Maxpool layers, one fully connected (Fc) layer, and one softmax classifier. Finally, the modulation types of seven signals are output (see Table 1 for model parameters).Table 1
Parameters of CNN-IQ model.
LayerConvolution kernelStep lengthCharacteristic diagramOutputInput12∗1024Conv11∗21∗12562∗1024Maxpool11∗21∗22562∗512Conv22∗21∗12561∗511Maxpool21∗21∗21281∗128Fc2561∗256Softmax71∗7The input layer inputs a 2-dimensional matrix with the size of2×1024; Conv1 convolution kernel has a size of 1×2, a depth of 256, and a step size of 1×1. It is filled with all zeros. After convolution calculation, 256 2×1024 characteristic graphs are obtained. There are a total of 2×512×256×1×2+1=786432 connections in this layer. Maxpool1 sliding window size is 1×2, step size is 1×2, and all zero filling is used to obtain 256 2×512 characteristic graphs [20]. In conv2, the convolution kernel size is 2×2, the depth is 128, and the step size is 1×1. All zero filling is not used. The two convolution layers use the rectified linear unit (Relu) as the activation function. The activation function makes the whole neural network model nonlinear. After convolution calculation, 256 1×511 characteristic graphs are obtained. There are 1×511×256×2×2+1=654080 connections in this layer. The size of maxpool1 sliding window is 1×2, the step size is 1×1, and all zero padding is used to obtain 1281×128 characteristic graphs. The full junction layer is composed of 256 neurons in total. The full junction layer has 1×128×128×256+256=4184560 connections. Finally, the number of softmax layer output nodes is 7 [21]. In order to avoid over fitting, a dropout with P=0.5 is set at the full connection layer. The dropout method can randomly delete half of the neurons in the network while keeping the input and output neurons unchanged, which can further improve the reliability of the model and prevent over fitting.


## 4. Result Analysis

### 4.1. Preparation of Experimental Data Set

In order to train convolutional neural network model, a large number of training set and test set sample data sets are required. In the experiment, Matlab is used to generate IQ data of seven digital signal models, including 2FSK, 4FSK, BPSK, 8PSK, QPSK, qam16, and QAM64. Each type of signal in the data set consists of 1024 sample points and is saved in a2×1024 matrix format. The first row of the matrix is I-channel signal, and the second row is Q-channel signal. The specific division of the data set is shown in Table 1. The signal-to-noise ratio of the data set ranges from -10 dB to 18 dB with an interval of 2. Parameters for signal generation: the sampling frequency is 1000 Hz, the carrier frequency is 100 Hz, and the number of symbols is 256. The training set includes 49000 samples, and the test set includes 4200 samples. The signal sample label adopts one hot coding format [22].The experimental environment is as follows: the graphics card is Titan x GPU, the processor is Intel (R) Xeon (R) CPUE5-2620v3@2.40 GHz, and the memory is 10 GB. Software environment: the data set is generated under Matlab2016b in Windows 10. The training of convolutional neural network is built under the framework of tensorflow1.12 in Ubuntu system. The development language is python3.6.


### 4.2. Analysis of Experimental Results

In the experiment, the learning rate starts from 0.001 to train the framework CNN-IQ. When the loss value of the test set during training is greater than the maximum loss value at this time, the learning rate at this time is multiplied by 0.02 to correct the learning rate. There are 100 rounds of training in the experiment, and each round takes about 23 seconds. Figure4 is a graph of the training loss value, the validation loss value, and the training rounds. With the increase of rounds, the training loss and the validation loss both decrease rapidly, and the two curves gradually converge, indicating that there is no overfitting in the experimental model. After epochs=38, the loss value is basically stable, and the two curves of training loss and validation loss converge. When epochs=100, the validation loss value is 0.035, and the loss value at this time has reached the minimum value. A good convolutional neural network model framework and weights are saved to facilitate the transfer training of the CNN-IQ model [23].Figure 4
Variation of training loss and verification loss with training times.In order to evaluate the range recognition performance of other methods under the same data set compared to our CNN-IQ method, we analyzed the effect of the two methods on the recognition accuracy as the signal-to-noise ratio increased. The analysis in Figure5 shows that the accuracy of the method in this document is significantly improved compared to other methods when the signal-to-noise ratio is low. The results of the analysis shown in Figure 5 show that the method of this document improves the accuracy by approximately 25.41% when the signal-to-noise ratio is less than 0 dB. When the signal-to-noise ratio is equal to 0 dB, the average accuracy of this paper reaches 94.61%, while the average accuracy of other methods is 72.13%. When the signal-to-noise ratio is 18 dB, the accuracy level of the method in this document reaches 98.85%, while the accuracy level of other methods is 95.32%. Compared to other methods, the accuracy of CNN-IQ is significantly improved when the signal-to-noise ratio is low, and the accuracy is somewhat improved when the signal-to-noise ratio is high.Figure 5
Average recognition accuracy of two methods under different signal-to-noise ratios.


## 4.1. Preparation of Experimental Data Set

In order to train convolutional neural network model, a large number of training set and test set sample data sets are required. In the experiment, Matlab is used to generate IQ data of seven digital signal models, including 2FSK, 4FSK, BPSK, 8PSK, QPSK, qam16, and QAM64. Each type of signal in the data set consists of 1024 sample points and is saved in a2×1024 matrix format. The first row of the matrix is I-channel signal, and the second row is Q-channel signal. The specific division of the data set is shown in Table 1. The signal-to-noise ratio of the data set ranges from -10 dB to 18 dB with an interval of 2. Parameters for signal generation: the sampling frequency is 1000 Hz, the carrier frequency is 100 Hz, and the number of symbols is 256. The training set includes 49000 samples, and the test set includes 4200 samples. The signal sample label adopts one hot coding format [22].The experimental environment is as follows: the graphics card is Titan x GPU, the processor is Intel (R) Xeon (R) CPUE5-2620v3@2.40 GHz, and the memory is 10 GB. Software environment: the data set is generated under Matlab2016b in Windows 10. The training of convolutional neural network is built under the framework of tensorflow1.12 in Ubuntu system. The development language is python3.6.


## 4.2. Analysis of Experimental Results

In the experiment, the learning rate starts from 0.001 to train the framework CNN-IQ. When the loss value of the test set during training is greater than the maximum loss value at this time, the learning rate at this time is multiplied by 0.02 to correct the learning rate. There are 100 rounds of training in the experiment, and each round takes about 23 seconds. Figure4 is a graph of the training loss value, the validation loss value, and the training rounds. With the increase of rounds, the training loss and the validation loss both decrease rapidly, and the two curves gradually converge, indicating that there is no overfitting in the experimental model. After epochs=38, the loss value is basically stable, and the two curves of training loss and validation loss converge. When epochs=100, the validation loss value is 0.035, and the loss value at this time has reached the minimum value. A good convolutional neural network model framework and weights are saved to facilitate the transfer training of the CNN-IQ model [23].Figure 4
Variation of training loss and verification loss with training times.In order to evaluate the range recognition performance of other methods under the same data set compared to our CNN-IQ method, we analyzed the effect of the two methods on the recognition accuracy as the signal-to-noise ratio increased. The analysis in Figure5 shows that the accuracy of the method in this document is significantly improved compared to other methods when the signal-to-noise ratio is low. The results of the analysis shown in Figure 5 show that the method of this document improves the accuracy by approximately 25.41% when the signal-to-noise ratio is less than 0 dB. When the signal-to-noise ratio is equal to 0 dB, the average accuracy of this paper reaches 94.61%, while the average accuracy of other methods is 72.13%. When the signal-to-noise ratio is 18 dB, the accuracy level of the method in this document reaches 98.85%, while the accuracy level of other methods is 95.32%. Compared to other methods, the accuracy of CNN-IQ is significantly improved when the signal-to-noise ratio is low, and the accuracy is somewhat improved when the signal-to-noise ratio is high.Figure 5
Average recognition accuracy of two methods under different signal-to-noise ratios.


## 5. Conclusion

In order to determine digital communication signals, this paper proposes a method for determining modulation based on a complex backbone signal using a disruptive neural network. First, a method is developed to process the generated digital signal into a complex signal, and then, the data is preprocessed, and the disrupted neural network built on the generated data set is trained. The value loss is minimal and combined, offering the CNN-IQ model and finally using the CNN-IQ model to learn the transmission of seven types of digital communication signals. The simulation results show that the method in this document is effective in recognizing digital communication signals, and that the signal recognition accuracy is greatly improved when the signal-to-noise ratio is low. The next step is to consider a dual-channel neural network, to study how to reduce the structure and parameters of the circulatory neural network, and to further improve the speed of the entire recognition process, while maintaining a high degree of acceptance.



---

*Source: 3519010-2022-07-23.xml*