A Machine Vision-Based Method and System for Identifying Sediment Thickness in Pile Boreholes

By using multi-angle image data processing and triangular structure analysis, the problem of inaccurate positioning of sediment area in traditional pile hole sediment thickness identification has been solved, achieving higher precision sediment thickness detection.

CN121147281BActive Publication Date: 2026-07-17NANTONG UNIV

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
NANTONG UNIV
Filing Date
2025-07-16
Publication Date
2026-07-17

AI Technical Summary

Technical Problem

Traditional methods for identifying the thickness of sediment in pile holes rely on single-angle image acquisition and two-dimensional image processing. They lack multi-angle image fusion and spatial information analysis, resulting in inaccurate positioning of sediment areas and blurred boundaries. This affects the completeness and accuracy of thickness calculation and easily leads to misidentification and misjudgment.

Method used

A machine vision-based approach was used to acquire multi-angle image data of the bottom of the pile hole. Image segmentation was performed by combining grayscale values ​​and texture features to extract the sediment area. Disturbed areas were identified by using brightness difference and saturation difference terms. A grayscale change trend sequence was constructed to reconstruct the boundary. The thickness of the sediment was calculated using the triangle structure analysis method, and the disturbed areas were corrected by combining thickness gradient interpolation.

Benefits of technology

It improves the accuracy of sediment area extraction, reduces misjudgment due to mud disturbance, enhances the continuity and integrity of boundary contours, and achieves higher precision sediment thickness detection.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121147281B_ABST
    Figure CN121147281B_ABST
Patent Text Reader

Abstract

This invention relates to the field of pile hole detection technology, specifically to a machine vision-based method and system for identifying pile hole sediment thickness. The method includes the following steps: acquiring multi-angle images of the hole bottom; segmenting the sediment and hole wall regions; extracting brightness and saturation features to identify disturbances; extracting grayscale gradients to construct trend sequences and calculating direction vectors to reconstruct boundaries; estimating sediment thickness based on parallax; and removing disturbances through interpolation correction to generate thickness distribution information. In this invention, the filtering capability against mud disturbance interference is enhanced by comparing brightness and saturation difference terms with mud disturbance offset thresholds. A grayscale change trend sequence is constructed using local grayscale gradient differences and combined with direction vectors for boundary identification, improving the continuity and integrity of the boundary contour. Sediment thickness is estimated through spatial depth calculation, and the influence of disturbed areas is removed using thickness gradient interpolation, achieving complete restoration of the sediment thickness distribution and improving the accuracy and efficiency of sediment thickness detection.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of pile hole detection technology, and in particular to a method and system for identifying the thickness of sediment in pile holes based on machine vision. Background Technology

[0002] The field of pile hole inspection technology primarily focuses on the quantitative and qualitative evaluation of pile hole formation quality during pile foundation construction. This area encompasses several key technologies, including pile hole geometry measurement, bottom sediment detection, borehole wall stability analysis, and mud performance monitoring, with the aim of ensuring that pile foundation construction meets structural design requirements and engineering safety standards. Common inspection methods include acoustic transmission, ultrasonic imaging, closed-circuit television detection, 3D laser scanning, and image processing-based non-contact inspection methods. With the development of intelligent construction technology, pile hole inspection is gradually incorporating automated and intelligent methods such as computer vision, deep learning, and image enhancement to improve inspection efficiency, reduce human error, and achieve real-time quality control during construction.

[0003] The pile hole sediment thickness identification method specifically focuses on using machine vision technology to identify and quantify the thickness of the sediment layer at the bottom of the pile hole. Its purpose is to acquire images of the bottom of the hole using image acquisition equipment, and then combine image processing and recognition algorithms to extract the sediment boundary and calculate the thickness, thereby determining whether the sediment exceeds the standard. This assists the construction team in timely hole cleaning, ensuring effective contact between the pile foundation and the bearing stratum, and improving the foundation bearing capacity and the safety of the project quality. This method is applicable to sediment thickness detection tasks in various pile foundation projects, including cast-in-place piles and bored piles.

[0004] Traditional identification methods mostly rely on single-angle image acquisition and two-dimensional image processing, lacking multi-angle image fusion and spatial information analysis mechanisms. This leads to inaccurate positioning of sediment areas and broken boundary contours in scenarios with significant disturbance at the bottom of the borehole or blurred boundaries, affecting the completeness and accuracy of thickness calculations. Mud disturbances in the image are easily confused with sediment textures. When relying on single indicators such as brightness or color difference for analysis, misidentification and misjudgment often occur, resulting in incorrect borehole cleaning judgments and affecting the contact quality between the pile foundation and the bearing layer. Traditional methods lack effective boundary compensation mechanisms when image boundaries are broken, making it difficult to reconstruct complete boundary areas, thus limiting the accuracy of subsequent thickness calculations. For example, in areas where the sediment and borehole wall colors are similar, existing algorithms often show outward diffusion or inward shift of the sediment boundary, causing error accumulation and ultimately leading to deviations in sediment thickness estimation, failing to meet engineering construction quality requirements. Summary of the Invention

[0005] The purpose of this invention is to address the shortcomings of existing technologies by proposing a machine vision-based method and system for identifying the thickness of sediment in pile holes.

[0006] To achieve the above objectives, the present invention adopts the following technical solution: a machine vision-based method for identifying the thickness of sediment in pile holes, comprising the following steps:

[0007] S1: Obtain multi-angle image data of the bottom of the pile hole, extract the sediment area and the boundary area of ​​the hole wall in the bottom image, perform image segmentation by combining gray value and texture features, mark the sediment area, and generate candidate images of the sediment area.

[0008] S2: Based on the candidate image of the sediment area, extract the brightness and saturation distribution of the image center area and the hole wall area, calculate the brightness difference term and saturation difference term, compare the values ​​with the preset mud disturbance offset threshold, identify the disturbance area in the image, and generate disturbance area marking information.

[0009] S3: Based on the disturbance area marking information, extract the sediment boundary in the image, obtain the local gray-level gradient difference of the boundary area, construct the gray-level change trend sequence, determine the start and end positions of the boundary based on the set low response threshold and high sensitivity threshold, identify and reconstruct the crack and discontinuity boundary, and generate the optimized sediment boundary contour.

[0010] S4: Based on the optimized sediment boundary contour, using image data from multiple angles, calculate the local parallax using the triangle structure analysis method, and calculate the spatial depth information of the sediment based on the relationship between the parallax value and the image distribution to obtain the estimated sediment thickness.

[0011] As a further aspect of the present invention, the candidate image of the sediment region specifically includes sediment region pixel data, pore wall boundary contour data, image grayscale value distribution information, and texture feature information; the disturbance region marking information specifically includes the pixel position of the disturbance region, brightness difference term, saturation difference term, and disturbance region threshold identifier; the optimized sediment boundary contour specifically includes the boundary start position, boundary end position, grayscale gradient difference value, boundary discontinuity region, and crack reconstruction point; and the sediment thickness estimation value specifically includes the disparity value, boundary depth information, local depth gradient, and initial thickness estimation value.

[0012] As a further aspect of the present invention, the step of obtaining the candidate image of the sediment region specifically includes:

[0013] S101: Obtain multi-angle image data of the bottom of the pile hole, call the gray channel values ​​and pixel texture change values ​​in multiple angle image frames, calculate the initial difference coefficient of the image pixels according to the degree of difference between the gray channel values ​​and texture change values, and collect the initial difference coefficients of multiple regions in the same image frame into a difference coefficient set after dividing them into grids, and generate image feature difference coefficient values.

