A metro contact net conductive rail abrasion measuring method

By integrating a camera and light source onto a wear detection vehicle, and utilizing the YOLOv8 model and wavelet transform technology, combined with illumination enhancement and grayscale processing, the problem of low accuracy in wear detection of subway contact wire conductive rails was solved, achieving efficient and accurate wear detection and measurement.

CN120953243BActive Publication Date: 2026-02-03CHINA RAILWAY CONSTR ELECTRIFICATION BUREAU GRP CO LTD +5
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202511126947.1
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-08-13
Publication Date
2026-02-03
Estimated Expiration
2045-08-13

AI Technical Summary

Technical Problem

Existing technologies for detecting wear on the conductive rails of subway contact networks have low accuracy, manual inspection is inefficient and of unstable quality, making it difficult to achieve full coverage. Furthermore, machine vision methods are not accurate enough under conditions of uneven lighting and poor image quality.

Method used

A wear inspection vehicle equipped with a camera and light source is used to identify defects through the YOLOv8 model. Combined with image processing and geometric rotation data enhancement, real-time illumination enhancement, wavelet transform denoising and weighted average grayscale processing are used to construct a training set and perform wear defect detection.

Benefits of technology

It improves the accuracy and efficiency of wear defect detection, achieves full coverage detection of conductive rails, reduces visual fatigue, enhances the model's adaptability to changes in lighting and attitude fluctuations, and enables precise location and measurement of defects.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure FT_1
    Figure FT_1
  • Figure FT_2
    Figure FT_2
  • Figure FT_3
    Figure FT_3
Patent Text Reader

Abstract

The application discloses a metro contact net conductive rail abrasion measurement method, and relates to conductive rail abrasion detection, comprising the following steps: collecting contact net conductive rail image data through a camera; performing gray scale and denoising processing on the collected image data; training an abrasion defect detection model based on a YOLOv8 model to predict the type and position information of the abrasion defect; sending the predicted type and position information of the abrasion defect to the control system of an abrasion detection trolley; according to the defect position information, the control system obtains the position coordinates of the defect by using the positioning system of the abrasion detection trolley; according to the position coordinates of the defect, the control system of the abrasion detection trolley controls the abrasion detection trolley to move to the defect position, and then the abrasion measurement device arranged on the abrasion detection trolley is used to measure the abrasion degree of the contact net conductive rail to obtain abrasion measurement data. The abrasion defect detection precision is improved in the application, and the problem of low abrasion detection precision of the metro contact net conductive rail in the prior art is solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of conductive rail wear detection, and in particular to a method for measuring the wear of conductive rails in subway contact networks. Background Technology

[0002] With the rapid development of urban rail transit and the continuous growth of operating mileage and passenger volume, higher requirements are being placed on train operation safety and power supply reliability. As a key component of the train traction power supply system, the physical contact and current transmission between the subway catenary's conductive rails and pantographs inevitably cause wear on the surface of the conductive rails. Long-term accumulated wear can lead to problems such as poor contact and arcing, seriously threatening train operation safety. To ensure the safe and stable operation of the catenary, it is necessary to regularly inspect and evaluate the wear condition of the conductive rails and promptly identify and address serious wear defects.

[0003] Currently, wear detection of subway overhead contact line rails mainly relies on manual visual inspection. Maintenance personnel ride in an overhead contact line maintenance vehicle, manually observing the surface condition of the rails along the line. If severely worn areas are found, they disembark to grind or replace the rails. This traditional inspection method suffers from low efficiency, high labor intensity, and inconsistent inspection quality. Maintenance personnel are prone to visual fatigue due to prolonged exposure to the moving and bumpy environment of the maintenance vehicle, making it difficult to effectively identify minute defects. Furthermore, the large spatial span of the overhead contact lines means that manual inspection often only allows for spot checks of visible sections, making full coverage inspection difficult and easily overlooking localized wear defects.

[0004] With the development of machine vision and artificial intelligence technologies, it has become possible to automatically detect wear defects by acquiring images of conductive rails using visual sensors and employing image processing and pattern recognition methods. Some scholars have conducted exploratory research on this topic. For example, some scholars have proposed a wear detection method based on gray-level co-occurrence matrix texture features and support vector machines (SVM), extracting texture features from the conductive rail surface and constructing an SVM classifier to achieve defect identification. However, these methods mainly rely on manually designed feature descriptors, which have limitations such as insufficient feature representation ability and poor model generalization. Other scholars have explored using convolutional neural networks (CNNs) to automatically learn hierarchical features from conductive rail images and construct deep learning detection models. However, due to the lack of large-scale labeled data and interference factors such as uneven lighting and poor image quality in real-world scenarios, the detection accuracy is difficult to meet the requirements of engineering applications. Summary of the Invention

[0005] To address the issue of low accuracy in detecting wear on the conductive rails of subway contact networks in existing technologies, this application provides a method for measuring wear on the conductive rails of subway contact networks. This method involves acquiring image data after light source enhancement, using a YOLOv8 model to identify and locate defects, and optimizing the detection model using image processing and geometric rotation data enhancement methods, thereby improving the accuracy of wear defect detection.

[0006] The purpose of this application is achieved through the following technical solution.

[0007] This application provides a method for measuring the wear of subway contact wire conductive rails, comprising: placing a wear detection trolley equipped with a camera and a light source on a subway contact wire conductive rail busbar, controlling the wear detection trolley to move along the busbar, and acquiring contact wire conductive rail image data through the camera; preprocessing the acquired image data, including grayscale conversion and noise reduction; constructing a training set using contact wire conductive rail image data labeled with wear defect types and locations, and training a wear defect detection model based on the YOLOv8 model; inputting the preprocessed image data into the trained wear defect detection model to identify wear defects in the images and predict the type and location information of the wear defects; sending the predicted wear defect type and location information to the control system of the wear detection trolley, and the control system using the positioning system of the wear detection trolley to obtain the location coordinates of the defects based on the defect location information; the control system controlling the wear detection trolley to move to the defect location based on the defect location coordinates, and measuring the wear degree of the contact wire conductive rail through a wear measurement device equipped on the wear detection trolley to obtain wear measurement data.

[0008] Furthermore, a wear detection trolley equipped with a camera and light source is placed on the subway contact network conductive rail busbar. The camera collects image data of the contact network conductive rail, including: an illuminance sensor is installed on the wear detection trolley to collect the ambient light intensity within a preset collection range during the trolley's movement on the busbar; the collected ambient light intensity is compared with a preset light threshold; wherein the light threshold is determined based on the reflectivity of the contact network conductive rail material and the camera's exposure parameters; when the collected ambient light intensity is lower than the light threshold, the light source is controlled to provide illumination enhancement; and the camera continuously collects image data of the contact network conductive rail at a preset frame rate and exposure parameters.

[0009] Specifically, the illumination threshold is determined based on the reflectivity of the contact wire rail material and the preset exposure parameters of the camera. This includes: measuring the reflectance spectrum data of contact wire rails of different materials under different illumination intensities using a spectrophotometer in the operating environment of the contact wire rails; calculating the reflectivity parameters of each material based on the reflectance spectrum data; testing the image exposure parameters of the camera under different illumination intensities using a standard light source and an illuminance meter; calculating the correspondence between the camera's exposure and the ambient light intensity based on the reflectivity parameters of the contact wire rail material and the correspondence between the camera's exposure and the ambient light intensity; establishing a mapping model between ambient light intensity and image exposure based on the reflectivity parameters of the contact wire rail material and the correspondence between the camera's exposure and the ambient light intensity; calculating the optimal ambient light intensity range for each material of contact wire rail based on the preset image exposure range; and using the lower limit of the optimal ambient light intensity range as the illumination threshold for each material of contact wire rail.

