## 4 Construction of Octree-Based Shape Information Model
### Image Processing for Crack Detection  
The validity of the proposed algorithm was evaluated for the extracted images from. The original snapshot resolution was 1513 \(\times\) 810 pixels, but 3026 \(\times\) 1620 pixels (\(\times\)2 resolution) was applied for precise crack detection and it was composed of RGB color. First, the original and compressed images were processed using the procedure described in the Table 1. Based on the compression rate, the accuracy of crack detection through the proposed imaging process was evaluated as shown in Figure 13. In case 3, the cracks were hardly recognized due to the poor resolution, so the result was not presented. As a result, most major cracks were identified well even in the Case 2 with compression rate of 50%, and some minor cracks due to drying shrinkage of concrete were recognized as well. The optimum values of the parameters for each case are shown in Table 6 and will be applied generally within the range in the table for other cases. \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Factors** & \multicolumn{2}{c}{**Original**} & **Case 1** & **Case 2** \\ \hline K-means clustering & A & \begin{tabular}{c} 300 \(\times\) 550, 600 \(\times\) \\ 100, 500 \(\times\) 200 \\ \end{tabular} & \begin{tabular}{c} 300 \(\times\) 550, 600 \(\times\) \\ 100, 500 \(\times\) 200 \\ \end{tabular} & \
\begin{tabular}{c} 300 \(\times\) 550, 600 \(\times\) \\ 100, 500 \(\times\) 200 \\ \end{tabular} \\ \hline Median filter size & B & 20 & 16 & 14 \\ \hline Segmentation level & C & 23 & 17 & 15 \\ \hline
\begin{tabular}{c} Control of area, \\ Eccentricity \\ \end{tabular} & D & \textgreater{}100, \textgreater{}0.3 & \textgreater{}100, \textgreater{}0.3 & \textgreater{}100, \textgreater{}0.3 \\ \hline \hline \end{tabular}
\end{table} 
Table 6: The parameter optimization of three cases. Figure 12: The TLS scan images by point compression rates. (**a**) Case 1; (**b**) Case 2; (**c**) Case 3. \begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Div.** & \
\begin{tabular}{c} **Data** \\ **Points** \\ \end{tabular} & **Octree Level** &
\begin{tabular}{c} **Point** \\ **Compression (\%)** \\ \end{tabular} & **Data Size (MB)** \\ \hline Original & 1,367,274 & 1 & 0 & 19.56 \\ Case1 & 934,061 & 9 & 31.6 & 13.36 \\ Case2 & 678,319 & 10 & 50.3 & 9.7 \\ Case3 & 269,942 & 11 & 80.2 & 3.86 \\ \hline \hline \end{tabular}
\end{table} 
Table 5: The number of compressed points and data size by octree structure. For quantitative comparison of each case, true positive (TP), false negative (FN), and number of false positive (FP) were analyzed and calculated in Figure 14 and Table 7. The quantitative analysis presents the evaluation of accuracy and error in comparison with the crack pattern map detected by visual inspection. For the quantification, two preconditions are assumed: (1) A crack is regarded as a noise and removed if its length was less than 450 mm (the smallest crack length) in the crack pattern map. (2) A crack was considered to be TP if its length was in line with more than 50% of one by visual inspection. As a result, it was confirmed that the accuracy of crack detection in the original image was best among all the cases in terms of TP, FN, and number of FP, and that the accuracy decreased according to the compression rate. However, it should be noted that the accuracy in even case 2 showed 84% in TP. In the original image, all the cracks were identified, but were not fully satisfied with crack lengths by visual inspection. In cases 1 and 2, the identified crack lengths were often exceeded with ones by visual inspection, which can be considered to be overestimated by resolution reduction. In comparison of the number of FP for each case, the errors increased sharply according to the compression rate due to erroneous recognition of the joints and sediments as cracks. Thus, it concludes that the higher the resolution, the higher the probability that the K-means clustering accurately recognizes the crack group.