CN-121998980-A - Metal pipeline anchor degree detection method and system based on image analysis
Abstract
The application discloses a metal pipeline anchor line degree detection method and system based on image analysis, and relates to the technical field of pipeline quality detection, wherein the method comprises the steps of collecting panoramic images; identifying a core area of the independent anchor line pit, generating a profile mask of the independent anchor line pit, dividing the profile of the anchor line pit, determining the profile of the independent anchor line pit, determining a depth predicted value of the independent anchor line pit, screening key detection pits, dividing the key detection pits into a plurality of measurement groups, controlling a photoelectric measuring head to project measurement light to the corresponding measurement groups, calculating actual depth data of the key detection pits based on the reflected light, and summarizing all the actual depth data to obtain an anchor line degree detection result. According to the method, three-dimensional space coordinates of each anchor pattern recess can be accurately obtained, the deepest anchor pattern is directly positioned, key recesses with larger influence on the overall anchor pattern depth average value are screened based on the anchor pattern depth predicted value, the general recesses are ignored, and invalid measurement operation is directly reduced by more than 50%.
Inventors
- FENG BO
- YANG JIAYI
- XUE JINGYUE
- LIU MENGCONG
Assignees
- 延安大学
Dates
- Publication Date
- 20260508
- Application Date
- 20260409
Claims (10)
- 1. The metal pipeline anchor degree detection method based on image analysis is characterized by comprising the following steps of: Collecting a panoramic image of the interior of a metal pipeline by using a three-dimensional industrial camera, wherein the panoramic image comprises a two-dimensional texture image and three-dimensional point cloud data; preprocessing the panoramic image and strengthening anchor line characteristics to form a strengthened two-dimensional contour image and optimized three-dimensional point cloud data; The method comprises the steps of identifying a potential independent anchor line concave core area in a reinforced two-dimensional profile image by adopting a watershed segmentation algorithm, marking the core area as an initial seed point, generating a profile mask of an independent anchor line concave in the reinforced two-dimensional profile image by utilizing a lightweight convolutional neural network, combining the initial seed point and the profile mask, segmenting communicated anchor line concave profiles by taking the optimized three-dimensional point cloud data as an auxiliary judgment basis, and determining all independent anchor line concave profiles; determining a depth estimated value of each independent anchor pattern recess based on the optimized three-dimensional point cloud data corresponding to each independent anchor pattern recess profile; determining average predicted values according to the depth predicted values of all the independent anchor line recesses, and screening key detection recesses in the independent anchor line recesses based on the size relation between the depth predicted value of each independent anchor line recess and the average predicted value; Dividing the key detection recesses into a plurality of measurement groups according to a preset circumferential angle grouping threshold, wherein each measurement group corresponds to a target circumferential angle; Controlling the photoelectric measuring head to rotate to each target circumferential angle, enabling the photoelectric measuring head to project measuring light to the corresponding measuring group, converting a reflected light signal of the measuring light into an electric signal, and calculating actual depth data of each key detection recess in the measuring group based on the intensity and change rule of the electric signal; And summarizing all the actual depth data of the whole metal pipeline to obtain an anchor texture degree detection result.
- 2. The method for detecting the anchor degree of the metal pipeline based on image analysis according to claim 1, wherein the preprocessing and anchor feature strengthening processing of the panoramic image comprises the following steps: filtering and denoising the two-dimensional texture image by adopting a Gaussian filtering algorithm; carrying out contrast enhancement on the two-dimensional texture image after noise reduction by adopting a histogram equalization algorithm, and carrying out gray value normalization processing on the two-dimensional texture image after enhancement processing; Performing edge detection on the normalized two-dimensional texture image by adopting a Canny edge detection algorithm to generate an edge detection binary image; Performing expansion-corrosion morphological operation on the edge detection binary image to obtain the reinforced two-dimensional texture image; and carrying out abnormal point elimination and smoothing treatment on the three-dimensional point cloud data to obtain the optimized three-dimensional point cloud data.
- 3. The method for detecting the anchor degree of the metal pipeline based on image analysis according to claim 1, wherein the method for identifying the initial seed point in the two-dimensional profile image after strengthening comprises the following steps: Performing fixed threshold binarization segmentation on the two-dimensional contour image to generate a foreground background binary image; And calculating the Euclidean distance from each foreground pixel to the nearest background pixel by adopting a Euclidean distance transformation method for the foreground background binary image, generating a distance transformation image, carrying out threshold segmentation on the distance transformation image, and marking the pixel points with the distance value larger than a distance threshold as the initial seed points.
- 4. The method for detecting the anchor degree of the metal pipeline based on the image analysis according to claim 1, wherein the lightweight convolutional neural network comprises an input layer, a first convolutional layer, a first pooling layer, a second convolutional layer, a second pooling layer, a third convolutional layer, an activation layer and a full connection layer which are sequentially connected.
- 5. The method for detecting the anchor degree of a metal pipeline based on image analysis according to claim 1, wherein the method for determining the depth predicted value of each independent anchor recess comprises the following steps: extracting three-dimensional coordinates of all pixel points in the independent anchor line concave outline, determining the pixel point with the minimum Z value in the three-dimensional coordinates as the deepest part of the independent anchor line concave, and recording the corresponding deepest Z value of the anchor line; Calculating an arithmetic average value of Z values of all pixel points of a flattened area of the inner wall of the metal pipeline in the optimized three-dimensional point cloud data, and taking the arithmetic average value as a radial reference plane Z value; And calculating the difference value between the Z value of the radial reference surface and the Z value at the deepest part of the anchor lines to obtain the depth predicted value.
- 6. The method for detecting the anchor degree of the metal pipeline based on image analysis according to claim 1, wherein the method for screening the key detection recess comprises the following steps: Calculating the difference value between the depth predicted value and the average predicted value of each independent anchor line depression, and determining the absolute value of the ratio of the difference value to the average predicted value; And if the absolute value is larger than 20%, the corresponding independent anchor line recess is used as the key detection recess.
- 7. The method for detecting the anchor degree of a metal pipeline based on image analysis according to claim 1, wherein the method for dividing the measurement group comprises the following steps: selecting a circumferential angle of a first key detection recess as a central angle, and classifying the first key detection recess and all other key detection recesses, of which the difference value with the central angle is within the circumferential angle grouping threshold, as a first measurement group; selecting the circumferential angle of the first ungrouped key detection recess as a new central angle, and classifying the first ungrouped key detection recess and all other ungrouped key detection recesses with the difference value of the new central angle within the circumferential angle grouping threshold as a second measurement group; the above operation is repeated until all the key detection recesses are completed grouping.
- 8. The method for detecting the anchor degree of a metal pipeline based on image analysis according to claim 1, wherein the measuring light is a continuous straight line, and when calculating the actual depth data, three-dimensional coordinates of the deepest part of each key detection recess are obtained, and only the actual depth data under the three-dimensional coordinates are extracted.
- 9. The method for detecting the anchor degree of the metal pipeline based on image analysis according to claim 1, wherein the method for summarizing the actual depth data comprises the following steps: Calculating an anchor line depth average value of the whole metal pipeline based on the actual depth data; counting the number proportion of the key detection depressions in different depth intervals; analyzing the distribution rule of the anchor lines in the axial direction and the circumferential direction of the metal pipeline, and identifying an abnormal region.
- 10. A system for applying the image analysis-based metal pipe anchoring degree detection method according to any one of claims 1 to 9, characterized in that the system comprises: The image acquisition module is used for acquiring a panoramic image of the interior of the metal pipeline by using a three-dimensional industrial camera, wherein the panoramic image comprises a two-dimensional texture image and three-dimensional point cloud data; The preprocessing module is used for preprocessing the panoramic image and strengthening anchor line characteristics to form a strengthened two-dimensional contour image and optimized three-dimensional point cloud data; The contour segmentation module is used for identifying a potential independent anchor line concave core area in the reinforced two-dimensional contour image by adopting a watershed segmentation algorithm, marking the core area as an initial seed point, generating a contour mask of the independent anchor line concave in the reinforced two-dimensional contour image by utilizing a lightweight convolutional neural network, combining the initial seed point and the contour mask, segmenting the communicated anchor line concave contour by taking the optimized three-dimensional point cloud data as an auxiliary judgment basis, and determining all the independent anchor line concave contours; the depth estimation module is used for determining a depth estimated value of each independent anchor pattern recess based on the optimized three-dimensional point cloud data corresponding to each independent anchor pattern recess profile; The recess screening module is used for determining an average predicted value according to the depth predicted values of all the independent anchor pattern recesses, and screening key detection recesses in the independent anchor pattern recesses based on the size relation between the depth predicted value and the average predicted value of each independent anchor pattern recess; the measurement group dividing module is used for dividing the key detection recess into a plurality of measurement groups according to a preset circumferential angle grouping threshold value, and each measurement group corresponds to one target circumferential angle; The depth measurement module is used for controlling the photoelectric measuring head to rotate to each target circumferential angle, enabling the photoelectric measuring head to project measurement light to the corresponding measurement group, converting a reflected light signal of the measurement light into an electric signal, and calculating actual depth data of each key detection recess in the measurement group based on the intensity and change rule of the electric signal; and the data summarizing module is used for summarizing all the actual depth data of the whole metal pipeline to obtain an anchor line degree detection result.
Description
Metal pipeline anchor degree detection method and system based on image analysis Technical Field The application relates to the technical field of pipeline quality detection, in particular to a method for measuring the anchor line degree of a metal pipeline by adopting a technology combining image processing and photoelectric detection. Background The metal pipeline becomes a core pipe in the fields of petrochemical industry, municipal water supply and drainage, gas transportation and the like by virtue of good corrosion resistance, compression resistance and formability, and the anchor grain degree of the inner wall after sand blasting and rust removal is a key index for measuring the quality of anti-corrosion pretreatment. The anchor lines are concave-convex textures formed by impacting the inner wall of the pipeline by abrasive materials in the sand blasting process, the binding force between the anti-corrosion coating and the inner wall of the pipeline is directly determined by the depth and the distribution uniformity of the anchor lines, the coating is easy to fall off and fail in corrosion resistance due to the fact that the anchor lines are too shallow, uneven coating accumulation and stress concentration are easy to occur due to the fact that the anchor lines are too deep, and therefore the anchor lines are used for accurately and efficiently detecting the anchor lines on the inner surface of the metal pipeline and are important pre-working procedures for guaranteeing the subsequent service life of the pipeline. At present, two detection modes mainly exist in the field of metal pipeline anchor grain degree detection, the traditional manual detection method is an early main stream mode of the industry, a section-shaped sample pipe is cut off from the whole pipeline during detection, and a detector observes the inner wall texture of the end part of the sample pipe through naked eyes and then compares the inner wall texture with an anchor grain degree standard sample picture to judge the grade. The method not only causes a large amount of metal pipe loss and increases the production cost, but also has limited sampling range, can only observe the end region of the pipeline, can not reflect the actual condition of the anchor line degree of the whole pipeline, has subjective judgment errors in manual observation, has high randomness, extremely low accuracy and reliability of the detection result, and can not meet the batch detection requirement of the modern industry. In order to solve the defects of manual detection, a related photoelectric detection technology is provided, wherein the photoelectric detection method for the anchor line degree of the inner surface of a pipeline provided by the CN1075203A patent is typical, and the method realizes non-manual detection and pipeline nondestructive detection, but has the following two defects that firstly, the method cannot ensure that measuring light rays precisely irradiate the deepest part of the anchor line, a plurality of groups of depth data are required to be obtained through continuous rotation of equipment, then the maximum value is screened, the detection efficiency is low, secondly, the detection process is indiscriminate point-by-point measurement, anchor line points are not screened, all pits are measured, a large number of invalid measurement operations exist, each point of the equipment needs to be rotated and stopped once, the stop times are frequent, and the detection time is greatly increased. Therefore, the defects of the prior detection technology lead to that the detection of the anchor line degree of the metal pipeline can not always achieve both precision and efficiency, and the rapid development of petrochemical engineering and municipal engineering brings higher requirements on the precision, the high efficiency and the comprehensiveness of the detection of the metal pipeline, so that a new detection method is needed to be developed. Disclosure of Invention The embodiment of the application provides a metal pipeline anchor degree detection method and system based on image analysis, which are used for solving the problems in the prior art. In one aspect, an embodiment of the present application provides a method for detecting an anchor degree of a metal pipe based on image analysis, including: Collecting a panoramic image in the metal pipeline by using a three-dimensional industrial camera, wherein the panoramic image comprises a two-dimensional texture image and three-dimensional point cloud data; preprocessing the panoramic image and strengthening anchor line characteristics to form a strengthened two-dimensional contour image and optimized three-dimensional point cloud data; The method comprises the steps of identifying a potential independent anchor line depression core area in a reinforced two-dimensional profile image by adopting a watershed segmentation algorithm, marking the core area as an initial seed point, generating a pro