[0010] Specifically, a mapping model between ambient light intensity and image exposure is established, including: establishing a light-exposure mapping model based on the principles of physical optics imaging, using a light intensity transfer function and a camera response function to establish a mathematical mapping relationship between ambient light intensity and image exposure; taking a preset image exposure range as input, using the light-exposure mapping model to calculate the corresponding ambient light intensity range, and using the obtained ambient light intensity range as the optimal ambient light intensity range for camera imaging under the current contact wire conductive rail material; and establishing a light-exposure mapping model based on the principles of physical optics imaging, using a light intensity transfer function and a camera response function to establish a mathematical mapping relationship between ambient light intensity and image exposure, including: selecting a light intensity transfer function, which describes the functional relationship between the ambient light intensity incident on the camera lens and the reflected light intensity from the contact wire conductive rail surface, wherein the ambient light intensity incident on the camera lens depends on the ambient light intensity. The brightness of the reflected light from the contact wire rail surface depends on the incident light brightness and the reflectivity of the contact wire rail material, along with the aperture size of the camera lens. A camera response function is selected, which describes the functional relationship between the brightness of the reflected light from the contact wire rail surface and the image exposure. The image exposure depends on the brightness of the reflected light entering the imaging device inside the camera and the camera's exposure time. Ambient light intensity, aperture size, and exposure time are set as input parameters of the model, reflectivity is set as the material characteristic parameter of the model, and image exposure is set as the output parameter of the model. The output of the brightness transfer function is equal to the input of the camera response function, thus constructing an ambient light intensity-image exposure mapping model based on physical optical processes. The camera aperture size and exposure time are fixed to preset constant values ​​and substituted into the mapping model, while retaining ambient light intensity and reflectivity as input parameters. This simplifies the mapping model to a simplified mapping model with ambient light intensity and reflectivity as input and image exposure as output, which is used for subsequent calculation of the optimal ambient light intensity range.

[0011] Furthermore, the acquired image data undergoes grayscale processing, including: using a weighted average method to sum the pixel values ​​of the RGB channels of the acquired image data to obtain a grayscale image. The weighted summation formula is as follows: Where Gray represents the pixel value of the grayscale image, and R, G, and B are the pixel values ​​of the red, green, and blue channels of the acquired image data, respectively. , , These are the weighting coefficients for the three channels.

[0012] Furthermore, the acquired image data undergoes denoising processing, including: performing a four-level wavelet decomposition on the grayscale catenary rail image using the db4 wavelet basis function to obtain the low-frequency subband coefficients and high-frequency subband coefficients of each level; and calculating the global grayscale mean of the grayscale image based on the high-frequency subband coefficients of each level. and global grayscale standard deviation : , ,in, Let M be the grayscale value of the pixel in the i-th row and j-th column of the grayscaled conductive track image, and M and N be the number of rows and columns of the image, respectively. Divide the grayscaled image into S×S non-overlapping local blocks, where S ranges from 8 to 32. For each local block, calculate the local grayscale mean. and local grayscale standard deviation : , ,in, Let the grayscale value of the pixel in the m-th row and n-th column of a local patch be denoted; calculate the local texture richness of each local patch. : , where ε is a non-negative small constant; Used to characterize the richness of the surface texture of the conductive rails within local small blocks; calculates the average local texture richness of the conductive rail image after grayscale conversion. : ,in, Reflects the overall richness of the conductive track texture; calculates global texture richness. : Based on the standard deviation of the high-frequency subband coefficients of each layer, the basic denoising threshold of the corresponding layer is calculated. : , where σ is the standard deviation of the wavelet coefficients within the corresponding high-frequency detail subband, and P and Q are the number of rows and columns of the corresponding subband, respectively.

[0013] Using the basic denoising threshold Adaptive adjustment is performed to obtain the final denoising threshold for each high-frequency detail subband. The calculation formula is: Where λ is the threshold adjustment intensity factor, α is the threshold adjustment sensitivity factor, and β is the threshold adjustment nonlinearity factor, and the values ​​of λ, α, and β range from [0.1, 0.5], [10, 50], and [0.5, 2], respectively; the absolute value within each high-frequency subband is less than the corresponding final threshold. The wavelet coefficients are set to zero to obtain the denoised high-frequency subband coefficients. The wavelet coefficients of each layer after denoising are subjected to inverse wavelet transform to reconstruct the grayscale image of the contact wire rail after denoising.

[0014] Furthermore, a training set was constructed using contact wire rail image data labeled with wear defect types and locations to train a wear defect detection model based on the YOLOv8 model. This included: acquiring preprocessed contact wire rail image samples and constructing a labeled image sample set; selecting the YOLOv8 model as the basic architecture of the wear defect detection model, which includes a backbone network, a neck network, and a detection head; the backbone network adopts a ResNet structure to extract multi-scale features from the image; the neck network adopts an SPP and PANet structure to fuse the multi-scale feature information extracted by the backbone network; the detection head adopts a YOLOv3 head structure to predict the bounding box and class probability of the wear defect target based on the fused multi-scale feature information; and using the constructed image sample set, the model was trained on the basis of the YOLOv8 pre-trained model through transfer learning to obtain an optimized model for the contact wire rail wear defect detection task.

[0015] Furthermore, constructing an annotated image sample set includes: acquiring preprocessed contact wire rail image samples, and annotating wear defect areas in the image samples according to preset defect types. The annotation content includes the bounding box coordinates of the defect type and defect location. Obtain the labeled image sample set For the labeled image sample set Geometric rotation data augmentation is performed on each image sample Img and its corresponding defect bounding box label to obtain the rotated augmented image sample. and tags Image samples after geometric rotation data augmentation and tag data Verification is performed to remove invalid samples where the conductive rail target is incomplete or the defective bounding box exceeds the limit due to rotation, resulting in a rotation-enhanced image sample set. ; Image sample set and The images were merged into a labeled dataset for training the YOLOv8 wear defect detection model.

[0016] Furthermore, geometric rotation data augmentation includes: randomly generating rotation transformation parameters based on the geometric center of the image sample Img to be augmented, the rotation transformation parameters including the coordinates of the rotation center. and rotation angle θ; where the coordinates of the rotation center are... The geometric center of the image sample Img to be enhanced is set, and the rotation angle θ is randomly selected within a preset range of -30° to 30°, corresponding to the pitch and yaw angle fluctuations of the camera during the operation of the wear detection vehicle. Based on the rotation transformation parameters, an affine transformation is used to geometrically rotate the image sample Img, resulting in the rotated image. ; Calculate the image after rotation transformation The top left corner coordinates of the bounding box and the coordinates of the bottom right corner And calculate the width of the bounding box based on its coordinates. and height Set a blank image (Blank) with the same size as the original image sample Img to be enhanced, and dimensions (W, H); calculate the image after rotation transformation. Starting coordinates in the blank image Blank , making To center an element in Blank, the starting coordinates must satisfy the following formula: , Where W and H are the width and height of the image sample Img to be enhanced, respectively;

[0017] Copy the rotated image Img_rot to the corresponding position in the blank image Blank, starting at coordinates [coordinates to be filled in]. The size of the copied region is To obtain geometrically rotated enhanced image samples ;

[0018] Obtain the defect bounding box label (Label) from the image sample Img to be enhanced, containing the coordinates of the defect bounding box. Based on the rotation transformation parameters, an affine transformation is used to rotate the coordinates of the defect boundary box, resulting in the rotated coordinates of the defect boundary box. ;

