## 2 The Problem of Crack Measurement Based on Machine Vision  
### Computer Vision-Based Measurement System  
Various measurement models based on computer vision have been proposed to detect cracks [30]. Camera imaging models are usually separated into two kinds: the simple pinhole camera model and Gauss camera imaging model. The Gauss camera imaging model is the most suitable model for engineering projects due to the suitable camera focusing expression, and the imaging geometrical relationship of Gauss model is shown in Figure 1. If an object with length \(L\) m is on the target plane, the projection length on the image plane would be \(S\) pixels. The distance between the target plane and optical center \(O\) is object distance \(U\) and usually can be calculated by a laser rangefinder. Image distance \(V\) represents the relationship of optical center \(O\) and the sensor plane, which is usually small, and the value will be affected by the focusing operation of the digital camera. Each point on the target plane will emit two rays: one passes through optical center \(O\) in a straight direction, with the other parallel to the optical axis, refracted by the camera lens, and intersecting with the first ray on the imaging plane. Focal length \(f\) is the distance between optical center \(O\) and the intersection of the second ray and optical axis. The geometric relation between focal length \(f\), object distance \(U\) and image distance \(V\) can be described using Equation (1). \[\frac{1}{U}+\frac{1}{V}=\frac{1}{f}, \tag{1}\]  
where the object distance \(U\) can be obtained by measuring equipment, and the focal length \(f\) is related to lens selection. The image distance \(V\) is calculated as Equation (2). \[V=\frac{Uf}{U-f}, \tag{2}\]  
When the captured image is clear, the image distance is automatically adjusted according to other variables. The pixel length \(S\) can be calculated by the pixel number \(pix\) and unit pixel size \(\varepsilon\) as shown in Equation (3). \[S=pix\cdot\varepsilon, \tag{3}\]If the camera optical axis is perpendicular to the object plane, according to the principle of triangulation, the actual physical width \(L\) can be described by the pixel length \(S\) as Equation (4). \[\frac{L}{U}=\frac{S}{V}\Rightarrow L=\frac{SU}{V}=\frac{pix\times\epsilon(U-f)}{ f}, \tag{4}\]  
Although the imaging formula can be used to represent the object width by measuring the object distance \(U\) and pixel length \(S\), there are many problems that can affect the precision and result of converting a pixel to the actual length. As the adopted Gauss model is idealized and not applicable in practice, there are three main problems. 1. Theoretically, the object distance is the space from the center of the lens \(O\) to the object surface, which is hard to accurately acquire and will cause the error in Equation (4). Moreover, the common range of focal length \(f\) is usually from 0.018 m to 0.2 m, while the error is usually at the centimeter scale; it can be seen that the lower the focal length \(f\), the larger the impact, resulting in an unignorable error. 2. Digital cameras are divided into half and full frame types, and the focal length \(f\) is usually obtained manually. However, the manual focal length \(f\) is different from that in the Gaussian model and should be corrected before measuring, which may cause an incorrect physical width \(L\) in Equation (4). 3. The Gauss camera imaging model calculates the actual physical width \(L\) based on the assumption that the object plane is parallel to the image plane. However, it is difficult to achieve true vertical photographing in the practical applications, as shown in Figure 2a, where the appearance of taking photos from the side is exhibited. The pixel distance \(S\) in Figure 1 can be divided into \(\lambda\) pixels in the horizontal and vertical directions. According to Equation (4), the real distance \(L\) can be directly calculated.