[0014] S102: Based on the image feature difference coefficient value, call the feature difference coefficient of the bottom region in the image frame and the overall average difference value of the image, use the difference between the difference coefficient and the average difference value to judge grid unit by grid unit, filter grid units whose difference exceeds the bottom sediment judgment threshold as sediment candidate region units, and mark the contour of the region boundary corresponding to the grid unit to generate sediment region boundary judgment information.

[0015] S103: Based on the boundary determination information of the sediment area, call the gradient value of texture change of the hole wall area and the gradient value of gray change of boundary pixels in the pile hole image frame, use the gradient difference of pixels inside and outside the boundary to perform boundary filtering, perform threshold determination on the difference between the determination boundary line and the surrounding hole wall boundary, mark the area with the difference exceeding the hole wall boundary recognition threshold as the sediment area range, and obtain the sediment area candidate image.

[0016] As a further aspect of the present invention, the step of obtaining the disturbance region marking information specifically includes:

[0017] S201: Based on the candidate image of the sediment area, extract the pixel distribution information corresponding to the central area and the hole wall area in the image frame, call the brightness component and saturation component of each pixel in multiple areas respectively, classify the brightness component and saturation component separately according to the area, establish a brightness distribution set and a saturation distribution set, and generate regional brightness and saturation set information.

[0018] S202: Based on the set information of brightness and saturation in the region, calculate the difference between the mean value of brightness distribution and the mean value of saturation distribution between the central region and the hole wall region, define the difference between the mean value of brightness distribution as the brightness difference term, define the difference between the mean value of saturation distribution as the saturation difference term, calculate the joint deviation value of brightness and saturation, and obtain the disturbance difference distribution information;

[0019] S203: For the disturbance difference distribution information, the difference data is called pixel by pixel and compared with the preset mud disturbance offset threshold. Image pixel areas with differences greater than the mud disturbance offset threshold are identified, and disturbance contours are delineated according to the pixel connectivity principle to obtain disturbance area marking information.

[0020] As a further aspect of the present invention, the formula for calculating the joint deviation value of brightness and saturation is as follows:

[0021]

[0022] Among them, D i L represents the combined deviation of brightness and saturation at the i-th position in the central region. ci L represents the average brightness distribution of the i-th pixel in the central region. wi S represents the mean luminance distribution at the i-th position in the aperture wall region.ci S represents the mean saturation distribution of the i-th pixel in the central region. wi λ represents the mean saturation distribution at the i-th position in the hole wall region, and λ represents the weighting factor of the brightness term in the deviation calculation.

[0023] As a further aspect of the present invention, the step of obtaining the optimized sediment boundary profile specifically includes:

[0024] S301: Based on the disturbance area marking information, perform boundary extraction on the image, obtain the local gray-level gradient difference between the sediment area and the hole wall area, calculate the gray-level change of each pixel in the image, and perform local boundary extraction based on the gray-level difference to obtain the local gray-level gradient difference.

[0025] S302: Based on the local gray-level gradient difference, construct a gray-level change trend sequence, calculate the direction vector of each boundary point in the image, determine the boundary direction through the gray-level change trend, and generate a boundary gray-level change trend sequence and direction vector;

[0026] S303: Based on the boundary grayscale change trend sequence and direction vector, combined with the preset low response threshold and high sensitivity threshold, determine the start and end positions of the boundary, filter by comparing the grayscale changes of the boundary points with the threshold, reconstruct the cracks and discontinuous boundaries in the image, and obtain the optimized sediment boundary contour.

[0027] As a further aspect of the present invention, the step of obtaining the estimated value of the sediment thickness specifically includes:

[0028] S401: Based on the optimized sediment boundary contour, obtain the pixel position of the corresponding sediment boundary region in the image frame at multiple angles, call the spatial projection offset value of the same pixel point at multiple angles, construct a pixel triangle structure with three points as the reference, calculate the projection offset distance corresponding to the included angle of the two sides in each group of structures, and obtain the local pixel disparity value.

[0029] S402: Based on the local pixel disparity value, extract continuous pixel groups on the sludge boundary line in the image frame, call the row and column positions between the disparity value in each group and the image plane, pair equally spaced pixel groups according to column coordinates, and map the paired disparity value to the pixel physical space to establish the depth mapping relationship from pixel to image plane and generate sludge space depth value.

[0030] S403: Based on the sludge space depth value, call the longitudinal depth change range between the starting and ending pixels of the sludge boundary in the image frame, and calculate the difference between the starting and ending depths in the longitudinal segment in the vertical direction to obtain the estimated sludge thickness value.

[0031] As a further aspect of the present invention, the method further includes:

[0032] S5: Based on the estimated sediment thickness, the disturbed area is removed, and the thickness gradient of the undisturbed area around the bottom of the hole is combined with the interpolation correction to fill in the thickness data of the disturbed area and generate sediment thickness distribution information.

[0033] The sediment thickness distribution information specifically includes corrected thickness data, interpolated data, depth information of the undisturbed region, and thickness distribution curve.

[0034] As a further aspect of the present invention, the step of obtaining the sediment thickness distribution information specifically includes:

[0035] S501: Based on the estimated sediment thickness, call the pixel position corresponding to the disturbance area marker information in the image frame, filter the thickness data corresponding to the pixels within the disturbance area, set the disturbance marker to invalid value according to the disturbance marker status, and retain the valid thickness data in the non-disturbance area to generate the thickness data value after disturbance removal.

[0036] S502: Based on the thickness data value after the disturbance removal, extract the position of the undisturbed pixel in the hole bottom edge region of the image frame, call the difference between the longitudinal and transverse thickness changes of multiple adjacent pixels, extract the thickness change trend according to the fixed window sliding range, and collect the difference into a gradient sequence to obtain the thickness gradient value of the undisturbed region.

[0037] S503: Based on the thickness gradient value of the undisturbed area, perform interpolation operation on the pixel position of the disturbed area that has been set as invalid value, use the known thickness value of the adjacent four sides and the corresponding gradient direction to perform linear compensation, calculate the interpolated thickness combination value, fill the interpolated thickness combination value into the thickness data of the corresponding position, and establish the sediment thickness distribution information.

[0038] The formula for calculating the interpolated thickness combination value is as follows:

[0039]

[0040] in, H represents the interpolated thickness combination value at the j-th pixel position in the perturbation region. j,u H j,d H j,l H j,r G represents the thickness values ​​of the four neighboring pixels above, below, left, and right of the j-th pixel, respectively. j,u G j,d G j,l G j,r η represents the thickness gradient values ​​in the four directions of top, bottom, left, and right of the j-th pixel, respectively, and η represents the compensation adjustment factor introduced by the directional gradient difference.

[0041] A machine vision-based pile hole sediment thickness identification system is used to implement the aforementioned machine vision-based pile hole sediment thickness identification method. The system includes:

[0042] The candidate region identification module acquires multi-angle image data of the bottom of the pile hole, extracts the sediment area and the boundary area of ​​the hole wall in the bottom image, performs image segmentation by combining gray value and texture features, marks the sediment area, and generates candidate images of the sediment area.

[0043] The disturbance region differentiation module extracts the brightness and saturation distribution of the image center region and the hole wall region based on the candidate image of the sediment region, calculates the brightness difference term and saturation difference term, compares the values ​​with the preset mud disturbance offset threshold, identifies the disturbance region in the image, and generates disturbance region marking information.

[0044] The boundary contour optimization module extracts the sediment boundary in the image based on the disturbance area marking information, constructs a grayscale change trend sequence, determines the start and end positions of the boundary, identifies and reconstructs cracks and discontinuities, and generates an optimized sediment boundary contour.

[0045] The thickness estimation module calculates the local parallax using image data from multiple angles based on the optimized sediment boundary contour, and calculates the spatial depth information of the sediment based on the relationship between the parallax value and the image distribution, thereby obtaining the estimated sediment thickness value.