[0019] Based on the rotated defect boundary box coordinates and the initial coordinates Calculate the image samples after rotation enhancement Coordinates of the defect bounding box The calculation formula is as follows: ; ; ; Output geometrically rotated image samples and corresponding defect bounding box labels ,in, Includes the coordinates of the defect bounding box after rotation enhancement .

[0020] Furthermore, affine transformations satisfy the rotational transformation formula: Where (x, y) are the coordinates of a pixel in the image to be rotated. These are the coordinates of the corresponding pixel in the image after rotation transformation.

[0021] Specifically, The homogeneous coordinates of a pixel in the image to be rotated are: (x, y) are the coordinates of the pixel in the image coordinate system; 1 is the scale factor of the homogeneous coordinates, used to represent the position of the point. In affine transformations, homogeneous coordinates can be used to represent translation transformations using matrix multiplication, which is convenient for calculation. By adding an extra dimension to the coordinates, the two-dimensional coordinates are extended to three-dimensional homogeneous coordinates, and translation and rotation transformations can be uniformly represented as matrix multiplication. Represents the homogeneous coordinates of the corresponding pixel in the image after rotation transformation: is the coordinate of the pixel in the rotated image coordinate system; 1 is also the scale factor for homogeneous coordinates. The matrix in the rotation transformation formula... , is a transformation matrix that combines rotation and translation, where: θ is the rotation angle; These are the coordinates of the rotation center. This is achieved by using the homogeneous coordinates of the pixels in the image to be rotated. Multiplying by this transformation matrix yields the homogeneous coordinates of the corresponding pixels in the rotated image. This process enables the rotation of the image.

[0022] Furthermore, the location coordinates of the defect are obtained, including:

[0023] Coordinates of the defect bounding box predicted by the wear defect detection model Calculate the pixel coordinates of defects in the overhead contact line rail image. : , ,in, The normalized center coordinates of the defect bounding box predicted by the wear defect detection model are defined, with values ​​ranging from [0, 1]. W and H represent the width and height of the contact wire conductive rail image, respectively. The current position coordinates of the wear detection trolley on the contact wire conductive rail busbar are obtained when the defect image is captured. ,in These are the position coordinates along the busbar direction. The position coordinates are perpendicular to the busbar direction. The height coordinates of the wear detection vehicle relative to the busbar; the current position coordinates of the wear detection vehicle are obtained through the encoder or GPS system equipped on the wear detection vehicle. The intrinsic parameter matrix K and extrinsic parameter matrix of the pre-calibrated camera are acquired. The intrinsic parameter matrix K contains the focal length of the camera and the coordinates of the principal point, while the extrinsic parameter matrix... It includes the rotation matrix R and translation vector t of the camera relative to the wear detection vehicle.

[0024] Furthermore, obtaining the location coordinates of the defect also includes: based on the camera's intrinsic parameter matrix K and extrinsic parameter matrix... And the pixel coordinates of the defects in the camera-captured images. The three-dimensional coordinates of the defect in the wear inspection trolley coordinate system are calculated using the following formula. : Where s is the scale factor; the three-dimensional coordinates of the defect in the wear inspection trolley coordinate system are... The following formula can be used to convert the defect's position coordinates in the busbar coordinate system. : Output the position coordinates of the defect in the busbar coordinate system. The data is then sent to the control system of the wear detection vehicle as the coordinates of the located defect.

[0025] Specifically, This represents the homogeneous coordinates of the pixel coordinates of the defect in the image captured by the camera. Where: and These represent the x and y coordinates of the defect in the image, respectively; the last element, 1, is the scale factor for the homogeneous coordinates, used to indicate the position of the point. This represents the homogeneous coordinates of the defect in the three-dimensional coordinate system of the wear inspection carriage. Where X, Y, and Z represent the three-dimensional coordinates of the defect in the wear inspection carriage coordinate system; the last element, 1, is also the scale factor for the homogeneous coordinates. Formula This describes the mapping relationship between pixel coordinates and 3D coordinates. Where: K is the intrinsic parameter matrix of the camera, containing information such as focal length and principal point coordinates; is the extrinsic parameter matrix of the camera relative to the coordinate system of the wear detection vehicle, which consists of the rotation matrix R and the translation vector t; s is a scale factor.

[0026] Compared to existing technologies, the advantages of this application are:

[0027] In the grayscale conversion of the conductive rail image, a weighted average method is used to convert the RGB three channels to a grayscale image. Inter-class variance thresholding is employed to segment the conductive rail target from the background, reducing redundant information in the image data and highlighting effective features such as texture and edges of the conductive rail target. In the denoising process, the multi-scale and multi-directional characteristics of wavelet transform are utilized to perform multi-level wavelet decomposition of the image. The threshold is adaptively adjusted based on the high-frequency detail coefficients, effectively filtering out high-frequency noise while preserving texture details to the maximum extent.

[0028] A geometric rotation data augmentation strategy is introduced to simulate the fluctuations in camera posture during the operation of a wear detection vehicle. Based on the geometric center of the image to be augmented, rotation parameters are randomly generated within a reasonable range. The affine transformation formula is used to rotate the original image and its labels. The transformed image is then merged with the original image. This approach expands the amount of small sample data, alleviating the dependence of deep model training on a large number of labeled samples. Furthermore, it simulates the changes in image perspective caused by the posture fluctuations of the wear detection vehicle during actual data acquisition, enhancing the adaptability of the wear defect detection model to defects at various angles and orientations.

[0029] By equipping the wear detection trolley with a high-precision encoder or GPS, the position coordinates of the trolley on the overhead contact line busbar can be obtained in real time. At the same time, by using the pre-calibrated internal and external parameters of the camera, a mapping relationship between the image coordinate system and the world coordinate system is established, and the detected defects are transformed from pixel coordinates to spatial coordinates in the busbar coordinate system. Combined with the positioning information of the wear detection trolley, the defects can be accurately located.

[0030] During the image acquisition process of the overhead contact line's conductive rails, ambient light intensity is collected in real time using an illuminance sensor and compared with a preset threshold to dynamically control the supplementary lighting strategy. Compared to a fixed lighting method, the adaptive light source compensation method can adjust the light intensity in real time according to changes in external lighting conditions.

[0031] This method combines global thresholding with local adaptive thresholding to adaptively threshold the high-frequency detail subband coefficients after wavelet decomposition, removing noise while preserving texture, edge, and other detailed features to the greatest extent possible. Compared to traditional methods such as median filtering and mean filtering, this denoising method has stronger detail preservation capabilities and adaptability.

[0032] In the process of locating wear defects, by establishing the relationship between the busbar coordinate system and the wear detection trolley coordinate system, the detected defect position is transformed from the pixel coordinates in the image coordinate system to the spatial coordinates in the busbar coordinate system. Combined with the positioning information of the wear detection trolley itself, the defect is accurately located on the contact wire conductive rail. Attached Figure Description

[0033] This application will be further described by way of exemplary embodiments, which will be described in detail with reference to the accompanying drawings. These embodiments are not limiting; in these embodiments, the same reference numerals denote the same structures, wherein:

[0034] Figure 1 This is an exemplary flowchart illustrating a method for measuring wear of conductive rails in a subway contact network according to some embodiments of this application;

[0035] Figure 2This is a schematic diagram of a wear detection carriage according to some embodiments of this application;

[0036] Figure 3 These are schematic diagrams illustrating image rotation processing according to some embodiments of this application;

[0037] Figure 4 This is a schematic diagram of a YOLOv8 model according to some embodiments of this application. Detailed Implementation

[0038] The methods and systems provided in the embodiments of this application will now be described in detail with reference to the accompanying drawings.

