# Structural Damage Detection Based on One-Dimensional Convolutional Neural Network
## 5 Damage Degree Detection
### Detection Result  
The training set and the valid set are inputted into the proposed convolutional neural network. Training accuracy and valid accuracy are shown in Figure 10. When the number of iteration epoch is 100, the training accuracy is 0.9642 and the valid accuracy is 0.9467. The detection accuracy has met the requirements of engineering.  
\begin{table}
\begin{tabular}{l c c c c c c c c} \hline \hline \multirow{2}{*}{**Count**} & \multicolumn{8}{c}{**Predicted Damage Location**} \\ \cline{2-9}  & **c0** & **c1c6** & **c1c11** & **c6c11** & **c1c6c11** & **Total** & **Accuracy** \\ \hline \multirow{4}{*}{Actual damage location} & c0 & 79 & 0 & 0 & 0 & 0 & 79 & 100\% \\ \cline{2-9}  & c1c6 & 0 & 106 & 1 & 0 & 0 & 107 & 99.1\% \\ \cline{2-9}  & c1c11 & 0 & 3 & 92 & 2 & 0 & 97 & 94.8\% \\ \cline{2-9}  & c6c11 & 0 & 0 & 0 & 114 & 0 & 114 & 100\% \\ \cline{2-9}  & c1c6c11 & 0 & 3 & 0 & 4 & 91 & 98 & 92.9\% \\ \cline{2-9}  & Total & 79 & 112 & 93 & 120 & 91 & 495 & Overall: 97.36\% \\ \hline \hline \end{tabular}
\end{table}
Table 4: The test results.  
Figure 9: The two-dimensional display of data. (**a**) raw data (**b**) output data of CNN.  
A detection model can be obtained by training the dataset. The test set is used to test the detection performance of the model, and the test result is shown in Table 5. The number of samples in the test set is 495. The recognition accuracy of \"0\" is 100%. The recognition accuracy of \"30%\" is 84.3%, 70 samples can be identified correctly, 1 sample can be misidentified as \"40%\", and 12 samples can be misidentified as \"20%\". In addition, it can be found that the misidentified samples always are identified as adjacent categories. The difference between adjacent categories is very small, and it is difficult to distinguish them. However, the average recognition accuracy of the five categories is 97.36%. The result showed that this method can identify damage degree accurately.  
The raw data of the test set and the output data of the convolutional neural network are, respectively, displayed in two dimensions by \"t-SNE\", as shown in Figure 11. The two-dimensional display of raw data is also terrible. There is no distinction between the categories. However, the two-dimensional display of the output data of CNN is perfect. There is a clear distinction between the categories. Because the difference between adjacent categories is very small, the misidentified samples always are identified as adjacent categories. In short, the proposed convolutional neural network can complete the damage degree detection.  
Figure 10: Training accuracy and valid accuracy.  
\begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline \multirow{2}{*}{**Count**} & \multicolumn{8}{c}{**Predicted Damage Degree**} \\ \cline{2-9}  & **0** & **10\%** & **20\%** & **30\%** & **40\%** & **Total** & **Accuracy** \\ \hline \multirow{4}{*}{**Actual damage degree**} & 0 & 104 & 0 & 0 & 0 & 0 & 104 & 100\% \\  & 10\% & 1 & 101 & 3 & 0 & 0 & 105 & 96.2\% \\ \cline{1-1} \cline{2-9}  & 20\% & 0 & 7 & 91 & 3 & 0 & 101 & 90.1\% \\ \cline{1-1} \cline{2-9}  & 30\% & 0 & 0 & 12 & 70 & 1 & 83 & 84.3\% \\ \cline{1-1} \cline{2-9}  & 40\% & 0 & 0 & 0 & 7 & 95 & 102 & 93.1\% \\ \cline{1-1} \cline{2-9}  & Total & 105 & 108 & 106 & 80 & 96 & 495 & Overall: 92.74\% \\ \hline \hline \end{tabular}
\end{table}
Table 5: The test results.