## 3 Robust Algorithm Based on CNN
### The Structure of CNN  
CNN which is inspired by the structure of nerve cells in the visual cortex extracts and classifies image information through a multilayer structure. As shown in Figure 2, the structure composed of seven layers is the basic form of CNN. In order to achieve better performance, CNN usually contains more layers. A pair of convolutional layer and pooling layer is a group. According to the needs of practical application, many groups could be added.  
In Figure 2, the input layer receives the sample data and preprocesses the data such as normalization. Then, it packages the data according to the input format to prepare for the next operation. The output layer provides the probabilities corresponding to different results. Convolutional layer, pooling layer and fully-connected layer are the decisive parts of CNN. Their structures are much more complex than that of the two above-mentioned layers, so they are described as follows one by one.  
The convolutional layer extracts different levels of image features by convolutional operation. The higher the level of convolutional layer is, the finer the image features are extracted. It is composed of several feature planes, each of which shares a convolution kernel with one of the feature planes of the upper layer. If the upper layer of the current convolutional layer contains multiple feature planes, there will be multiple convolution kernels. The feature plane of convolutional layer is equal to the sum of convolution between multiple feature planes and convolutional kernels. Convolutional kernel is a weight matrix whose coefficients are adjusted during the training period of CNN. The input-output relationship of convolutional layer is expressed as:  
\[Y_{j}=f_{\text{cov}}\Bigg{(}\sum_{i=1}^{M}\text{cov}\Big{(}X_{i},W_{i,j} \Big{)}+b_{j}\Bigg{)}, \tag{22}\]  
Figure 2: The typical structure of convolutional neural network (CNN).  
where \(Y_{j}\) represents the \(j\)th feature plane of convolutional layer. \(X_{i}\) represents the \(i\)th feature plane, which belongs to the upper layer of the current convolutional layer. \(W_{i,j}\) represents the coefficients of convolutional kernel between \(X_{i}\) and \(Y_{j}\). \(b_{j}\) is the bias. \(M\) is the number of \(X_{i}\). The function \(\text{cov}(\cdot)\) represents the convolutional operation, and \(f_{\text{cov}}(\cdot)\) represents the nonlinear activation function of convolutional layer.  
The function of pooling layer is to reduce the number of connections between two convolutional layers. Through the subsampling operation, some redundant information in the image is removed, and the main feature of image is obtained. The feature planes of pooling layer and convolutional layer correspond one to one, and the number of planes is the same. Average pooling and max pooling are the commonly used methods of subsampling. Average pooling takes the average of sampling area as the output, while max pooling chooses the maximum of sampling area as the output. The output of pooling layer is as follows:  
\[S_{j}=f_{\text{pool}}\Big{(}Y_{j}\Big{)}, \tag{23}\]  
where \(S_{j}\) represents the output of the \(j\)th feature plane of pooling layer, and the function \(f_{\text{pool}}(\cdot)\) represents the subsampling operation.  
Fully-connected layer lies between pooling layer and output layer. It integrates the local features which are extracted from pooling layer, and transfers the integrated results to the output layer. The relationship between input and output in fully-connected layer is expressed by Equation (24):  
\[l_{j}=f_{\text{fc}}\Bigg{(}\sum_{i=1}^{L}v_{i,j}c_{i}+\varepsilon_{j}\Bigg{)}, \tag{24}\]  
where \(l_{j}\) represents the \(j\)th output of fully-connected layer. \(c_{i}\) represents the \(i\)th neuron of fully-connected layer. \(v_{i,j}\) denotes the connection coefficient between \(c_{i}\) and \(l_{j}\). \(\varepsilon_{j}\) denotes the bias. \(f_{\text{fc}}(\cdot)\) represents the nonlinear activation function of the fully-connected layer.