{'fraction_non_alphanumeric': 0.023386342376052385, 'fraction_numerical': 0.007483629560336763, 'mean_word_length': 4.8478632478632475, 'pattern_counts': {'":': 0, '<': 0, '<?xml version=': 0, '>': 0, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
Research and Application for Transmission Line Sag Measurement Method Based on Aerial Image Sequence

Sag is an important parameter of the transmission lines, which directly affects the safe and stable operation of the transmission lines. This paper proposes a new sag measurement method based on the aerial image. It selects the spacer rod on the transmission lines as the recognized target, and adopts the normalized correlation image matching algorithm and the wavelet pyramid layered search strategy to measure the pixel coordinates of the center of the spacer rod in the sequence image. And then this paper measures the three-dimensional space coordinates of the center of the spacer rod according to the active vision technology, and finally calculates the actual sag via the nonlinear least square regression algorithm. The experimental results prove that this method can improve the efficiency of the sag measurement and it is also suitable for application in complex geographical conditions.


INTRODUCTION
Sag is an important parameter of the transmission lines, which directly affects the safe and stable operation of the transmission lines. It is affected by the circuit load, natural environment, weather conditions and other factors, and the size of sag may change at any time, thus causing safety accidents and endangering the safe operation of the surrounding transmission lines. Therefore, there is a need of real-time monitoring for the change of the transmission line sag. The traditional manual inspection method has a high accuracy, but it also has heavy workload and difficult conditions. In particular, the inspection of the transmission lines in a more complex geographical environment requires long time, high labor costs, great difficulty and high risks, and it is almost impossible to do manual operation in an area with a harsh geographical environment.
Some domestic and foreign research institutions and electric power departments have carried out the research on the real-time monitoring of the transmission line sag for many years, and they have developed and produced a variety of devices used for real-timely monitoring the size of sag. The measurement method for real-time monitoring of sag based on the temperature is to calculate the size of sag by selecting the appropriate physical models based on the real-time temperature and stress changes of the transmission lines; the direct measurement method for the sag based on the global positioning system technology obtains a certain achievement in the actual measurement, but it can result in high testing costs, maintenance costs and other problems due to the need of installation of various sensors or detectors in the transmission lines. The unmanned aerial vehicle is used to inspect the transmission lines with the advantages of high efficiency, rapidness, reliability, low cost and without the impact of geographical environment. This method has become an important way to inspect the transmission lines in China. The image information of the transmission lines is captured by visible and infrared light, including digital images, sequence images and infrared images, which contain the basic features and motion state information of the transmission lines, so as to determine the basic operational state of the transmission lines through processing these images, and timely discover equipment defects and hidden faults. This paper proposes a new kind of transmission line sag measurement method-transmission line sag measurement method based on the aerial image. The method with simple operation and high accuracy is free of the impact of the geographical environment and installation of a variety of specific equipment.

Sag measurement process
Sag refers to the distance between the lowest point of the overhead conductor and the suspension point on two adjacent towers at the vertical direction. When the height of the conductor suspension point on two adjacent towers is consistent, the vertical distance between the lowest point of the conductor and the suspension point is sag; if the height of the conductor suspension point on the tower is not the same, there are two sags, which are respectively called as the maximum sag and the minimum sag. The hyperbola is the closest to the shape of sag. The traditional measurement method is to calculate the coordinate of the lowest point within a span by observing the data processing, that is, the size of sag, as shown in Figure 1: In the inspection process, the unmanned aerial vehicle can shoot a complete set of inspection video. The shooting process of the unmanned aerial vehicle is constantly moving, and the location in front and back of the image will also change, thereby obtaining different viewpoints of images under the same scene. This process is equivalent to a binocular imaging process. According to the active vision principle, its spatial position coordinates, namely, the space coordinates from P1 to P6 as shown in Figure 1 can be calculated; according to the data regression algorithm, a space curve equation for the transmission lines within the span can be obtained, thus calculating the size of transmission line sag. The detailed process is shown in Figure 2.

Sag algorithm based on active vision
The camera is constantly moved in the process of shooting image. This process is also known as an active visual process. A group of images at different viewing angles under the same scene can be obtained according to the active vision measurement model. The information of the three-dimensional coordinates of the feature points in the image can be calculated by the principle of the trigonometric survey. Figure 3 is a diagram of the active vision imaging model of a single camera. C1 and C2 represent lens centers of two-frame images in the front and back; Z1 and Z2 are mutually parallel, which are the optical axis of the camera; f is the effective focal length of the lens; d is the camera spacing corresponding to two-frame images. When the unmanned aerial vehicle flies along the axis of X, the internal parameters captured by the camera are the same, and the external parameters only have a translation d on the axis of X. Figure 3 shows the relationship between the coordinate systems of two cameras and the coordinate systems of images.
If the coordinate of the point P in the camera C1 is (xp, yp, zp), and the coordinates of the point P on two imaging planes are respectively P1(u1, v1) and P2(u2, v2), the three-dimensional coordinates of P can be obtained according to the imaging relation of the pinhole model: Two image points P1 (u1, v1) and P2 (u2, v2) obtain the coordinates of the space point p under the condition of the camera space d by the image matching algorithm.

Space curve fitting and sag measurement of the transmission lines
In the high-voltage transmission lines, there are generally five to nine spacer rods within a span. The above model can be used to calculate the space coordinates (xi, yi, zi) (i = 1, 2, 3, ...) of these points, P1, P2, P3, ..., and also calculate the coordinates of the suspension point in front and back of the tower, and then the data regression method can be used to calculate a space curve equation of the transmission lines within a span. Here, we use a parabolic equation to represent the transmission line equation, and the specific equation is as follows: In the Formula, y is the vertical coordinate of a point on the transmission lines, x is the distance between two towers, a0, a1 and a2 are coefficients to be determined. Assuming that there are five feature points, the function value at these points, P1, P2, P3, ... isy(xi)= a0+a1xi+a2xi 2 . Assuming that there are five feature points, Where, yi is the vertical coordinate of the center of the spacer rod. The non-linear least square regression algorithm can be used for fitting the coordinate data in the center of spacer rods and calculating the values of the parameters a0, a1 and a2, so as to obtain a space curve equation and calculate the size of sag, that is, the maximum value of y.

THREE-DIMENSIONAL COORDINATE
MEASUREMENT ALGORITHM

Image matching algorithm
The image matching is a process to analyze the similarity and consistency of two images and multiple images through a certain matching algorithm. This paper adopts the traditional template matching method as an image matching algorithm, which is a high-precision and widely-used algorithm. The template matching methods includes the variance method, normalized cross-correlation matching method, least square error method, ABS algorithm and image moment matching algorithm and so on. This paper adopts the normalized cross-correlation matching method, with the following specific algorithm: In the above formula, G(i, j) is the pixel gray of the template image at the point of (i, j); F(i, j) is the pixel gray of the image to be matched at the point of (i, j); N (u, v) is the correlation coefficient at the point (u, v).
This paper adopts the wavelet image pyramid layered search strategy to improve the success rate of matching and reduce the amount of calculation. In this paper, we first adopted the wavelet pyramid layered search from roughness to fineness to gradually break down the template images and the images to be matched in order to obtain a pyramid structure which is from small to large with a resolution ratio from high to low; second, we conducted rough matching for the layers with a resolution rate and then obtained a of the image, and we regarded the rough position as a guide to match again and gradually narrowed the search area; with the improvement of the resolution ratio, the matching accuracy also continues to be improved and finally achieve matching that meets the accuracy requirements. The research shows that, the wavelet image pyramid matching algorithm currently has the highest success rate and fastest speed in the matching algorithm.

3D coordinate measuring algorithm
According to the principle of stereoscopic vision, the image point coordinates P1(u1, v1) and P2(u2, v2) of the feature points in front and back of the images can be determined by the image pair after image matching, so as to measure 3D coordinates.
The internal and external parameters of the camera can be determined according to the camera calibration algorithm, and the camera transformation model from 3D coordinate system to the two-dimensional coordinate system of the image can be achieved through the following steps according to the principle of pinhole imaging:1)3D coordinate system is transformed into a coordinate of the space coordinate system; 2) the pinhole perspective of the space coordinate system is transformed into a pinhole perspective of the plane coordinate system of the image; 3) the image coordinate system is transformed into the pixel coordinate system; 4) the actual image coordinate is transformed into a computer image coordinate. Thus, the relationship between the world coordinate (xw, yw, zw) and the image coordinate (u1, v1): (4) ZC represents Z axis of the camera coordinate system; R and T respectively represent the rotation matrix and the translation of the camera; dx and dy are respectively the physical size of each pixel along the X axis and Y axis; the parameters in M4×3 matrix can be obtained by camera calibration method, and then the internal and external parameters of the camera can be calculated by the nonlinear optimization algorithm. In the UAV inspection process, the spatial position of the camera can be provided by GPS, and the differential dynamic positioning technology can be used with a high positioning accuracy; the camera attitude parameters can be acquired by the airborne sensor, thus obtaining the spatial location corresponding to two images which are acquired in the front and back.
Assuming that the two-dimensional coordinates of the feature point P of the transmission line are (u1, v1) and (u2, v2), and four linear equations can be obtained by the formula (4): The above formula includes the elements of two-image projection in the matrix. The superscripts 1 and 2 respectively represent the image in the front and back.
According to the least squares method, X=(C T C -1 )C T D (6) Thus we obtain the space coordinate of the feature point P, namely, (xw, yw, zw).