[0039] Figure 1 This is an exemplary flowchart illustrating a method for measuring wear of subway contact wire conductive rails according to some embodiments of this application. A wear detection trolley equipped with a camera and light source is placed on the subway contact wire conductive rail busbar. The trolley is controlled to move along the busbar, and image data of the contact wire conductive rails is acquired through the camera. The acquired image data is preprocessed, including grayscale conversion and noise reduction. A training set is constructed using the contact wire conductive rail image data labeled with wear defect types and locations to train a wear defect detection model based on the YOLOv8 model. The preprocessed image data is input into the trained wear defect detection model to identify wear defects in the images and predict the type and location information of the wear defects. The predicted wear defect type and location information are sent to the control system of the wear detection trolley. The control system obtains the location coordinates of the defects using the positioning system of the wear detection trolley based on the defect location information. The control system of the wear detection trolley controls the wear detection trolley to move to the defect location based on the defect location coordinates, and measures the wear degree of the contact wire conductive rail using the wear measurement device equipped on the wear detection trolley to obtain wear measurement data.

[0040] Figure 2 This is a schematic diagram of a wear detection trolley according to some embodiments of this application. Data is collected by the detection trolley, and a CCD camera and supplementary lighting source are installed on the wear detection trolley of the overhead contact line maintenance vehicle. A high-resolution, low-illuminance industrial camera is selected for the CCD camera, and the lens focal length is determined based on the width of the conductive rail and the installation height. The supplementary lighting source uses an LED array, whose spectral distribution matches the spectral response of the camera. The camera and light source are fixed to the bottom of the trolley by a bracket, and the lens optical axis is perpendicular to the surface of the conductive rail. The trolley runs on the busbar via insulated tires, and its travel speed is determined based on the camera frame rate and the required detection resolution of the conductive rail.

[0041] A rotary encoder is installed on the axle of the wear detection trolley to obtain the trolley's travel distance and speed by measuring the axle rotation angle. The encoder is selected with sufficient accuracy and resolution, while considering errors introduced by factors such as tire slippage. The encoder's output pulse signal is synchronized with the camera's trigger signal to record the image acquisition position. Based on the reflectivity of the contact wire's conductive rail material, a spectrophotometer is used to measure its reflectivity at different incident angles and wavelengths, obtaining reflectivity curves. Simultaneously, the imaging effect of the camera under different exposure parameters under standard light sources is statistically analyzed to obtain a suitable exposure range. Combining these two factors, an illumination threshold is experimentally determined, representing the minimum ambient light intensity required to obtain a clear image of the conductive rail. The ambient light intensity collected by the illuminance sensor is compared with the preset illumination threshold in real time. When the ambient light intensity is below the threshold, the light source is triggered to turn on, and the brightness and duration of the light source are dynamically adjusted based on the light intensity difference, achieving adaptive supplementary lighting through closed-loop control. Furthermore, the response time and thermal effects of the light source are considered to avoid sudden brightness changes and overexposure. Based on the running speed of the wear detection trolley, the surface condition of the conductive rail, and the imaging quality requirements, the camera's frame rate, exposure time, and gain were set. The frame rate needed to meet the requirements of continuous acquisition and real-time processing, the exposure time needed to avoid motion blur, and the gain needed to balance signal-to-noise ratio and dynamic range. Through field experiments and image quality evaluation, the parameter configuration was optimized to obtain stable and clear conductive rail image data.

[0042] Grayscale conversion: The acquired color image of the conductive rail is converted to grayscale, transforming the RGB three-channel information into single-channel grayscale information. A weighted average method is used to calculate the grayscale value, i.e.: Where Gray represents the pixel values ​​of the grayscale image, and R, G, and B represent the pixel values ​​of the red, green, and blue channels of the original color image, respectively. , , represents the weighting coefficients for the three channels. .

[0043] The Daubechies 4 (db4) wavelet was used as the basis function. The db4 wavelet is a commonly used orthogonal compactly supported wavelet with good time-frequency localization performance and moderate smoothness, enabling effective multi-scale decomposition of images. The db4 wavelet was used to perform a four-level wavelet decomposition on the grayscale image of the overhead contact line rail. Each level of decomposition divides the image into a low-frequency approximation subband and a high-frequency detail subband. First level decomposition: The original grayscale image I is decomposed into a low-frequency subband LL1 and high-frequency subbands HL1, LH1, and HH1. LL1 represents the low-frequency approximation information of the image, while HL1, LH1, and HH1 represent the high-frequency detail information in the horizontal, vertical, and diagonal directions, respectively. Second level decomposition: The low-frequency subband LL1 obtained from the first level decomposition is further decomposed to obtain the low-frequency subband LL2 and the high-frequency subbands HL2, LH2, and HH2. Third level decomposition: The low-frequency subband LL2 obtained from the second level decomposition is further decomposed to obtain the low-frequency subband LL3 and the high-frequency subbands HL3, LH3, and HH3. Fourth-level decomposition: The low-frequency subband LL3 obtained from the third-level decomposition is further decomposed to obtain the low-frequency subband LL4 and the high-frequency subbands HL4, LH4, and HH4. After four levels of wavelet decomposition, one low-frequency subband coefficient LL4 and twelve high-frequency subband coefficients are obtained: Low-frequency subband coefficient: LL4. High-frequency subband coefficients: HL1, HL2, HL3, HL4, LH1, LH2, LH3, LH4, HH1, HH2, HH3, HH4; where LL4 represents the low-frequency approximation information of the image at the coarsest scale, preserving the main structure and energy of the image. HL1HL4, LH1LH4, and HH1~HH4 represent the high-frequency detail information in the horizontal, vertical, and diagonal directions at different scales, respectively, including details such as image texture, edges, and noise.

[0044] Global statistical feature calculation: Based on the grayscale image of the conductive rail, calculate its global grayscale mean. and global grayscale standard deviation The formula is as follows: ; ;in, Let M be the grayscale value of the pixel in the i-th row and j-th column of the grayscale image, where M and N are the number of rows and columns of the image, respectively. Local texture feature calculation: Divide the grayscale image into S×S non-overlapping local patches, where S ranges from 8 to 32. For each local patch, calculate the following features: local grayscale mean. : Local grayscale standard deviation : ;in, This represents the grayscale value of the pixel in the m-th row and n-th column of a local patch. Local texture richness. : Where ε is a non-negative small constant used to avoid the denominator being zero. This reflects the richness of the surface texture of the conductive rails within a local small area. Global texture feature calculation: average local texture richness. : ;in, This reflects the overall richness of the conductive track texture. Global texture richness. : .

[0045] Adaptive threshold calculation: For each high-frequency sub-band obtained by wavelet decomposition, the basic denoising threshold of the corresponding layer is calculated based on the standard deviation σ of its coefficients. : Where P and Q are the number of rows and columns of the corresponding sub-band, respectively. Then, adaptive adjustment is performed using the base threshold to obtain the final denoising threshold for each high-frequency sub-band. : Where λ is the threshold adjustment intensity factor, α is the threshold adjustment sensitivity factor, and β is the threshold adjustment nonlinearity factor, with values ​​ranging from [0.1, 0.5], [10, 50], and [0.5, 2], respectively. When the texture richness of the conductive rail is high, the threshold is appropriately increased to avoid excessive noise reduction; when the texture richness is low, the threshold is appropriately decreased to retain more detailed information.