[0046] The thickness optimization and correction module removes disturbed areas based on the estimated sediment thickness, and performs interpolation correction by combining the thickness gradient of the undisturbed area around the bottom of the hole to fill in the thickness data of the disturbed area and generate sediment thickness distribution information.

[0047] Compared with the prior art, the advantages and positive effects of the present invention are as follows:

[0048] In this invention, image segmentation is achieved by acquiring multi-angle image data, extracting sediment areas and borehole wall boundary areas, and combining grayscale values ​​and texture features. This enhances the accuracy of sediment area extraction and improves recognition precision in complex borehole environments. By comparing brightness difference and saturation difference terms with mud disturbance offset thresholds, the filtering capability against mud disturbance interference is enhanced, reducing misjudgments in image recognition. A grayscale change trend sequence is constructed using local grayscale gradient differences and combined with direction vectors for boundary recognition, which helps to reconstruct fracture or discontinuous boundaries and improve the continuity and integrity of boundary contours. The triangular structure analysis method based on multi-angle images is used to calculate local parallax, and the sediment thickness is estimated by spatial depth estimation, achieving higher accuracy compared to two-dimensional plane projection estimation. The influence of disturbed areas is eliminated by thickness gradient interpolation, achieving complete restoration of sediment thickness distribution and improving the accuracy and efficiency of sediment thickness detection. Attached Figure Description

[0049] Figure 1 This is a schematic diagram of the workflow of the present invention;

[0050] Figure 2 This is a detailed flowchart of S1 of the present invention;

[0051] Figure 3 This is a detailed flowchart of the S2 process of the present invention;

[0052] Figure 4 This is a detailed flowchart of the S3 process of the present invention;

[0053] Figure 5 This is a detailed flowchart of the S4 process of the present invention;

[0054] Figure 6 This is a detailed flowchart of S5 of the present invention;

[0055] Figure 7 This is a system flowchart of the present invention. Detailed Implementation

[0056] To make the objectives, technical solutions, and advantages of this invention clearer, the invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the invention.

[0057] In the description of this invention, it should be understood that the terms "length," "width," "upper," "lower," "front," "rear," "left," "right," "vertical," "horizontal," "top," "bottom," "inner," and "outer," etc., indicating orientation or positional relationships, are based on the orientation or positional relationships shown in the accompanying drawings and are only for the convenience of describing the invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the invention. Furthermore, in the description of this invention, "a plurality of" means two or more, unless otherwise explicitly specified.

[0058] Please see Figure 1 This invention provides a technical solution: a machine vision-based method for identifying the thickness of sediment in pile holes, comprising the following steps:

[0059] S1: Obtain multi-angle image data of the bottom of the pile hole, extract the sediment area and the boundary area of ​​the hole wall in the bottom image, perform image segmentation by combining gray value and texture features, mark the sediment area, and generate candidate images of the sediment area.

[0060] S2: Based on the candidate image of the sediment area, extract the brightness and saturation distribution of the image center area and the hole wall area, calculate the brightness difference term and saturation difference term, compare the values ​​with the preset mud disturbance offset threshold, identify the disturbance area in the image, and generate disturbance area marking information.

[0061] S3: Based on the disturbance area marking information, extract the sediment boundary in the image, obtain the local gray-level gradient difference of the boundary area, construct the gray-level change trend sequence, and calculate the direction vector. Based on the set low response threshold and high sensitivity threshold, determine the start and end positions of the boundary, identify and reconstruct the crack and discontinuity boundary, and generate the optimized sediment boundary contour.

[0062] S4: Based on the optimized sediment boundary profile, use image data from multiple angles to calculate local disparity using the triangle structure analysis method, and calculate the spatial depth information of the sediment based on the relationship between the disparity value and the image distribution to obtain the estimated sediment thickness.

[0063] S5: Based on the estimated sediment thickness, the disturbed area is removed, and the thickness gradient of the undisturbed area around the bottom of the hole is combined with the interpolation correction to fill in the thickness data of the disturbed area and generate sediment thickness distribution information.

[0064] The candidate images for the sediment region specifically include sediment region pixel data, borehole wall boundary contour data, image grayscale value distribution information, and texture feature information. The disturbance region marking information specifically includes the pixel position of the disturbance region, brightness difference term, saturation difference term, and disturbance region threshold identifier. The optimized sediment boundary contour specifically includes the boundary start position, boundary end position, grayscale gradient difference value, boundary discontinuity region, and crack reconstruction point. The sediment thickness estimation value specifically includes the disparity value, boundary depth information, local depth gradient, and initial thickness estimation value. The sediment thickness distribution information specifically includes the corrected thickness data, interpolated data, depth information of the non-disturbed region, and thickness distribution curve.

[0065] Please see Figure 2 The specific steps for obtaining candidate images of the sediment region are as follows:

[0066] S101: Obtain multi-angle image data of the bottom of the pile hole, call the gray channel values ​​and pixel texture change values ​​in multiple angle image frames, calculate the initial difference coefficient of the image pixels according to the degree of difference between the gray channel values ​​and texture change values, and collect the initial difference coefficients of multiple regions in the same image frame into a difference coefficient set after dividing them into grids, and generate image feature difference coefficient values.

[0067] To acquire multi-angle image data of the bottom of the pile hole, multiple cameras installed at the bottom of the drilling detection equipment are used to capture image frames from multiple angles during the pile hole rotation acquisition process. Each image frame records the texture state of the bottom area of ​​the pile hole at different angles, and the grayscale channel values ​​in the image frames are read as the grayscale values ​​of each pixel. By combining the grayscale fluctuations of adjacent areas of each pixel in the same image frame, the texture change value of each pixel is extracted. The grayscale channel values ​​are obtained by traversing the RGB channels of the image and using a weighted average method.

[0068] A G = 0.299 × R + 0.587 × G + 0.114 × B;

[0069] Grayscale values ​​are extracted, while texture variation values ​​are obtained by constructing a 3×3 neighborhood window and calculating the standard deviation of the grayscale values ​​between the center pixel and its eight neighboring pixels to obtain texture volatility. The initial difference coefficient is calculated by setting the grayscale value of pixel i to A. Gi The texture change value is A Ti The difference coefficient A between grayscale and texture fluctuation Di The calculation is as follows:

[0070]

[0071] To prevent the denominator from being zero, the entire image is then divided into fixed-size grid units, for example, 20×20 pixels per grid unit. The difference coefficient values ​​of the pixels within each grid are collected, and their average value is used as the image feature difference coefficient for that grid. Finally, the feature difference coefficients calculated from all grids are compiled into a set. For example, if the image resolution is 800×800, it is divided into 1600 grids, forming a set of 1600 image feature difference coefficient values, where the difference coefficient A is the difference coefficient. Di During the setting process, its value should be between 0 and 1. The weight coefficient "1" is used as an additive constant in the denominator to prevent the abnormal denominator from being 0 when both the grayscale value and the texture value are 0. Therefore, it does not involve dynamic adjustment and its value is always 1. The basis for this setting is that the grayscale and texture values ​​in the image are usually not negative. Using an increment of 1 to stabilize the coefficient is a logical and conventional operation. Taking a real image as an example, let A... Gi =80, A Ti =40, then:

[0072]

[0073] It meets the normalization calculation range and has good stability, making it suitable for pile hole image difference analysis.

[0074] S102: Based on the image feature difference coefficient value, call the feature difference coefficient of the bottom region in the image frame and the overall average difference value of the image. Use the difference between the difference coefficient and the average difference value to judge grid unit by grid unit. Filter grid units whose difference exceeds the bottom sediment judgment threshold as sediment candidate area units, and mark the outline of the area boundary of the grid unit to generate sediment area boundary judgment information.