Camera calibration error and processing
In the actual imaging process, the camera is not in strict accordance with the principle of pinhole imaging, so there is a certain error. This paper adopts the camera calibration method to make the checkerboard pattern template as a calibration template, usually with an error of 3% to 5%. Therefore, in the calibration process, there is a need to take fully into account the nonlinear characteristics of the camera imaging, especially the impact of distortion on the calibration accuracy. The nonlinear optimization algorithm can be used to control the error range within 1% to 3%.

Camera position error and processing
From the above analysis, 3D coordinates of the space point P are obtained by calculation of the image point coordinates of the aerial sequence images. Therefore, the location parameters of the camera have a great impact on the final measurement results. In the actual measurement, it is very difficult to precisely determine the position parameters of the camera, and the error is inevitable mainly because: 1) There is an error of included angle between the optical axis of the camera; the included angle of the optical axis has the largest impact on Z axis while relatively small impact on X axis and Y axis. Therefore, a correction factor is added in the measurement results in order to compensate for the error of the included angle. 2) There is an impact of the baseline distance (d) between the center of optical perspective in front and back of the camera; according to the principle of the stereoscopic vision measurement, the greater the d is, the smaller the error is. Therefore, there is a need to increase the distance (d) in the event of determination of the sequence images. UAV carries out inspection at a speed of 20 to 40km/h, and the camera can capture 25-frame images per second, the distance (d) between adjacent two-frame images is 22 to 44cm. If GPS is only used to locate, the error is up to 4cm. Therefore, the heading or speed must be corrected so that the error can be reduced by half. 3) There is an impact of the camera shooting distance. The farther the distance between camera shooting and 3D coordinate measurement is, the smaller the parallax angle is, and the greater the measurement error is. Therefore, there is a need to increase the baseline distance and widen the perspective as much as possible, so as to compensate for the position error of the camera.