[0046] Wavelet coefficient thresholding denoising: For each high-frequency subband (HL, LH, HH), a soft thresholding function is used to denoise the wavelet coefficients. Let the wavelet coefficient of the k-th high-frequency subband in the j-th layer be... Where i is the index of the coefficient, j = 1, 2, 3, 4 represents the wavelet decomposition level, and k = 1, 2, 3 represents the HL, LH, and HH subbands, respectively. The final threshold of the k-th subband at the j-th level is calculated previously. For each wavelet coefficient Perform soft thresholding: if Then set the coefficient to zero: ;if If so, then retain the coefficient and perform shrinkage: if ,but ;if ,but Repeat this process for all high-frequency subbands in each layer to obtain the denoised high-frequency subband coefficients. The low-frequency subband LL4 remains unchanged and is not thresholded.

[0047] Inverse wavelet transform and image reconstruction: Using the denoised wavelet coefficients, the denoised grayscale image is reconstructed through inverse wavelet transform. An inverse wavelet transform is performed on the fourth-layer low-frequency subband LL4 and the denoised high-frequency subbands HL4, LH4, and HH4 to obtain the third-layer low-frequency subband LL3'. An inverse wavelet transform is performed on LL3' and the denoised high-frequency subbands HL3, LH3, and HH3 to obtain the second-layer low-frequency subband LL2'. An inverse wavelet transform is performed on LL2' and the denoised high-frequency subbands HL2, LH2, and HH2 to obtain the first-layer low-frequency subband LL1'. An inverse wavelet transform is performed on LL1' and the denoised high-frequency subbands HL1, LH1, and HH1 to obtain the reconstructed denoised grayscale image I'.

[0048] Construct a training set and obtain preprocessed contact wire rail image samples: Acquire raw images of the contact wire rail using contact wire rail image acquisition equipment (such as a high-definition camera on a wear detection vehicle). Preprocess the raw images, including grayscale conversion, noise reduction, and enhancement, to obtain preprocessed contact wire rail image samples. Store the preprocessed image samples according to a certain naming rule, such as "sample_001.jpg", "sample_002.jpg", etc. Determine the preset wear defect types: Based on the wear defect characteristics of the contact wire rail, preset different types of wear defects, such as "wear", "peeling", and "deformation". Assign a unique identifier to each defect type, such as "wear: 1", "peeling: 2", "deformation: 3", etc. Annotate the image samples for defects: Open the preprocessed contact wire rail image samples using annotation tools (such as LabelImg, CVAT, etc.). Annotate the wear defect areas in the images, selecting the corresponding identifier according to the defect type. Mark the location of the defect area with a rectangular bounding box and record the coordinates of the bounding box. ,in The coordinates of the top-left corner of the bounding box. The coordinates are the lower right corner of the bounding box. All defect regions in each image sample are labeled to ensure completeness and accuracy. Annotation files are generated: After annotation, a corresponding annotation file is generated for each image sample, such as "sample_001.xml", "sample_002.xml", etc. The annotation file contains basic image information (such as filename, size, etc.) and annotation information for defect regions (such as defect type, bounding box coordinates, etc.). The annotation files use common annotation formats, such as PASCAL VOC, COCO, etc. Annotated image sample set is constructed. The preprocessed image samples and their corresponding annotation files are organized according to a specific directory structure to form an annotated image sample set. .

[0049] Read the labeled image sample set Each image sample Img and its corresponding defect bounding box label are included. For each image sample Img, the following geometric rotation data augmentation steps are performed: calculate the geometric center coordinates of the image sample Img to be augmented. : , Where width and height are the width and height of the image sample Img, respectively. Randomly generate the rotation angle θ: θ = random(-30°, 30°); where random(-30°, 30°) represents randomly selecting an angle value within the range of -30° to 30°. c. Construct the affine transformation matrix M: Applying an affine transformation to the image sample Img yields the rotated image. : ;in, This means that applying the affine transformation matrix M to the image Img yields the transformed image. For each bounding box coordinate in the defect bounding box label. Apply the same affine transformation: ; ; Obtain the coordinates of the defect boundary box after rotation transformation .

[0050] Calculate the image after rotation transformation The top left corner coordinates of the bounding box and the coordinates of the bottom right corner And calculate the width of the bounding box based on its coordinates. and height Set a blank image (Blank) with the same size as the original image sample Img to be enhanced, and dimensions (W, H). Calculate the image after rotation transformation. Starting coordinates in the blank image Blank , making Center in Blank. The starting coordinates satisfy the following formula: ; Where W and H are the width and height of the image sample Img to be enhanced, respectively.

[0051] Image after rotation transformation Copy to the corresponding position in the blank image, with the starting coordinates of the copy being... The size of the copied region is To obtain geometrically rotated enhanced image samples Obtain the defect bounding box label (Label) from the image sample Img to be enhanced, containing the coordinates of the defect bounding box. Based on the rotation transformation parameters, an affine transformation is used to rotate the coordinates of the defect boundary box, resulting in the rotated coordinates of the defect boundary box. Based on the rotated defect boundary box coordinates and the initial coordinates... Calculate the image samples after rotation enhancement Coordinates of the defect bounding box The calculation formula is as follows: ; ; ; Output image samples enhanced by geometric rotation. and corresponding defect bounding box labels ,in, Includes the coordinates of the defect bounding box after rotation enhancement .

[0052] For the rotation-enhanced image sample set Each image sample in and corresponding tag data Verification: Calculate image samples width and height Traverse the label data Coordinates of each defect bounding box : Determine whether the defect bounding box is completely within the image range: When or or or Mark the defect bounding box as out of bounds; determine whether the width and height of the defect bounding box exceed a preset minimum threshold. and :if or The defect bounding box is marked as incomplete. If the image sample... If any out-of-bounds or incomplete bounding boxes are found in the image, the image sample and its corresponding label data are considered invalid samples. Remove from the list. All image samples and label data are validated to obtain a valid set of rotated and enhanced image samples. .

[0053] Image sample set and Merge: Create a new image sample set (Dataset) to store the merged image samples and label data. Copy all image samples and their corresponding label data to the Dataset. All image samples and their corresponding label data are copied into a Dataset. The image samples and label data in the Dataset are randomly shuffled to improve the randomness and robustness of the training. The merged image sample set Dataset is used as the labeled dataset for training the YOLOv8 wear defect detection model: the Dataset is divided into training, validation, and test sets according to a certain ratio, such as 70% for training, 20% for validation, and 10% for testing.

[0054] Figure 4 This is a schematic diagram of a YOLOv8 model according to some embodiments of this application. The YOLOv8 model architecture is as follows: Backbone Network: A ResNet structure is used as the backbone network of the YOLOv8 model. ResNet, by introducing residual connections, can effectively solve the gradient vanishing problem during deep network training, improving the model's feature extraction capability. The backbone network receives input image data and extracts multi-scale features of the image through a series of convolutional and pooling layers. Neck Network: The neck network consists of an SPP (Spatial Pyramid Pooling) structure and a PANet (Path Aggregation Network) structure. The SPP structure enhances the model's robustness to changes in target scale through max pooling operations at different scales. The PANet structure, through bottom-up and top-down feature fusion, effectively combines low-level fine-grained features with high-level semantic features, improving the model's detection accuracy. Detection Head: A YOLOv3 head structure is used as the detection head of the YOLOv8 model. The detection head receives the fused features output from the neck network and generates detection results at different scales through a series of convolutional layers and upsampling operations. The detection results at each scale include the predicted target bounding box coordinates and class probability.

