## 2 Developed Methodology
### Connected Component Analysis  
Once an input image was transformed into two separate edge maps using Sobel operators, each map is treated as an image and is processed independently. As previously observed in Figure 6, a CC built up from detected edges will often mistakenly join architectural lines and cracks, resulting in misidentification of geometrical properties. Hence, value exists in producing oriented gradient maps rather than single-level edge maps. This computation is motivated by the intuition that horizontal and vertical lines, left on the surface of the rammed earth structures, correspond to horizontal and vertical discontinuities in intensity and geometrical features provide a robust mechanism for modeling the content of such image regions. By using oriented edge detection output, CC regions are built by  
Figure 7: The contributions of oriented edge maps to the performance of the algorithm. (**a**) Horizontal edge map, (**b**) vertical edge map, (**c**) horizontal CC map and (**d**) vertical CC map. exploiting the information in these edge maps by applying the eight connectivity rule [31] to each group of neighboring pixels in each direction, independently (Figure 7). Since cracks differ from architectural lines considering physical properties, their geometric characteristics can be used to classify them into different classes. Therefore, various morphological parameters can be defined to group them mathematically. For example, a strongly oriented axis length ratio (Ratio of Major Axis Length to Minor Axis Length) means a CC is more likely to lie on an architectural line map. In the previous stage, crack and non-crack regions were extracted from images using a classical edge detection technique, Sobel edge operators, in horizontal and vertical directions. To classify crack and architectural features, inspecting the detected oriented edge maps pixel by pixel is not necessary. In this model, we start from CC, a group of neighboring pixels that form a roughly linear segment. Each CC is represented by an ellipse. CC fundamental and physical properties are equivalent to those of this ellipse, and are utilized to support subsequent automatic crack analysis. A wide range of a surface can be acquired with a digital camera [40]. Therefore, fundamental analyses are performed on patches with 256 \(\times\) 256 pixels. Moreover, by expressing the geometrical characteristics in terms of the normalized quantities, we obtain a scale-invariant feature space. The morphological parameters identified and selected to use for CC analysis are briefly described in Table 1 and shown in Figure 8. We assign to each CC on each oriented map the morphological parameters of the corresponding ellipse. The results of CC analysis are shown in Figure 9. \begin{table}
\begin{tabular}{c c} \hline \hline
**Area** & **Number of Pixels** \\ \hline Density & Ratio of pixels in the region to pixels in total image \\ Major axis length & Length (in pixels) of the major axis of the equivalent ellipse \\ Minor axis length & Length (in pixels) of the minor axis of the equivalent ellipse \\ Length ratio & Ratio of the major axis length to 256\(\sqrt{2}\) \\ Width ratio & Ratio of the minor axis length to 256\(\sqrt{2}\) \\ Axis length ratio & Ratio of Major Axis Length to Minor axis length \\ Orientation & Absolute value of the angle between the x-axis and the major axis of the ellipse, ranging from 0 degrees to 90 degrees (Figure 3b). \\ Orientation ratio & Ratio of orientation to 90 degrees \\ Convex area & Number of pixels in convex Image (Figure 8c) \\ Convex area ratio & Ratio of pixels in convex area to pixels in total image \\ Equivalent diameter & Diameter of an equivalent circle with the same area as the region \\ Equivalent diameter ratio & Ratio of Equivalent diameter to 256 \\ Extent & Ratio of pixels in the region to pixels in the total bounding box \\ Solidity & Ratio of area to convex area \\ \hline \hline \end{tabular}
\end{table} 
Table 1: Morphological parameters for connected component analysis. Figure 8: Morphological parameters.