[0075] Based on the image feature difference coefficient values, several grid cells located in the bottom center region of the image frame are selected as the target region, and the average value of their image feature difference coefficient values ​​is calculated and denoted as A. base This value is set as the average image difference feature benchmark for the bottom region of the pile hole. Then, the value of each cell in the entire set of grid difference coefficients of the whole image is compared with A. base Perform the difference calculation, and record the difference as...

[0076] ΔA i =|A i -A base |;

[0077] When ΔA i Exceeding the preset threshold T silt When this occurs, the grid cell is identified as a candidate cell for sediment, and the threshold T is used. silt The settings are based on the statistical results of the standard deviation of the grid feature difference coefficients in the image frame. Let's assume that all A values ​​in an image frame...i The mean is 12.5 and the standard deviation is 2.1. If 1.5 times the standard deviation is used as the deviation judgment standard, then:

[0078] T silt =1.5 × 2.1 = 3.15;

[0079] However, to improve accuracy, the judgment width can be expanded by setting the threshold at twice the standard deviation, i.e.:

[0080] T silt =2 × 2.1 = 4.2;

[0081] Therefore, T is selected in the actual settings. silt =4.2, when ΔA i >4.2 This indicates that the grid is marked as a candidate element for the sediment region. If the actual value is A i =18.0, A base =12.5, then:

[0082]

[0083] For all units that meet the judgment conditions, contour boundary extraction is performed. Contour segments are extracted by merging the boundaries of adjacent units that meet the conditions. This process uses the 8-neighborhood method of scanning grid number to merge all connected units into one region. After marking the region boundary, the set of coordinate points of the outer boundary of the region is output as the sediment region boundary judgment information.

[0084] S103: Based on the boundary determination information of the sediment area, call the gradient value of the texture change of the hole wall area and the gradient value of the gray value change of the boundary pixels in the pile hole image frame, use the gradient difference between the pixels inside and outside the boundary to perform boundary filtering, perform threshold determination on the difference between the determination boundary line and the surrounding hole wall boundary, and mark the area where the difference exceeds the hole wall boundary recognition threshold as the sediment area range, and obtain the sediment area candidate image.

[0085] Based on the boundary determination information of the sediment area, pixel data inside and outside the corresponding contour boundary in the pile hole image frame are extracted, and the gradient value of pixel texture change in the bottom area of ​​the hole within the boundary is called. Texture gradient values ​​of pixels in the adjacent hole wall region outside the boundary Simultaneously call the gradient values ​​of pixel grayscale changes inside and outside the boundary. and Calculate the gradient difference of texture changes respectively With gray-scale gradient difference Using max(ΔT,ΔG) as the boundary difference value ΔB, the threshold T for identifying the hole wall boundary is compared with ΔB. boundary The threshold T is compared. boundaryThe settings are based on the boundary feature statistics in the image samples. Specifically, ΔB values ​​are extracted from manually labeled areas at known hole wall boundary locations, and histogram distribution analysis is performed. Assuming a median of 7.8 and a standard deviation of 0.6, the median plus one standard deviation is taken.

[0086] T boundary =7.8 + 0.6 = 8.4;

[0087] To ensure that areas with clearly defined boundaries are detected, if a region is calculated to have ΔT = 9.1 and ΔG = 7.5, then:

[0088]

[0089] All regions defined by contour boundaries that satisfy ΔB>8.4 are selected, and all regions that meet the conditions are marked as candidate images of sediment regions. The marked result image is then output as the basis for subsequent processing.

[0090] Please see Figure 3 The specific steps for obtaining disturbance area marking information are as follows:

[0091] S201: Based on the candidate image of the sediment region, extract the pixel distribution information corresponding to the central region and the hole wall region in the image frame, call the brightness component and saturation component of each pixel in multiple regions respectively, classify the brightness component and saturation component separately according to the region, establish the brightness distribution set and saturation distribution set, and generate the region brightness and saturation set information.

[0092] Based on candidate images of the sedimentation area, a region segmentation operation is first performed on the image frame. The entire image is divided into a central region and a hole wall region according to the structural features of the pile hole. The central region is a circular area with a radius of 1 / 4 of the image width extending outward from the geometric center of the image. The hole wall region is an annular edge region within 20 pixels of the image edge. Then, each pixel in the central region and hole wall region is traversed, and its color components are extracted and converted to the HSB color space. The luminance component L and saturation component S are obtained respectively. The luminance L is obtained by converting RGB values ​​using the formula max(R,G,B), and the saturation S is obtained according to... For each pixel's L and S values, the brightness and saturation values ​​of the pixels in the central region and the aperture wall region are respectively collected into corresponding sets, forming four sets: central brightness set, central saturation set, aperture wall brightness set, and aperture wall saturation set, denoted as L. c S c L w S w By performing statistical calculations on the pixel values ​​within each set, the number of pixels N in each set is recorded. c N wIn addition, abnormal pixels (boundary value pixels with brightness less than 10 or greater than 245) are filtered out during the statistical process to ensure the stability of the statistical results. Finally, the regional brightness saturation set information is summarized for subsequent joint deviation analysis.

[0093] S202: Based on the set information of regional brightness and saturation, calculate the difference between the mean value of brightness distribution and the mean value of saturation distribution between the central region and the hole wall region. Define the difference between the mean values ​​of brightness distribution as the brightness difference term and the difference between the mean values ​​of saturation distribution as the saturation difference term. Calculate the joint deviation value of brightness and saturation to obtain the disturbance difference distribution information.

[0094] The formula for calculating the joint deviation value of brightness and saturation is:

[0095]

[0096] Among them, D i L represents the combined deviation of brightness and saturation at the i-th position in the central region. ci L represents the average brightness distribution of the i-th pixel in the central region. wi S represents the mean luminance distribution at the i-th position in the aperture wall region. ci S represents the mean saturation distribution of the i-th pixel in the central region. wi λ represents the mean saturation distribution at the i-th position in the hole wall region, and λ represents the weighting factor of the brightness term in the deviation calculation.

[0097] This indicator is used to identify mud-disturbed areas in an image. Abnormal fluctuations in local brightness and saturation caused by mud disturbance are crucial for determining the authenticity of sediment boundaries. Therefore, the joint deviation value of brightness and saturation measures the degree of change in optical properties between the image center region and the borehole wall region, as well as the joint shift of brightness and saturation under the influence of disturbance.

[0098] The weighted sum of squares of the brightness difference and saturation difference is then squared to achieve a balanced integration of the two variations; λ can be adjusted according to the different sensitivities of brightness or saturation to mud disturbance in actual scenarios; the joint deviation value D... i A larger value indicates that the pixel may have been affected by disturbance. The joint deviation value of brightness and saturation is used for fine-grained identification of non-real sediment disturbance areas (such as floating mud) in sediment images; the larger the value, the higher the probability of disturbance.

[0099] Based on the regional brightness saturation set information, the brightness set L of the central region is statistically analyzed respectively. c With the brightness set L of the hole wall region w The pixel mean is used to obtain the brightness mean difference term.

[0100]

[0101] Similarly, the statistical saturation set S c With S w The average pixel value is used to obtain the saturation mean difference term.

[0102]

[0103] Next, iterate through each pixel in the central region and call its average brightness value L. ci The average brightness L of the corresponding region in the hole wall wi And the corresponding mean saturation S ci With S wi The combined luminance and saturation deviation value for each location is calculated using the following formula:

[0104]

