## 4 Pipeline System Modeling
### Damage, Load and Support Identification Using CNN  
In the previous section, MMS distributions were studied for the intact and damaged pipeline system. However, due to the 3D modeling and its inherent complexity, different damage levels can hardly be identified. Therefore, a more efficient way to extract the features of MMS distribution is employed for damage, load and support identification. The schematic diagram of the application of the convolutional neural network can be shown in Figure 17.  
As discussed above, the convolution operation can be viewed as a neuron with fixed weights. The function of convolution layer is to identify local features of the previous layer, and the sampling layer is merging the similar features with the same feature. * Cnnssetup: Each feature map is the number of feature map multiplied by the size of patch map for convolution. By moving a kernel window in the feature map, each neuron of feature map is traversed. The kernel window is composed of elements with the size of _kernelsize_\(\times\)_kernelsize_. Each element is an independent weight, so there are _kernelsize_\(\times\)_kernelsize_ weights that need to be learned. Due to weight sharing, for the same feature map layer, the kernel window with the size of _kernelsize_\(\times\)_kernelsize_ has the same weights, which means weights are only determined by the kernel window. For different feature maps, the kernel windows are different, which means the weights are different. * cnntrain: First reorder the sample, and randomly train and calculate the weights of network input and output. Then calculate the derivative of the error with respect to weights by the back propagation (BP) algorithm. Weight updating method will be used to update the network. * Cnnff: Use the neural network to predict the input vector. First reorder the samples and then randomly train them. Samples are input to the network and are mapped for prediction. For each feature map of the last layer, the size of the feature map after convolution is: (feature map width-conv kernel width + 1) \(\times\) (feature map height-conv kernel height + 1). * cnnbp: The convolution layer is used for up-sampling and subsampling layer is used for down-sampling. The weights (size is onum \(\times\) rwnum) between the last layer and the output neurons; where onum is the number of labels, and fruum is the number of output neurons at the last layer. * Cnnapplygrads: The _Cnnapplygrads_ is used for weight updating. The training dataset is 256 \(\times\) 256 \(\times\) 6000, testing dataset is 256 \(\times\) 256 \(\times\) 800, labeled training dataset is 7 \(\times\) 6000, and the labeled testing dataset is 7 \(\times\) 800. The construction of the conventional neural network is 6c-2s-12c-2s (c: convolution layer, s: sub sampling layer), learning efficiency _Alpha_ = 1, _Batchsize_ = 50, and _Numepoch_ = 1. The superior characteristics of deep learning is that the outputs of intermediate layers can be used as another expression of data, therefore regarding it as the learned features through network adaptive learning, and these features can later be used for similarity comparison. The amounts of data can be used to effectively train parameters of deep learning network. In this study, the convolutional neural network includes two convolutional layers, two sub-sampling layers, and a full connection layer. Each layer tuned parameters and the corresponding weights. The input image size is 256 \(\times\) 256. The basic architecture of the connection of the convolutional layer and sub-sampling layer is depicted in Figure 18. C1 is a convolutional layer composed of six feature maps. By doing convolutional  
Figure 17: Identification schematic using a convolutional neural network. operation, the feature of the original signal can be enhanced and also reduce noise effects. Each neuron of the feature map is connected with 16 \(\times\) 16 neighborhood of input images. The feature map size is 196 \(\times\) 196.