Image matching error and correction
In the process of image matching, the best matching feature points obtained are not actually the matching features due to the impact of the matching algorithm, noise, geometric distortion, image gray and other factors, thus leading to matching errors. In the matching process, the matching error is set as 0.5 pixels, the accuracy rate of matching will rise to over 90%, and the matching speed is relatively fast. To improve the resolution ratio of the image can effectively improve the matching accuracy.

EXPERIMENTAL VERIFICATION
In order to verify the effectiveness of this method, the experiment simulates the working condition of UAV inspection. Assuming that the shooting angle of the camera is depression angel which is 45°, and the straight-line distance moves horizontally at the position of 4cm, 6cm, 8cm, 10cm and 12cm; the base length is 30cm. Therefore, the rotation matrix of external parameters in the matrix is shown as follows: The balanced matrix is: T= (300, 0, 0) T The above calibration algorithm is used to calculate the internal parameters of the camera: Thus, the three-dimensional space coordinates of five feature points are shown in the Table 1.
According to the provisions of the overhead sag measurement error in the national standard GBJ233-90, the allowable deviations of the lines at110kV and below are +5% and −2.5%; the allowable deviation of the lines at 220kV and above is ± 2.5%. As can be seen from the calculation results in above table, the accuracy of data calculated by this method is in line with the national standards.

CONCLUSION
Based on the aerial images of the transmission lines in inspection, this paper calculates the size of sag of the transmission lines by using the digital images captured in the process of UAV inspection and the algorithm stated in this paper through the stereoscopic vision technology of the computer, so as to avoid drawbacks of artificial methods, conduct the effective monitoring for the key equipment and environment of the transmission lines, realize the real-time early warning for the reliability of the equipment, and further enhance the required management and the condition overhaul of related equipment in the power transmission network, thus improving the asset utilization ratio and reducing the accident rate.