[0105] Where λ represents the weighting factor of brightness in the joint deviation value, its value is based on the proportional relationship between the sensitivity of the target area to changes in illumination and the influence of saturation. Taking into account the characteristic that the bottom of the pile hole often has strong light fluctuations, let the brightness weighting factor λ = 0.7, indicating that the brightness difference contributes 70% and the saturation contributes 30%. This value is obtained by extracting brightness and saturation fluctuations from multiple images with and without sediment and comparing them statistically. Fluctuations within the range [0.6, 0.8] do not affect the recognition accuracy. If the average brightness of a certain pixel is compared as L ci =180, L wi =150, mean saturation value is S ci =90, S wi =70, then:

[0106]

[0107] The final information on the distribution of disturbance differences is used as the basis for subsequent judgments.

[0108] S203: For the disturbance difference distribution information, the difference data is called pixel by pixel and compared with the preset mud disturbance offset threshold. The image pixel areas with differences greater than the mud disturbance offset threshold are identified, and the disturbance contours are grouped and delineated according to the pixel connectivity principle to obtain the disturbance area marking information.

[0109] Based on the perturbation difference distribution information, each pixel in the central region is traversed pixel by pixel to obtain its corresponding joint deviation value D. i , and the set mud disturbance offset threshold T mud The threshold T is compared. mudThe setting needs to be combined with the previously calculated ΔL and ΔS, as well as the median value of the joint deviation of the center-hole wall region in the undisturbed image samples in actual engineering. Assuming 30 pile hole image samples are analyzed, with a mean of 16.2 and a standard deviation of 2.5, then let T... mud =16.2 + 1.5 × 2.5 = 19.95, rounded down to 20.0 as the threshold benchmark, ensuring that areas with a deviation greater than 20.0 are considered disturbance marker areas. If the calculated value of a certain pixel is D i =22.3>20.0, then it is judged as a disturbed pixel. Then, the four-adjacent connectivity principle is used to group all adjacent disturbed pixels into connected components. If the number of pixels in each group is not less than the set minimum area threshold (such as 25 pixels), it is defined as a disturbed region. The boundary coordinates and pixel positions of the region are recorded, and the marker information of the disturbed region is output.

[0110] Please see Figure 4 The specific steps for obtaining the optimized sediment boundary profile are as follows:

[0111] S301: Based on the disturbance region marking information, perform boundary extraction on the image, obtain the local gray-level gradient difference between the sediment region and the hole wall region, calculate the gray-level change of each pixel in the image, and perform local boundary extraction based on the gray-level difference to obtain the local gray-level gradient difference.

[0112] Based on the perturbation region labeling information, boundary extraction is performed on the image. First, the pixel locations marked as perturbation regions in the image are used as a candidate point set for boundary detection. The gray value of each candidate point is extracted, and a 3×3 or 5×5 pixel neighborhood window centered on that point is constructed. The gray value difference between the center pixel and its surrounding neighboring pixels is calculated, and the gray value change is denoted as ΔG. i =|G i -G j |, where G i G represents the grayscale value of the center pixel. j To obtain the grayscale value of adjacent pixels, the above steps are repeated for pixels at the edge of the disturbance region and those in the adjacent hole wall region, respectively, to obtain the local grayscale difference distribution at that location. Then, each pixel location is traversed throughout the entire image, and its grayscale value is compared with the grayscale values ​​of its adjacent pixels to perform a difference calculation. The local grayscale change of the entire image is extracted as a grayscale change map. Furthermore, by calculating the local grayscale difference between pixels at the edge of the disturbance region and corresponding pixels in the hole wall region, the distribution range of this difference at the disturbance boundary is summarized and statistically analyzed. Let the grayscale value of a disturbance boundary point be G. i =132, the pixel grayscale of the adjacent hole wall region is G j=109, then the grayscale difference is ΔG=|132-109|=23. Set the lower limit of the local gradient difference threshold to 15. If the difference is greater than 15, it is retained as a boundary feature pixel. Finally, the local grayscale gradient difference that meets the conditions is output, which is used to construct the subsequent boundary change trend sequence.

[0113] S302: Based on the local gray-level gradient difference, construct a gray-level change trend sequence and calculate the direction vector of each boundary point in the image. By the gray-level change trend, determine the boundary direction and generate the boundary gray-level change trend sequence and direction vector.