[0055] Model Training: Data Preparation: The constructed image sample set (Dataset) is used as the training data for the YOLOv8 model. The Dataset is divided into training, validation, and test sets, and organized and stored according to the format required by YOLOv8. Transfer Learning: Transfer learning is performed on the pre-trained YOLOv8 model to accelerate model convergence and improve training performance. Pre-trained models are typically trained on large-scale general datasets and have learned rich image feature representations. Through transfer learning, the weights of the pre-trained model can be used as initialization parameters and fine-tuned for the contact wire rail wear defect detection task. Model Optimization: Based on transfer learning, the YOLOv8 model is trained using the training set, and the model's performance is evaluated and tuned using the validation set. By adjusting hyperparameters (such as learning rate, batch size, number of iterations, etc.) and optimization strategies (such as learning rate scheduling, regularization methods, etc.), the detection accuracy and generalization ability of the model are continuously optimized. Model Evaluation: The trained YOLOv8 model is evaluated using a test set, and its performance metrics, such as precision, recall, and mean AP, are calculated for the contact wire rail wear defect detection task. Based on the evaluation results, the model structure and training strategy can be further adjusted to obtain optimal detection performance.

[0056] Model Application: Model Deployment: The trained YOLOv8 model is deployed to an embedded device on the wear detection vehicle, such as a Jetson series development board. The embedded device receives image data collected by the wear detection vehicle and uses the deployed YOLOv8 model to perform real-time image detection. Defect Localization and Classification: The YOLOv8 model performs forward inference on the input image to generate detection results. The detection results include the bounding box coordinates and corresponding class probability of each detected wear defect target. Based on a preset threshold, detection results with low confidence can be filtered out, while wear defect targets with high confidence are retained. Defect Visualization: The detection results are visualized by drawing the bounding boxes of wear defect targets on the original image and labeling the corresponding defect categories and confidence levels. The visualization results help maintenance personnel intuitively understand the wear condition of the overhead contact line rails and perform timely repairs and replacements.

[0057] Calculate the position coordinates of the wear defect in the busbar coordinate system of the overhead contact line, and obtain the pixel coordinates of the defect in the image of the overhead contact line: coordinates of the defect bounding box predicted by the wear defect detection model. Calculate the normalized center coordinates of the defect bounding box. : Where W and H are the width and height of the contact wire conductive rail image, respectively. The normalized center coordinates are then... Convert the defect to pixel coordinates in the image : .

[0058] The position coordinates of the wear detection carriage are obtained using an encoder: An encoder is installed on the drive wheel of the wear detection carriage to measure the rotation information of the drive wheel. The encoder can be an incremental encoder or an absolute encoder. By measuring the rotation angle and direction of the drive wheel using the encoder, and combining this with the diameter of the drive wheel, the displacement Δx of the wear detection carriage along the busbar direction is calculated. At the initial position of the wear detection carriage, the position coordinates along the busbar direction are recorded. Initialize to zero or a known starting coordinate value. Update the current position coordinates of the wear detection cart according to its movement direction and displacement Δx using the following formula. If the wear detection carriage moves in the positive direction of the busbar, then If the wear detection trolley moves in the negative direction of the busbar, then For position coordinates perpendicular to the busbar direction and height coordinates relative to the busbar These can be assumed to remain unchanged or to be measured and updated by other sensors, such as laser rangefinders.

[0059] The location coordinates of the wear detection vehicle are obtained using the Global Positioning System (GPS): A GPS receiver is installed on the wear detection vehicle to receive GPS satellite signals and calculate its global location coordinates. The GPS receiver calculates the longitude, latitude, and altitude coordinates of the wear detection vehicle by receiving signals from multiple satellites. The location coordinates (longitude, latitude, altitude) in the GPS coordinate system are then converted to the location coordinates in the catenary conductor rail busbar coordinate system. This requires establishing the conversion relationship between the GPS coordinate system and the busbar coordinate system beforehand.

[0060] The transformation relationship can be established through the following steps: Select several reference points on the busbar and measure the position coordinates of these reference points in the GPS coordinate system using a high-precision GPS device. Simultaneously, measure the position coordinates of these reference points in the busbar coordinate system, establishing the correspondence between the reference points in the two coordinate systems. Calculate the transformation matrix or transformation function between the GPS coordinate system and the busbar coordinate system using a coordinate transformation algorithm (such as coordinate system rotation and translation). Using the established transformation relationship, convert the GPS coordinates of the wear detection vehicle to position coordinates in the busbar coordinate system. Fusion of encoder and GPS position information: To obtain more accurate and robust position coordinates, the position information from the encoder and GPS can be fused. Using algorithms such as Kalman filters or particle filters, the relative displacement measured by the encoder and the absolute position coordinates measured by the GPS are fused to estimate the current position coordinates of the wear detection vehicle in the busbar coordinate system. Fusion algorithms can comprehensively consider the uncertainties and noise of encoder and GPS measurements, thereby improving the accuracy and stability of position estimation.

[0061] Obtain the intrinsic parameter matrix K of the camera: The intrinsic parameter matrix K describes the internal geometry and optical properties of the camera, including the focal length and principal point coordinates. The general form of the intrinsic parameter matrix K is: ,in, and These are the focal lengths of the camera along the x and y axes, respectively. and These are the coordinates of the camera's principal point.

[0062] Using Zhang Zhengyou's calibration method or other calibration methods, the intrinsic parameter matrix K of the camera is calculated by capturing multiple images containing known regular patterns (such as a checkerboard). The calibration steps are as follows: Prepare a calibration board containing a known regular pattern (such as a checkerboard), where the positions of feature points are known. Use the camera to capture multiple images containing the calibration board from different angles and positions. For each image, extract the pixel coordinates of the feature points (such as checkerboard corners) on the calibration board. Based on the world coordinates and pixel coordinates of the feature points, construct a set of equations and solve for the elements of the intrinsic parameter matrix K. Use an optimization algorithm (such as the least squares method) to jointly solve the equations for all images to obtain the optimal intrinsic parameter matrix K. d. Save the calculated intrinsic parameter matrix K for subsequent defect localization calculations.

[0063] Obtain the extrinsic parameter matrix of the camera : Extrinsic parameter matrix This describes the position and orientation relationship of the camera relative to the wear detection vehicle's coordinate system. Here, R is the rotation matrix and t is the translation vector. Using hand-eye calibration or other calibration methods, the extrinsic parameter matrix of the camera relative to the wear detection vehicle is calculated by capturing multiple images containing a known reference object. The calibration steps are as follows: Fix a reference object (such as a calibration plate or marker point) of known size and position on the wear detection cart. Control the wear detection cart to move to different positions and use a camera to capture images containing the reference object. For each image, extract the pixel coordinates of feature points (such as corner points or marker points) on the reference object. Based on the position information of the wear detection cart and the world coordinates of the reference object, construct a set of equations and solve for the extrinsic parameter matrix. The elements are then used. An optimization algorithm (such as least squares) is used to jointly solve the equations for all images to obtain the optimal extrinsic parameter matrix. The calculated extrinsic parameter matrix Save it for subsequent defect location calculations.

[0064] Storage and access of calibration data: The intrinsic parameter matrix K and extrinsic parameter matrix [R|t] obtained from calibration are stored in the non-volatile memory of the wear detection vehicle, such as flash memory or an SD card. In the defect localization algorithm, the intrinsic parameter matrix K and extrinsic parameter matrix [R|t] are read from the memory to calculate the three-dimensional coordinates of the defect in the wear detection vehicle coordinate system. If the intrinsic and extrinsic parameters of the camera change (e.g., the camera is replaced or its installation position is adjusted), recalibration and updating of the stored parameter matrices are required.

[0065] Calculate the three-dimensional coordinates of the defect in the wear inspection trolley coordinate system: a. Based on the camera's intrinsic parameter matrix K, extrinsic parameter matrix [R|t], and the pixel coordinates of the defect in the camera's captured image. Establish the following system of equations: Where s is the scale factor.

