# Pothole Classification Model Using Edge Detection in Road Image
## 4 Result and Performance Evaluation
### Performance Evaluation
This is a method of comparing luminance (l), contrast (C), and structure (\(S\)) of two images when there are an original image X and a distorted image Y. Luminance represents the degree of brightness of an object reflected from and to a light source or the brightness of a device display. Contrast refers to the standard deviation value of an image. Structure means the value obtained by subtracting the average brightness from the image and dividing it by the standard deviation. Equation (5) represents SSIM. \[\text{SSIM}(\text{a},\text{b})=\frac{\left(2\mu_{a}\mu_{b}+C_{1}\right)+\left( 2\sigma_{ab}+C_{2}\right)}{\left(\mu_{a}^{2}+\mu_{y}^{2}+C_{1}\right)\left( \sigma_{a}^{2}+\sigma_{b}^{2}+C_{2}\right)} \tag{5}\]  
The SSIM has values from \(-1\) to \(+1\), and being closer to \(+1\) means that it matches the original. In addition, \(\mu_{a}\) and \(\mu_{b}\) mean the internal average of pixels in each image, \(\sigma_{a}\) and \(\sigma_{b}\) mean the internal standard deviation of pixels in each image. Also, \(\sigma_{ab}\) means the internal covariance of pixels in the image. The image data with potholes is used for performance evaluation. This uses image data of pothole-related news from news data provided by KBS (Korea Broadcasting System) [49], YTN [50], and SBS (Seoul Broadcasting System) [51]. Accordingly, each data set is converted to a gray-scale, and the YOLO algorithm is used to detect objects. In addition, the detected object is removed and processed as a background to use the pre-processed data set. Through the proposed method, the edge of the pothole is detected and the degree of loss when restoring to the original data is evaluated. Table 2 shows the results of the performance evaluation of the distortion rate and the restoration rate for the pothole image. The result of the evaluation shows errors of 0.2 to 0.44 in MSE. The PSNR was evaluated as 52 db or more. In addition, the SSIM was evaluated as 0.71-0.82. Therefore, it can be seen that image loss can be reduced and potholes can be accurately predicted through the proposed method. The second performance evaluation evaluates the validity of the pothole classification model and the accuracy of the classification results. Accuracy of pothole detection is evaluated in the image through the proposed model. Table 3 shows the results of pothole classification accuracy using the proposed model. The configuration shows the ratio of potholes, cracks, and others (people, cars, buildings, etc., except for cracks and potholes) in the pothole image to be analyzed. \begin{table}
\begin{tabular}{c c c c c c} \hline \hline
**NO.** & **DATA** & **MSE** & **Gray-Scale\_MAX** & **PSNR** & **SSIM** \\ \hline
1 & Pothole\_1 & 0.4235 & 195 & 53.2636 & 0.7123 \\
2 & Pothole\_2 & 0.3751 & 205 & 54.7521 & 0.7186 \\
3 & Pothole\_3 & 0.4413 & 241 & 54.7457 & 0.7887 \\
4 & Pothole\_4 & 0.3345 & 288 & 58.6999 & 0.7523 \\
5 & Pothole\_5 & 0.2189 & 199 & 59.1721 & 0.8123 \\
6 & Pothole\_6 & 0.2012 & 187 & 59.3643 & 0.8004 \\
7 & Pothole\_7 & 0.3158 & 138 & 52.8093 & 0.7989 \\
8 & Pothole\_8 & 0.3123 & 197 & 50.9436 & 0.8231 \\
9 & Pothole\_9 & 0.4123 & 207 & 50.1672 & 0.7982 \\
10 & Pothole\_10 & 0.2225 & 220 & 53.3751 & 0.7785 \\ \hline \hline \end{tabular}
\end{table} 
Table 2: The results of the evaluation of the distortion rate and the restoration rate. As a result of the classification accuracy in Table 3, pothole_4 and pothole_5 have potholes, but their accuracy is evaluated to be low, so it is predicted that there is no pothole. In the case of pothole_4, there are many cracks in the image compared to the pothole. Accordingly, it is difficult to detect potholes. In addition, since the pothole does not exist clearly, the accuracy was evaluated low because the edge extraction using edge detection was not performed properly. In the case of pothole_5, potholes, cracks, and shadows exist at the same time. However, since cracks and shadows exist around the pothole, the accuracy was evaluated low because the edge was extracted as part of the pothole during the edge detection process.