[0114] Based on the local gray-level gradient difference, the gray-level changes of adjacent boundary points are sequentially arranged according to the pixel positions in the boundary extraction results of the image, constructing a gray-level change trend sequence. Let the continuous boundary points be P1, P2, ..., P n Their grayscale values ​​are G1, G2, ..., G n The trend sequence is then ΔG. k =G k+1 -G k Then, the direction vector V of the boundary points is constructed by the spatial coordinate difference. k =(x k+1 -x k ,y k+1 -y k ), where (x k ,y k P is the boundary point. k The coordinate position is used to record the spatial distribution of the boundary direction in the image. Then, by traversing all boundary points, the positions of the alternating positive and negative changes in the gray-level trend are counted to determine the boundary fluctuation points and the stable extension sections of the boundary. If there are five consecutive points (G1=130,G2=134,G3=129,G4=133,G5=127), then its gray-level trend sequence is [+4,-5,+4,-6]. If the trend has multiple reversals, it indicates that the boundary gray-level disturbance is severe. Combined with the trend change of its direction vector, the change of the direction angle is counted. For example, if the direction vector from point P1 to P2 is V=(3,1) and the direction vector from P2 to P3 is (-2,0), it indicates that there is a significant turning point in the boundary direction. The trend sequence and direction vector are combined to generate the boundary gray-level change trend sequence and direction record.

[0115] S303: Based on the boundary gray-scale change trend sequence and direction vector, combined with the preset low response threshold and high sensitivity threshold, the start and end positions of the boundary are determined. By comparing the gray-scale changes of the boundary points with the threshold, the cracks and discontinuous boundaries in the image are reconstructed to obtain the optimized sediment boundary contour.

[0116] Based on the boundary grayscale change trend sequence and direction vector, the grayscale change value of each boundary point is called and compared with the preset low response threshold T. low With high sensitivity threshold T high Comparison, where T low Used to mark the starting response position of weak grayscale boundaries, the setting is based on 0.75 times the average grayscale variation of the entire image. If the average grayscale fluctuation in the image is 18, then T is set as follows: low =0.75 × 18 = 13.5, rounded down to 14, T high A high-sensitivity response threshold, used to identify locations of strong grayscale changes, is set to the average grayscale change plus 1.25 times the standard deviation. If the standard deviation is 5, then T... high =18 + 1.25 × 5 = 24.25, set to 24 to ensure the response covers the main boundary points of the image. In the actual comparison process, if the grayscale change of a certain boundary point is 22, then T is satisfied. low <22 <T high Points that can be identified as valid boundary extension points are discarded if the grayscale change is less than 14, and marked as strong response endpoints if it is greater than 24, based on the trend sequence where the grayscale change is continuously greater than T. low And less than T high The segment extracts the starting and ending point indices of the boundary and marks the corresponding point coordinates as boundary segments. Then, it judges the tortuous segments of the boundary by whether the angle of continuous change of the direction vector is greater than the set turning threshold (e.g., 15°). For areas with discontinuity, it repairs the fracture path by linear interpolation based on the positions of the preceding and following boundary segments. Finally, it forms a complete and continuous crack and discontinuous boundary path in the image and outputs the optimized sediment boundary contour.

[0117] Please see Figure 5 The specific steps for obtaining the estimated value of sediment thickness are as follows:

[0118] S401: Based on the optimized sediment boundary contour, obtain the pixel position of the corresponding sediment boundary region in the image frame at multiple angles, call the spatial projection offset value of the same pixel at multiple angles, construct a pixel triangle structure based on three points, calculate the projection offset distance corresponding to the included angle of the two sides in each group of structures, and obtain the local pixel disparity value.

[0119] Based on the optimized sediment boundary contour, the pixel coordinates of the corresponding boundary region in each frame are first extracted from the multi-angle image frames. A spatial mapping relationship between pixels in image frames under different perspectives is established. Three images at different angles are selected, and the position of one boundary pixel in each of the three images is set as (x1, y1), (x2, y2), and (x3, y3). The spatial projection offset relationship of the three points is constructed, and a pixel triangle structure is defined by connecting the three points. Using the position difference of the pixels between the three points in the image coordinate system as a benchmark, the pixel displacement difference corresponding to the included angle between two sides in each structure is calculated. That is, the cosine theorem is constructed using the lengths of the three sides of the triangle and the included angle. The Euclidean distance between two adjacent points is then calculated. d 23 d 13 Then, based on the angular relationships of triangles, analyze the included angle θ. 123 The projected offset distance δ = d corresponding to the included angle is obtained. 13 -(d 12 ·cosθ 123 Let this offset value represent the local pixel disparity value within the three-point structure. If the coordinates of the three points are (100, 200), (105, 202), and (110, 203), then d is calculated. 12 =5.1, d 13 =10.2, the included angle θ =27°, then δ =10.2-5.1·cos(27°)≈10.2-4.54=5.66. Finally, the multiple three-point structures in the image are traversed and calculated to output the pixel disparity value sequence of all three-point structures.

[0120] S402: Based on local pixel disparity values, extract continuous pixel groups on the sediment boundary line in the image frame, call the row and column positions between the disparity values ​​in each group and the image plane, pair equally spaced pixel groups according to column coordinates, and map the paired disparity values ​​to the pixel physical space to establish the depth mapping relationship from pixel to image plane and generate sediment space depth values.

[0121] Based on local pixel disparity values, continuously distributed boundary pixel groups are extracted along the sediment boundary line. Let each group of pixels be (P... i1 ,P i2 ,...,P in ), sequentially call the disparity value of each point in the group and its row and column coordinates in the image frame, let the image position of the pixel be (x k ,y k The disparity value is δ. k , for each column of coordinates x k Based on this, equally spaced pixel groups are paired in different frames along the column direction. This involves uniformly pairing and comparing the column values ​​of pixels from different viewpoints under the same row number (y), and combining the unified disparity value with the column coordinates to construct a disparity-column coordinate pair (x...).k ,δ k Based on known camera system parameters such as focal length f = 12mm, pixel pitch p = 0.005mm, and viewing angle difference θ = 10°, the depth calculation relationship is as follows:

[0122]

[0123] Z k Let B be the physical depth of a pixel in the image plane, and let B be the camera baseline length. Assume B = 50mm. If a pixel has a depth δ... k =5.66, then:

[0124]

[0125] A mapping table is built based on the calculation results of all pixels, and the depth value of each pixel is output to complete the conversion from pixel position to image plane depth space, generating sediment space depth value.

[0126] S403: Based on the sludge spatial depth value, call the vertical depth change range between the starting and ending pixels of the sludge boundary in the image frame, and calculate the difference between the starting and ending depths in the vertical segment in the vertical direction to obtain the estimated sludge thickness.

[0127] Based on the depth value of the sediment space, select the starting pixel point P of the sediment boundary in the image frame. s With the end pixel P e Call the spatial depth values ​​of the two in the vertical direction (Y-axis direction), which are Z and Z respectively. s With Z e The estimated value of sediment thickness is defined as the depth difference between two points, using the formula:

[0128] H = |Z e -Z s |;

[0129] If Z s =21200mm, Z e =21530mm, then the estimated thickness of the sediment is:

[0130] H = |21530-21200| = 330mm;

[0131] Simultaneously, based on the Y-axis coordinates, it is determined whether there is an inconsistency in slope between two points. If there is an obvious gradient change trend in the image, multiple boundary pixels along the vertical direction are divided into segments, with each segment consisting of 10 pixels. The difference between the starting depth and the ending depth within each segment is calculated. After statistically analyzing the depth changes of all segments, the maximum value is taken as the thickness estimation result. The fluctuation values ​​in continuous segments are then subjected to difference filtering to remove occasional abrupt error points, and the final estimated value of sediment thickness is output.

[0132] Please see Figure 6 The specific steps for obtaining information on sediment thickness distribution are as follows:

[0133] S501: Based on the estimated sediment thickness, call the corresponding pixel position in the disturbance area marker information in the image frame, filter the thickness data corresponding to the pixels within the disturbance area, set the disturbance marker to invalid value according to the disturbance marker status, and retain the valid thickness data in the non-disturbance area to generate the thickness data value after disturbance removal.

[0134] Based on the estimated sediment thickness, the process first iterates through all pixel positions in the image frame, comparing them with the pixel marking status in the disturbance region marking information. Each pixel marked as a disturbance is extracted as an interference target, and the thickness value at the corresponding position is set to an invalid state, for example, recorded with the special identifier "NaN". This process achieves matching by calling the pixel coordinate index and covering it with a mask matrix, thereby retaining the thickness values ​​of all pixels not marked as disturbance as valid data, forming a preliminary thickness dataset after disturbance removal. In this process, for pixels near the boundary of the disturbance region, it is also necessary to determine their disturbance marking confidence or disturbance level. If the interference weight is less than the set minimum judgment standard, their thickness value is still retained as valid. This minimum judgment standard corresponds to the disturbance confidence threshold T set in the disturbance identification stage. d =0.4, this value is derived from the statistical results of the actual recognition error in the perturbed image frame. Assuming that the maximum range of misidentification error is below 0.35, in order to improve the recognition reliability, a conservative value of 0.4 is set as the threshold. If the confidence of a pixel is 0.38, it is removed, and if it is greater than or equal to 0.4, it is retained. For example, if the thickness value of a pixel is 315mm and the perturbation confidence is 0.42, it is recorded as valid. Otherwise, it is set as "NaN". Finally, the thickness values ​​of all perturbed pixels are cleared and the set of thickness data values ​​after perturbation removal is output.

[0135] S502: Based on the thickness data value after disturbance removal, extract the position of the undisturbed pixel in the hole bottom edge region of the image frame, call the difference between the longitudinal and transverse thickness changes of multiple adjacent pixels, extract the thickness change trend according to the fixed window sliding range, and collect the difference into a gradient series to obtain the thickness gradient value of the undisturbed region.

[0136] Based on the thickness data value after perturbation removal, the pixel row and column coordinates of the hole bottom edge region in the image frame are traversed. Each pixel is checked to see if it is not perturbed. If it is not perturbed and the thickness value is valid, the thickness gradient calculation process is entered. The thickness values ​​of the adjacent pixels in the four directions (up, down, left, and right) are called respectively, and the vertical thickness difference ΔH is calculated. v =H j,u -H j,d With the difference in transverse thickness ΔH h =H j,l -H j,r The sliding window is set to a 3×3 area. The above difference calculation is performed on the center pixel within each window, and the corresponding gradient values ​​are aggregated into a gradient sequence. This sequence records the variation trend of edge region thickness in different directions of the image plane. If the thickness at the center point of a window is 310mm, the thickness of the pixel above it is 320mm, and the thickness of the pixel below it is 305mm, then the vertical gradient is ΔH. v =320-305=15, similarly, the lateral gradient is ΔH h =308-312=-4. Record these two differences into the vertical and horizontal gradient sequences respectively. The sliding window moves within the image frame in a row-first manner, sliding 1 pixel at a time, gradually extracting the thickness changes in the entire undisturbed area, and finally forming a complete dataset of thickness gradient values ​​in the undisturbed area.

[0137] S503: Based on the thickness gradient value of the undisturbed area, perform interpolation operation on the pixel position of the disturbed area that has been set as invalid value, use the known thickness value of the adjacent four sides and the corresponding gradient direction to perform linear compensation, calculate the interpolated thickness combination value, fill the interpolated thickness combination value into the thickness data of the corresponding position, and establish the sediment thickness distribution information.

[0138] The formula for calculating the interpolated thickness combination value is:

[0139]

[0140] in, H represents the interpolated thickness combination value at the j-th pixel position in the perturbation region. j,u H j,d H j,l H j,r G represents the thickness values ​​of the four neighboring pixels above, below, left, and right of the j-th pixel, respectively. j,u G j,d G j,l G j,r These represent the thickness gradient values ​​in the four directions (up, down, left, and right) of the j-th pixel, respectively, and η represents the compensation adjustment factor introduced by the directional gradient difference.

[0141] This index is used to recover sediment thickness information that cannot be directly observed under the influence of mud disturbance. Because the image of the disturbed area is severely damaged, the thickness cannot be directly extracted and needs to be inferred from the data of the surrounding undisturbed area.

[0142] First, the thickness values ​​in four neighboring directions are averaged and smoothed, and then the thickness of the central perturbation pixel is approximately estimated. By introducing weighted compensation of the neighborhood thickness gradient, the thickness variation trend of the local area can be taken into account, thereby improving the continuity and physical rationality of the interpolation.

[0143] The specific steps for filling in the thickness data at the corresponding positions are as follows: For each perturbation marker pixel position j, calculate the thickness data according to the above formula based on the surrounding effective thickness data and local gradient. Will The thickness data matrix is ​​directly assigned to the pixel position, forming a complete and continuous thickness distribution map. During the processing, it is ensured that there are no thickness gaps inside the disturbed area, thereby restoring the complete spatial information of sediment thickness. The thickness combination value is estimated by the thickness of the disturbed area and the thickness change trend of the surrounding undisturbed area, so that the overall thickness distribution is continuous and conforms to the physical deposition law.

[0144] Based on the thickness gradient value of the undisturbed region, iterate through all data points in the image frame that are marked as perturbed regions and have invalid thickness values. For each perturbed pixel position j, call the valid thickness values ​​of its four neighboring pixels in the up, down, left, and right directions, denoted as H respectively. j,u H j,d H j,l H j,r And extract the thickness gradient value G in the corresponding direction. j,u G j,d G j,l G j,r The interpolated thickness combination value is calculated using the following interpolation compensation formula:

[0145]

[0146] Where η is the compensation adjustment factor introduced by the directional gradient difference, and is set based on the average gradient amplitude of the boundary region and the statistical range of interpolation error. Assuming the average gradient of the effective region in the image is 11.5 and the standard deviation is 3.2, the median adjustment factor is selected as η = 0.4, which can control the influence rate of the compensation term on the total thickness interpolation to not exceed 10%. If the thicknesses of the neighboring pixels of a certain perturbed pixel are H... j,u =320, H j,d =310, H j,l =305, H j,r =308, corresponding to a gradient value of G j,u =15, G j,d =-10, G j,l =5, Gj,r =-7, then:

[0147]

[0148] The calculated interpolated thickness is written into the original perturbation location thickness matrix. This process is repeated to traverse all pixels in the perturbation area, and finally the sediment thickness data in the entire image is filled, establishing complete sediment thickness distribution information.

[0149] Please see Figure 7 A machine vision-based pile hole sediment thickness recognition system is used to execute the aforementioned machine vision-based pile hole sediment thickness recognition method. The system includes:

[0150] The candidate region identification module acquires multi-angle image data of the bottom of the pile hole, extracts the sediment area and the boundary area of ​​the hole wall in the bottom image, performs image segmentation by combining gray value and texture features, marks the sediment area, and generates candidate images of the sediment area.

[0151] The disturbance region differentiation module extracts the brightness and saturation distribution of the image center region and the borehole wall region based on the candidate image of the sediment region, calculates the brightness difference term and saturation difference term, compares the values ​​with the preset mud disturbance offset threshold, identifies the disturbance region in the image, and generates disturbance region marking information.

[0152] The boundary contour optimization module extracts the sediment boundary in the image based on the disturbance area marking information, constructs a grayscale change trend sequence, determines the start and end positions of the boundary, identifies and reconstructs crack and discontinuity boundaries, and generates the optimized sediment boundary contour.

[0153] The thickness estimation module calculates the local parallax using image data from multiple angles based on the optimized sediment boundary contour, and calculates the spatial depth information of the sediment based on the relationship between the parallax value and the image distribution, thereby obtaining the estimated sediment thickness value.

[0154] The thickness optimization and correction module removes disturbed areas based on the estimated sediment thickness, and performs interpolation correction by combining the thickness gradient of the undisturbed area around the bottom of the hole to fill in the thickness data of the disturbed area and generate sediment thickness distribution information.

[0155] The above are merely preferred embodiments of the present invention and are not intended to limit the present invention in any other way. Any person skilled in the art may make changes or modifications to the above-disclosed technical content to create equivalent embodiments that can be applied to other fields. However, any simple modifications, equivalent changes, and modifications made to the above embodiments based on the technical essence of the present invention without departing from the scope of the present invention shall still fall within the protection scope of the present invention.

Claims

1. A machine vision-based method for identifying the thickness of sediment in pile holes, characterized in that, Includes the following steps: S1: Obtain multi-angle image data of the bottom of the pile hole, extract the sediment area and the boundary area of ​​the hole wall in the bottom image, perform image segmentation by combining gray value and texture features, mark the sediment area, and generate candidate images of the sediment area. S2: Based on the candidate image of the sediment area, extract the brightness and saturation distribution of the image center area and the hole wall area, calculate the brightness difference term and saturation difference term, compare the values ​​with the preset mud disturbance offset threshold, identify the disturbance area in the image, and generate disturbance area marking information. S3: Based on the disturbance area marking information, extract the sediment boundary in the image, obtain the local gray-level gradient difference of the boundary area, construct the gray-level change trend sequence, determine the start and end positions of the boundary based on the set low response threshold and high sensitivity threshold, identify and reconstruct the crack and discontinuity boundary, and generate the optimized sediment boundary contour. S4: Based on the optimized sediment boundary contour, using image data from multiple angles, calculate the local parallax using the triangle structure analysis method, and calculate the spatial depth information of the sediment based on the relationship between the parallax value and the image distribution to obtain the estimated sediment thickness.

2. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 1, characterized in that, The candidate image of the sediment region specifically includes sediment region pixel data, pore wall boundary contour data, image grayscale value distribution information, and texture feature information. The disturbance region marking information specifically includes the pixel position of the disturbance region, brightness difference, saturation difference, and disturbance region threshold identifier. The optimized sediment boundary contour specifically includes the boundary start position, boundary end position, grayscale gradient difference, boundary discontinuity region, and crack reconstruction point. The sediment thickness estimation value specifically includes the disparity value, boundary depth information, local depth gradient, and initial thickness estimation value.

3. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 2, characterized in that, The specific steps for obtaining the candidate image of the sediment region are as follows: S101: Obtain multi-angle image data of the bottom of the pile hole, call the gray channel values ​​and pixel texture change values ​​in multiple angle image frames, calculate the initial difference coefficient of the image pixels according to the degree of difference between the gray channel values ​​and texture change values, and collect the initial difference coefficients of multiple regions in the same image frame into a difference coefficient set after dividing them into grids, and generate image feature difference coefficient values. S102: Based on the image feature difference coefficient value, call the feature difference coefficient of the bottom region in the image frame and the overall average difference value of the image, use the difference between the difference coefficient and the average difference value to judge grid unit by grid unit, filter grid units whose difference exceeds the bottom sediment judgment threshold as sediment candidate region units, and mark the contour of the region boundary corresponding to the grid unit to generate sediment region boundary judgment information. S103: Based on the boundary determination information of the sediment area, call the gradient value of texture change of the hole wall area and the gradient value of gray change of boundary pixels in the pile hole image frame, use the gradient difference of pixels inside and outside the boundary to perform boundary filtering, perform threshold determination on the difference between the determination boundary line and the surrounding hole wall boundary, mark the area with the difference exceeding the hole wall boundary recognition threshold as the sediment area range, and obtain the sediment area candidate image.

4. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 3, characterized in that, The specific steps for obtaining the disturbance region marking information are as follows: S201: Based on the candidate image of the sediment area, extract the pixel distribution information corresponding to the central area and the hole wall area in the image frame, call the brightness component and saturation component of each pixel in multiple areas respectively, classify the brightness component and saturation component separately according to the area, establish a brightness distribution set and a saturation distribution set, and generate regional brightness and saturation set information. S202: Based on the set information of brightness and saturation in the region, calculate the difference between the mean value of brightness distribution and the mean value of saturation distribution between the central region and the hole wall region, define the difference between the mean value of brightness distribution as the brightness difference term, define the difference between the mean value of saturation distribution as the saturation difference term, calculate the joint deviation value of brightness and saturation, and obtain the disturbance difference distribution information; S203: For the disturbance difference distribution information, the difference data is called pixel by pixel and compared with the preset mud disturbance offset threshold. Image pixel areas with differences greater than the mud disturbance offset threshold are identified, and disturbance contours are delineated according to the pixel connectivity principle to obtain disturbance area marking information.

5. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 4, characterized in that, The formula for calculating the joint deviation value of brightness and saturation is as follows: Among them, D i L represents the combined deviation of brightness and saturation at the i-th position in the central region. ci L represents the average brightness distribution of the i-th pixel in the central region. wi S represents the mean luminance distribution at the i-th position in the aperture wall region. ci S represents the mean saturation distribution of the i-th pixel in the central region. wi λ represents the mean saturation distribution at the i-th position in the hole wall region, and λ represents the weighting factor of the brightness term in the deviation calculation.

6. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 5, characterized in that, The specific steps for obtaining the optimized sediment boundary profile are as follows: S301: Based on the disturbance area marking information, perform boundary extraction on the image, obtain the local gray-level gradient difference between the sediment area and the hole wall area, calculate the gray-level change of each pixel in the image, and perform local boundary extraction based on the gray-level difference to obtain the local gray-level gradient difference. S302: Based on the local gray-level gradient difference, construct a gray-level change trend sequence, calculate the direction vector of each boundary point in the image, determine the boundary direction through the gray-level change trend, and generate a boundary gray-level change trend sequence and direction vector; S303: Based on the boundary grayscale change trend sequence and direction vector, combined with the preset low response threshold and high sensitivity threshold, determine the start and end positions of the boundary, filter by comparing the grayscale changes of the boundary points with the threshold, reconstruct the cracks and discontinuous boundaries in the image, and obtain the optimized sediment boundary contour.

7. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 6, characterized in that, The specific steps for obtaining the estimated sediment thickness are as follows: S401: Based on the optimized sediment boundary contour, obtain the pixel position of the corresponding sediment boundary region in the image frame at multiple angles, call the spatial projection offset value of the same pixel point at multiple angles, construct a pixel triangle structure with three points as the reference, calculate the projection offset distance corresponding to the included angle of the two sides in each group of structures, and obtain the local pixel disparity value. S402: Based on the local pixel disparity value, extract continuous pixel groups on the sludge boundary line in the image frame, call the row and column positions between the disparity value in each group and the image plane, pair equally spaced pixel groups according to column coordinates, and map the paired disparity value to the pixel physical space to establish the depth mapping relationship from pixel to image plane and generate sludge space depth value. S403: Based on the sludge space depth value, call the longitudinal depth change range between the starting and ending pixels of the sludge boundary in the image frame, and calculate the difference between the starting and ending depths in the longitudinal segment in the vertical direction to obtain the estimated sludge thickness value.

8. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 7, characterized in that, The method further includes: S5: Based on the estimated sediment thickness, the disturbed area is removed, and the thickness gradient of the undisturbed area around the bottom of the hole is combined with the interpolation correction to fill in the thickness data of the disturbed area and generate sediment thickness distribution information. The sediment thickness distribution information specifically includes corrected thickness data, interpolated data, depth information of the undisturbed region, and thickness distribution curve.

9. The method for identifying the thickness of sediment in pile holes based on machine vision according to claim 8, characterized in that, The specific steps for obtaining the sediment thickness distribution information are as follows: S501: Based on the estimated sediment thickness, call the pixel position corresponding to the disturbance area marker information in the image frame, filter the thickness data corresponding to the pixels within the disturbance area, set the disturbance marker to invalid value according to the disturbance marker status, and retain the valid thickness data in the non-disturbance area to generate the thickness data value after disturbance removal. S502: Based on the thickness data value after the disturbance removal, extract the position of the undisturbed pixel in the hole bottom edge region of the image frame, call the difference between the longitudinal and transverse thickness changes of multiple adjacent pixels, extract the thickness change trend according to the fixed window sliding range, and collect the difference into a gradient sequence to obtain the thickness gradient value of the undisturbed region. S503: Based on the thickness gradient value of the undisturbed area, perform interpolation operation on the pixel position of the disturbed area that has been set as invalid value, use the known thickness value of the adjacent four sides and the corresponding gradient direction to perform linear compensation, calculate the interpolated thickness combination value, fill the interpolated thickness combination value into the thickness data of the corresponding position, and establish the sediment thickness distribution information. The formula for calculating the interpolated thickness combination value is as follows: in, H represents the interpolated thickness combination value at the j-th pixel position in the perturbation region. j,u H j,d H j,l H j,r G represents the thickness values ​​of the four neighboring pixels above, below, left, and right of the j-th pixel, respectively. j,u G j,d G j,l G j,r η represents the thickness gradient values ​​in the four directions of top, bottom, left, and right of the j-th pixel, respectively, and η represents the compensation adjustment factor introduced by the directional gradient difference.

10. A machine vision-based system for identifying the thickness of sediment in pile holes, characterized in that, The system is used to implement the machine vision-based pile hole sediment thickness identification method according to any one of claims 1-9, and the system includes: The candidate region identification module acquires multi-angle image data of the bottom of the pile hole, extracts the sediment area and the boundary area of ​​the hole wall in the bottom image, performs image segmentation by combining gray value and texture features, marks the sediment area, and generates candidate images of the sediment area. The disturbance region differentiation module extracts the brightness and saturation distribution of the image center region and the hole wall region based on the candidate image of the sediment region, calculates the brightness difference term and saturation difference term, compares the values ​​with the preset mud disturbance offset threshold, identifies the disturbance region in the image, and generates disturbance region marking information. The boundary contour optimization module extracts the sediment boundary in the image based on the disturbance area marking information, constructs a grayscale change trend sequence, determines the start and end positions of the boundary, identifies and reconstructs cracks and discontinuities, and generates an optimized sediment boundary contour. The thickness estimation module calculates the local parallax using image data from multiple angles based on the optimized sediment boundary contour, and calculates the spatial depth information of the sediment based on the relationship between the parallax value and the image distribution, thereby obtaining the estimated sediment thickness value. The thickness optimization and correction module removes disturbed areas based on the estimated sediment thickness, and performs interpolation correction by combining the thickness gradient of the undisturbed area around the bottom of the hole to fill in the thickness data of the disturbed area and generate sediment thickness distribution information.