[0066] More specifically, known: pixel coordinates (pass (Calculated), rotation matrix R and translation vector t. Solution: Expand the equation: ;in, and These are the transformed pixel coordinates; This represents the element in the i-th row and j-th column of the rotation matrix R. Let represent the i-th element of the translation vector t. The scale factor s is obtained from the third equation: Substitute s into the first two equations to eliminate s: ; ;make: ; ; ; ; ; ; ; The resulting system of equations can then be written as: ; Now that we have a system of two linear equations in two variables X, Y, and Z, we can solve it using Cramer's rule: ; ; or Substitute the obtained values ​​of X, Y, and Z into the expression for the scale factor s, and calculate s: .

[0067] Convert the defect coordinates to position coordinates in the busbar coordinate system: Obtain the current position coordinates of the wear inspection vehicle in the busbar coordinate system. The three-dimensional coordinates (X, Y, Z) of the defect in the wear inspection carriage coordinate system and the current position coordinates of the wear inspection carriage in the busbar coordinate system are used to determine the location of the defect. Adding them together gives the position coordinates of the defect in the busbar coordinate system. : The position coordinates of the defect in the busbar coordinate system are obtained after transformation. Save it.

[0068] Output the defect location coordinates and send them to the control system: This will provide the defect's location coordinates in the busbar coordinate system. The output is sent to the control system of the wear detection cart. After receiving the defect location coordinates, the control system can perform subsequent operations based on the coordinate information, such as displaying the defect location coordinates on the user interface for operator viewing and confirmation, recording the defect location coordinates in a database or log file for later analysis and statistics, and sending the defect location coordinates to the navigation and control module of the wear detection cart so that the cart can move to the defect location for further inspection or repair. Based on the received defect location coordinates, the control system executes corresponding operations and decisions, completing the defect location and handling process.

[0069] The wear inspection carriage moves to the defect location: The wear inspection carriage's control system receives the defect location coordinates. The control system calculates the distance the wear detection trolley needs to move along the busbar direction. ,in Here is the x-coordinate of the current position of the wear detection carriage. The control system issues a control command to drive the motion mechanism (such as a motor, wheels, etc.) of the wear detection carriage to move the calculated distance along the busbar direction. The wear detection carriage moves to directly below the defect location, aligning the wear measuring device with the defect location. The control system issues a control command to drive the lifting device (such as a hydraulic cylinder, lead screw, etc.) on the wear detection carriage to lower the wear measuring device. The height the wear measuring device lowers is... ,in The z-coordinate of the current position of the wear detection vehicle. Here is the z-coordinate of the defect location. After the wear measuring device descends to its position, it contacts the surface of the conductive rail at the defect location.

[0070] Laser rangefinder sensor measures normal distance: The laser rangefinder in the wear measurement device emits a laser beam, which is perpendicularly incident on the surface of the conductive rail. The conductive rail surface reflects the laser beam back, and the laser rangefinder sensor receives the reflected laser beam. The processing unit inside the laser rangefinder sensor calculates the distance between the emission point and the reflection point of the laser beam based on the time difference between the emitted and received laser beams. This calculated distance is taken as the normal distance d from the conductive rail surface at the defect location to the laser rangefinder sensor. The laser rangefinder sensor transmits the measured normal distance d to the data acquisition module of the wear measurement device.

[0071] The wear measurement device moves in steps and collects data: A linear guide rail is installed perpendicular to the busbar direction, and a slider is mounted on the guide rail, fixedly connected to the main body of the wear measurement device. A stepper motor is mounted on the linear guide rail, driving the slider to move along the guide rail via a lead screw or synchronous belt drive mechanism. The control unit of the wear measurement device controls the stepper motor to rotate according to a preset step length Δd, causing the wear measurement device to move one step length perpendicular to the busbar direction. For each step length, the control unit triggers a laser rangefinder to perform a normal distance measurement and records the measured normal distance d. The wear measurement device repeats this process until the preset number of steps is completed, obtaining a set of normal distance data. The collected normal distance data is transmitted to the wear detection trolley control system for further processing. Extracting normal dimension data from the drawing: Based on the current position of the wear measuring device, determine the corresponding busbar cross-section position. Search the busbar cross-section design drawing database for the design drawing corresponding to that cross-section position. Perform image processing and feature extraction on the design drawing to identify the geometric features of the cross-section profile. Extract the corresponding normal dimension D from the cross-section profile according to the measurement direction of the wear measuring device. Record the extracted normal dimension D and correlate it with the normal distance d at the corresponding step position. Repeat until the normal dimension data corresponding to all step positions is obtained from the drawing. .

[0072] Calculate the deviation value and assess the degree of wear: For each step position i, calculate the actual measured normal distance. Normal dimensions of the drawing Deviation between ,Right now The calculated deviation value Save to an array or list to form a bias dataset. Perform statistical analysis on the deviation dataset and calculate the maximum deviation value. Minimum value ,average value and standard deviation After receiving wear measurement data, the wear detection trolley control system records and stores the data, either saving it to local storage or uploading it to a remote server. Based on the wear measurement data, the control system assesses the wear condition of the conductive rail at the defect location and determines whether repair or replacement is necessary. The wear assessment results are displayed on the user interface or sent to the relevant maintenance management system for scheduling subsequent maintenance operations.

Claims

1. A method for measuring the wear of conductive rails in subway overhead contact lines, comprising: A wear detection trolley equipped with a camera and light source is placed on the busbar of the conductive rail of the subway catenary. The wear detection trolley is controlled to move along the busbar and the camera collects image data of the conductive rail of the catenary. The acquired image data is preprocessed, including grayscale conversion and noise reduction. A training set was constructed using contact wire conductive rail image data labeled with wear defect types and locations, and a wear defect detection model based on the YOLOv8 model was trained. The preprocessed image data is input into the trained wear defect detection model to identify wear defects in the image and predict the type and location information of the wear defects. The predicted wear defect type and location information are sent to the control system of the wear detection trolley. The control system uses the positioning system of the wear detection trolley to obtain the location coordinates of the defect based on the defect location information. The control system of the wear detection trolley moves the trolley to the location of the defect based on the location coordinates of the defect, and measures the wear degree of the contact wire conductive rail through the wear measurement device equipped on the trolley to obtain wear measurement data.

2. The method for measuring wear of subway contact wire conductive rails according to claim 1, characterized in that: A wear detection trolley equipped with a camera and light source is placed on the busbar of the subway overhead contact line. The camera collects image data of the overhead contact line busbar, including: The wear detection trolley is equipped with an illuminance sensor, which is used to collect the ambient light intensity within a preset collection range as the wear detection trolley moves on the busbar. The collected ambient light intensity is compared with a preset light threshold; the light threshold is determined based on the reflective characteristics of the contact wire conductive rail material and the camera's exposure parameters. When the ambient light intensity is lower than the light threshold, the light source is controlled to enhance the light intensity. The camera continuously acquires image data of the overhead contact line rails at a preset frame rate and exposure parameters.

3. The method for measuring wear of subway contact wire conductive rails according to claim 2, characterized in that: The acquired image data is converted to grayscale, including: A weighted average method is used to sum the pixel values ​​of the RGB channels of the acquired image data to obtain a grayscale image. The weighted summation formula is as follows: ; Where Gray represents the pixel value of the grayscale image, and R, G, and B are the pixel values ​​of the red, green, and blue channels of the acquired image data, respectively. , , These are the weighting coefficients for the three channels.

4. The method for measuring wear of subway contact wire conductive rails according to claim 3, characterized in that: The acquired image data undergoes denoising processing, including: The grayscale image of the overhead contact line rail was decomposed into four layers using the db4 wavelet basis function to obtain the low-frequency subband coefficients and high-frequency subband coefficients of each layer. Calculate the global grayscale mean of the image after grayscale conversion based on the high-frequency subband coefficients of each layer. and global grayscale standard deviation : ; ; in, Let be the grayscale value of the pixel in the i-th row and j-th column of the grayscale image of the conductive rail, where M and N are the number of rows and columns of the image, respectively. The grayscale image is divided into S×S non-overlapping local blocks, where the value of S ranges from 8 to 32. For each local block, calculate the local grayscale mean. and local grayscale standard deviation : ; ; in, This represents the grayscale value of the pixel in the m-th row and n-th column of a local small block; Calculate the local texture richness of each local patch. : ; Where ε is a non-negative small constant; Used to characterize the richness of the surface texture of conductive rails within local small blocks; Calculate the average local texture richness of the grayscale conductive track image. : ; in, This reflects the overall richness of the conductive track texture; Calculate global texture richness : ; Calculate the base denoising threshold for the corresponding layer based on the standard deviation of the high-frequency subband coefficients of each layer. : ; Where σ is the standard deviation of the wavelet coefficients within the corresponding high-frequency detail subband, and P and Q are the number of rows and columns of the corresponding subband, respectively; Using the basic denoising threshold Adaptive adjustment is performed to obtain the final denoising threshold for each high-frequency detail subband. The calculation formula is: ; Wherein, λ is the threshold adjustment intensity factor, α is the threshold adjustment sensitivity factor, and β is the threshold adjustment nonlinearity factor. The values ​​of λ, α, and β range from [0.1, 0.5], [10, 50], and [0.5, 2], respectively. The absolute value within each high-frequency subband is less than the corresponding final threshold. The wavelet coefficients are set to zero to obtain the denoised high-frequency subband coefficients; The wavelet coefficients of each layer after denoising are subjected to inverse wavelet transform to reconstruct the grayscale image of the contact wire rail after denoising.

5. The method for measuring wear of subway contact wire conductive rails according to claim 4, characterized in that: A training set was constructed using contact wire conductive rail image data labeled with wear defect types and locations. A wear defect detection model based on the YOLOv8 model was trained, including: Obtain preprocessed image samples of the overhead contact line rails and construct an annotated image sample set; The YOLOv8 model was chosen as the basic architecture for the wear defect detection model. The YOLOv8 model consists of a backbone network, a neck network, and a detection head. The backbone network adopts a ResNet structure to extract multi-scale features from the image. The neck network adopts an SPP and PANet structure to fuse the multi-scale feature information extracted by the backbone network. The detection head adopts a YOLOv3 head structure to predict the bounding box and class probability of the wear defect target based on the fused multi-scale feature information. Using the constructed image sample set, an optimized model for detecting wear defects in overhead contact wire rails is obtained by training the YOLOv8 pre-trained model through transfer learning.

6. The method for measuring wear of subway contact wire conductive rails according to claim 5, characterized in that: Construct a labeled image sample set, including: Obtain preprocessed image samples of the overhead contact line rails, and annotate the wear defect areas in the image samples according to preset defect types. The annotations include the bounding box coordinates of the defect type and defect location. Obtain the labeled image sample set ; For the labeled image sample set Geometric rotation data augmentation is performed on each image sample Img and its corresponding defect bounding box label to obtain the rotated augmented image sample. and tags ; Image samples after geometric rotation data augmentation and tag data Verification is performed to remove invalid samples where the conductive rail target is incomplete or the defective bounding box exceeds the limit due to rotation, resulting in a rotation-enhanced image sample set. ; Image sample set and The images were merged into a labeled dataset for training the YOLOv8 wear defect detection model.

7. The method for measuring wear of subway contact wire conductive rails according to claim 6, characterized in that: Geometric rotation data augmentation, including: Based on the geometric center of the image sample Img to be enhanced, rotation transformation parameters are randomly generated. These parameters include the coordinates of the rotation center. and rotation angle θ; where the coordinates of the rotation center are... The geometric center of the image sample Img to be enhanced is set, and the rotation angle θ is randomly selected within a preset range of -30° to 30°, corresponding to the pitch and yaw angle fluctuations of the camera during the operation of the wear detection vehicle. Based on the rotation transformation parameters, the image sample Img is geometrically rotated using an affine transformation to obtain the rotated image. ; Calculate the image after rotation transformation The top left corner coordinates of the bounding box and the coordinates of the bottom right corner And calculate the width of the bounding box based on its coordinates. and height ; Set a blank image Blank with the same size as the original image sample Img to be enhanced, and dimensions (W, H); Calculate the image after rotation transformation Starting coordinates in the blank image Blank , making To center an element in Blank, the starting coordinates must satisfy the following formula: ; ; Where W and H are the width and height of the image sample Img to be enhanced, respectively; Image after rotation transformation Copy to the corresponding position in the blank image, with the starting coordinates of the copy being... The size of the copied region is To obtain geometrically rotated enhanced image samples ; Obtain the defect bounding box label (Label) from the image sample Img to be enhanced, containing the coordinates of the defect bounding box. Based on the rotation transformation parameters, an affine transformation is used to rotate the coordinates of the defect boundary box, resulting in the rotated coordinates of the defect boundary box. ; Based on the rotated defect boundary box coordinates and the initial coordinates Calculate the image samples after rotation enhancement Coordinates of the defect bounding box The calculation formula is as follows: ; ; ; ; Output geometrically rotated image samples and corresponding defect bounding box labels ,in, Includes the coordinates of the defect bounding box after rotation enhancement .

8. The method for measuring wear of subway contact wire conductive rails according to claim 7, characterized in that: Affine transformations satisfy the rotational transformation formula: ; Where (x, y) are the coordinates of a pixel in the image to be rotated. These are the coordinates of the corresponding pixel in the image after rotation transformation.

9. The method for measuring wear of subway contact wire conductive rails according to any one of claims 2 to 8, characterized in that: Obtain the location coordinates of the defect, including: Coordinates of the defect bounding box predicted by the wear defect detection model Calculate the pixel coordinates of defects in the overhead contact line rail image. : ; ; in, The normalized center coordinates of the defect bounding box predicted by the wear defect detection model are [0, 1]; W and H are the width and height of the contact wire conductive rail image, respectively. The current position coordinates of the wear detection trolley on the overhead contact line busbar when acquiring defect images ,in These are the position coordinates along the busbar direction. The position coordinates are perpendicular to the busbar direction. The height coordinates of the wear detection vehicle relative to the busbar; the current position coordinates of the wear detection vehicle are obtained through the encoder or GPS system equipped on the wear detection vehicle; Obtain the intrinsic parameter matrix K and extrinsic parameter matrix of the pre-calibrated camera. The intrinsic parameter matrix K contains the focal length of the camera and the coordinates of the principal point, while the extrinsic parameter matrix... It includes the rotation matrix R and translation vector t of the camera relative to the wear detection vehicle.

10. The method for measuring wear of subway contact wire conductive rails according to claim 9, characterized in that: Obtaining the location coordinates of the defect also includes: Based on the camera's intrinsic parameter matrix K and extrinsic parameter matrix And the pixel coordinates of the defects in the camera-captured images. The three-dimensional coordinates of the defect in the wear inspection trolley coordinate system are calculated using the following formula. : ; Where s is the scale factor; The three-dimensional coordinates of the defect in the wear inspection cart coordinate system The following formula can be used to convert the defect's position coordinates in the busbar coordinate system. : ; Output the position coordinates of the defect in the busbar coordinate system. The data is then sent to the control system of the wear detection vehicle as the coordinates of the located defect.

Citation Information

Patent Citations

  • Contact network abrasion detection method based on deep learning

    CN117314849A

  • Pantograph catenary wire abrasion measuring method based on deep learning

    CN118310425A