# Visual Ranging Based on Object Detection Bounding Box Optimization
## 4 Experimental Results and Analysis
### Ranging Results and Analysis  
In order to verify the effectiveness of the proposed similar triangle ranging method based on height difference, a ranging experiment is carried out on the basis of the results of the object detection bounding box optimization. In this experiment, the known height difference h = 10 cm and the pitch angle \(\alpha\) = 12\({}^{\circ}\).  
In Table 4, the results of similar triangle ranging based on height difference are shown. The results show that the relative error within 6 m is 0.7-2.47% after optimization, indicating that this ranging method can achieve more accuracy.  
Figure 10 visually presents a clear comparison of the ranging accuracy before and after bounding box optimization at different distances. Additionally, Figure 11 illustrates the distance visualization before and after optimization for serial number 1. It is evident that the optimized ranging results are much closer to the actual values. This finding further serves to validate the feasibility of the bounding box optimization method proposed in this research paper.  
\begin{table}
\begin{tabular}{c c c c c} \hline \hline
**Serial** & \multicolumn{2}{c}{**Image at O\({}^{\prime}\) Point**} & \multicolumn{2}{c}{**Image at O\({}^{\prime\prime}\) Point**} \\
**Number** & **WOV** & **HOV** & **WOV** & **HOV** \\ \hline
1 & 2.32\% & 1.43\% & 1.28\% & 1.75\% \\
2 & 2.22\% & 0.24\% & 2.05\% & 0 \\
3 & 3\% & 2.7\% & 1.19\% & 0.27\% \\
4 & 4.47\% & 3.38\% & 3.41\% & 5.41\% \\
5 & 8.92\% & 3.38\% & 3.86\% & 1.49\% \\
6 & 3.21\% & 6.98\% & 2.07\% & 4.19\% \\
7 & 7.79\% & 5.29\% & 2.75\% & 8.54\% \\
8 & 12.38\% & 12.14\% & 11.27\% & 10.46\% \\
9 & 19.24\% & 9.39\% & 14.07\% & 8.44\% \\ \hline \hline \end{tabular}
\end{table}
Table 3: Results of object detection bounding box optimization.  
Figure 9: The changes in pixel width and pixel height before and after bounding box optimization: (**a**) change in the image at point O\({}^{\prime}\); and (**b**) change in the image at point O\({}^{\prime\prime}\).  
\begin{table}
\begin{tabular}{c c c c c c c c c} \hline \hline  & \multicolumn{6}{c}{**Image at O\({}^{\prime}\) Point**} & \multicolumn{6}{c}{**Image at O\({}^{\prime\prime}\) Point**} \\ \cline{2-9}
**Serial** & **Actual** & **Ranging** & **Ranging** & **Relative** & **Actual** & **Ranging** & **Ranging** & **Relative** \\
**Number** & **Distance** & **before Optimization** & **after Optimization** & **Error after Optimization** & **Distance** & **before Optimization** & **after Optimization** & **Error after Optimization** \\
6 & 352.36 & 333.42 & 345.28 & 2.01\% & 354.54 & 342.35 & 350.35 & 1.18\% \\
7 & 426.94 & 320.99 & 417.15 & 2.29\% & 427.93 & 339.37 & 418.19 & 2.27\% \\
8 & 459.74 & 430.26 & 448.98 & 2.34\% & 461.22 & 439.39 & 452.7 & 1.84\% \\
9 & 501.65 & 375.32 & 489.22 & 2.47\% & 502.56 & 400.82 & 490.93 & 2.31\% \\ \hline \hline \end{tabular}
\end{table}
Table 4: Results of ranging with height difference of 10 cm and pitch angle of 12\({}^{\circ}\).  
Figure 11: _Cont._  
Figure 10: Comparison of ranging accuracy before and after bounding box optimization at different distances: (**a**) comparison of ranging accuracy at point O\({}^{\prime}\); and (**b**) comparison of ranging accuracy at point O\({}^{\prime\prime}\).