Pipeline defect identification system based on target detection algorithm
Through histogram equalization, optical flow method, synthetic data enhancement and multi-scale analysis, combined with front-end preliminary processing and back-end parallel computing, the problems of difficulty in image preprocessing and insufficient real-time performance in pipeline defect recognition are solved, and efficient Accurate defect identification and real-time detection.
Patent Information
- Application Number
- CN202411345476.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-26
- Publication Date
- 2025-01-03
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
The prior art has problems such as difficulty in image preprocessing, low defect recognition accuracy, difficulty in maintaining consistent detection effect and insufficient real-time performance in pipeline defect recognition, especially when processing complex lighting conditions and dynamic video frames, and the model has defects of different scales. insufficient recognition ability.
The histogram equalization algorithm is used to adjust the brightness, the optical flow method tracks the defect location, and the synthetic data enhancement technology simulates samples of different types of defects. The multi-scale analysis strategy ensures the identification of defects in different sizes, and combines the front-end preliminary processing and back-end parallel computing to improve real-time and Resource utilization efficiency.
It significantly improves the accuracy and stability of defect recognition under different lighting conditions, enhances the ability to identify defects of different forms and types, improves the real-time and response speed of the system, and ensures rapid and accurate detection on resource-limited equipment.
Smart Images

Figure CN119251472A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of image processing, and in particular to a pipeline defect recognition system based on a target detection algorithm. Background Art
[0002] In the existing technology, advanced computer vision technology is mainly used to identify possible defects by processing images or videos inside the pipeline, thereby helping maintenance personnel to find problems in a timely manner and ensure the safe operation and efficient maintenance of the pipeline system. The main advantage of this method is that it can automatically detect multiple types of defects, improve detection efficiency, and reduce the workload of manual inspection.
[0003] However, there are still some technical challenges and limitations in practical applications. First, the internal environment of the pipeline is complex and often accompanied by uneven lighting conditions, which makes image preprocessing difficult, thus affecting the extraction of high-quality target features and the accuracy of defect recognition. Second, for dynamic video frames, the rapid movement of the object in the pipeline may cause feature blurring in the image, which reduces the accuracy of edge detection and defect location. In addition, since the actual pipeline defect samples are usually diverse in shape and limited in number, the problem of insufficient learning of small samples often occurs when training the model, making it difficult for the model to fully learn and summarize the features of various defect types. In the detection task of long pipelines, defects at different locations may present different sizes and proportions, which puts higher requirements on the scale invariance of the algorithm. The models in the existing technology often lack sufficient flexibility to cope with these changes, making it difficult to maintain consistent detection results. Finally, existing target detection algorithms often require high computing power, and in practical applications, these algorithms are often deployed on devices with limited computing resources, such as robots and drones. This environment poses a challenge to the real-time performance of the algorithm, making the problem of insufficient detection speed prominent, which seriously affects the timeliness and practicality of defect detection. Summary of the invention
[0004] The purpose of the present invention is to provide a pipeline defect recognition system based on a target detection algorithm to solve the problems that image preprocessing in the prior art becomes difficult, thereby affecting the extraction of high-quality target features, and further affecting the accuracy of defect recognition, the problem that the detection effect is difficult to maintain consistency, and the environment poses a challenge to the real-time performance of the algorithm, resulting in insufficient detection speed, which seriously affects the timeliness and practicality of defect detection.
[0005] To achieve the above object, the present invention provides the following technical solution: a pipeline defect recognition system based on a target detection algorithm, the system comprising:
[0006] An image acquisition module, used to acquire image data inside the pipeline;
[0007] A defect recognition module is connected to the image acquisition module and is used to process the image data based on a pre-trained target detection algorithm to identify defect features therein;
[0008] A result generation module, connected to the defect identification module, for generating defect identification results;
[0009] An output module, connected to the result generation module, for outputting the defect identification result to a terminal device;
[0010] Among them, the defect recognition module processes the image data based on the pre-trained target detection algorithm, and identifies the defect features therein, including adjusting the brightness and uneven lighting areas for each frame of the image data using a histogram equalization algorithm, tracking the position of defects between consecutive frames using the optical flow method during the detection process, and using synthetic data enhancement technology to simulate different types of defect samples to increase the learning data set. According to the detected defect location, a multi-scale analysis strategy is applied to ensure that defects of different distances can be correctly identified and classified. Based on real-time requirements and resource constraints, while performing preliminary image processing on the front end to filter background noise, the model is used for parallel computing in the background.
[0011] Preferably, the image acquisition module acquires the image data inside the pipeline including:
[0012] Placing or installing image acquisition devices including industrial endoscopes, cameras, and machine vision equipment inside the pipeline or along the inspection path of the pipeline;
[0013] According to the lighting conditions, image resolution requirements, and acquisition speed of the pipeline's internal environment, set the parameters of the image acquisition device, including exposure time, image resolution, frame rate, and focal length;
[0014] Start the auxiliary lighting device including LED light source and laser illuminator to supplement the light intensity of the collection area;
[0015] Starting the image acquisition device to acquire image data inside the pipeline continuously or at a set time interval, wherein the image acquisition includes a static image or a dynamic video;
[0016] The collected image data is transmitted to the data processing unit via a wired or wireless network, and the image data is stored in a local storage device or a cloud server in real-time transmission or batch storage.
[0017] Preferably, the step of transmitting the collected image data to the data processing unit via a wired or wireless network, and storing the image data in a local storage device or a cloud server in a real-time transmission or batch storage manner includes:
[0018] Using multi-path TCP transmission protocol and edge computing cache strategy, the transmission delay optimization formula is:
[0019]
[0020] Among them, T total represents the total delay time of data transmission, D represents the amount of data, B represents the transmission bandwidth, and T cache Indicates the cache delay time.
[0021] Preferably, the defect recognition module processes the image data based on a pre-trained target detection algorithm, and identifying defect features therein further comprises:
[0022] In image data processing, the histogram equalization algorithm is used to adjust the brightness of each frame of the image. The specific formula is:
[0023]
[0024] Among them, H(b) represents the pixel value after equalization, L represents the grayscale level of the image, a represents the grayscale value in the original image, b represents the current grayscale value in the cumulative distribution function, and p(a) represents the probability of occurrence of a pixel with grayscale value a.
[0025] Preferably, the defect recognition module processes the image data based on a pre-trained target detection algorithm, and identifying defect features therein further comprises:
[0026] The optical flow method is used to track the position changes of defects in consecutive frame images. The optical flow field is expressed by the following equation:
[0027] I(x,y,t)=I(x+Δx,y+Δy,t+Δt),
[0028] Among them, (x, y) represents the pixel position coordinates, t represents time, I(x, y, t) represents the grayscale value of the image (x, y) at position and time t, Δx represents the horizontal displacement, Δy represents the vertical displacement, and Δt represents the time interval between two consecutive image frames.
[0029] Preferably, the defect recognition module processes the image data based on a pre-trained target detection algorithm, and identifying defect features therein further comprises:
[0030] During the model training process, synthetic data augmentation techniques are used to enrich the dataset. Different types of images in the pipeline are simulated by simulation or computer generation. The generated synthetic images are added to the training set. The enhanced sample dataset is generated by the following formula:
[0031]
[0032] Where D′ represents the enhanced data set, D represents the original data set, n represents the number of data enhancement operations, and Aug(D, θ i ) represents the enhancement operation function, θ i Represents a set of enhancement parameters, and i represents the sequence number of the enhancement operation.
[0033] Preferably, the defect recognition module processes the image data based on a pre-trained target detection algorithm, and identifying defect features therein further comprises:
[0034] The detection model is adapted to defects of different sizes through the multi-scale image pyramid extraction algorithm. The multi-scale image pyramid is expressed as:
[0035] I s (u, w) = I (u, w) × G (σ s ),
[0036] Among them, u represents the horizontal coordinate of the image pixel, w represents the vertical coordinate of the image pixel, σ s represents the scale parameter in the Gaussian blur function, I s (u, w) represents the pixel value of the image at the coordinate (u, w) after multi-scale pyramid processing, I(u, w) represents the pixel value of the original image at the coordinate (u, w), G(σ s ) represents the Gaussian kernel function, and s represents the scale parameters of different levels in the image pyramid.
[0037] Preferably, the defect recognition module processes the image data based on a pre-trained target detection algorithm, and identifying defect features therein further comprises:
[0038] Using front-end preliminary processing and back-end parallel computing, simple background noise filtering operations are performed on the front-end device, and parallel computing or cloud services are used in the background to process complex tasks. Specifically, the parallel processing framework is used to slice the data for parallel processing. The formula for parallel acceleration can be expressed as:
[0039]
[0040] Among them, T parallel is the parallel processing time, T serial is the serial processing time, N is the number of processing units, α is a scaling factor, αT overhead Represents the overhead introduced by parallelization.
[0041] Preferably, the result generation module generates the defect identification result including:
[0042] Through convolutional neural networks, features in image data are extracted;
[0043] The extracted defect features are compared with the pre-trained dataset, and the defects are classified through the model’s classifier;
[0044] For each identified defect, a confidence score is generated to indicate whether the defect identification is accurate;
[0045] The location of the defect is represented in the form of a bounding box, and the coordinates of the defect in the image are output.
[0046] Preferably, the output module outputs the defect identification result to the terminal device, including:
[0047] The results of defect identification are organized in a standardized format, including images, coordinates, classification results, confidence, and size;
[0048] The recognition results will be superimposed on the original image, and the defect area will be displayed through image annotation;
[0049] If it is an online detection system, the recognition results will be transmitted to the remote terminal device in real time through the network;
[0050] Automatically generate pipeline defect detection reports, including the identification results, location and classification of each defect;
[0051] After the defect identification results are output, the terminal device will feedback the data.
[0052] It can be seen from the above technical solution that the present invention has the following beneficial effects:
[0053] The pipeline defect recognition system based on the target detection algorithm obtains the image data inside the pipeline through the image acquisition module. The defect recognition module processes the image data based on the pre-trained target detection algorithm to identify the defect features therein. The result generation module generates the defect recognition result. The output module outputs the defect recognition result to the terminal device, which effectively improves the image quality so that the defect features can still be clearly displayed under different lighting conditions, greatly improves the defect recognition accuracy in poor light or uneven lighting environments, ensures the accurate detection of key defects, improves the stability of defect positioning in the pipeline during mobile shooting, and ensures efficient and accurate recognition in dynamic detection scenarios. It improves the recognition ability of defects of different forms and types, significantly enhances the generalization ability of the model in various application scenarios, and can perform defect detection at different image resolutions to ensure that defects of different distances can be correctly identified. It greatly improves the real-time and response speed of the system, ensuring that defect detection can be completed quickly and accurately on equipment with limited resources. It solves the problems that image preprocessing in the existing technology becomes difficult, thereby affecting the extraction of high-quality target features and further affecting the accuracy of defect recognition, the problem that it is difficult to maintain consistent detection results, and the environment poses a challenge to the real-time performance of the algorithm, resulting in insufficient detection speed, which seriously affects the timeliness and practicality of defect detection. BRIEF DESCRIPTION OF THE DRAWINGS
[0054] Figure 1 This is a schematic diagram of the connection of the system modules of the present invention. DETAILED DESCRIPTION
[0055] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0056] like Figure 1 As shown, a pipeline defect recognition system based on a target detection algorithm, the system comprises:
[0057] Image acquisition module: This module is used to acquire image data inside the pipeline. The image data can be captured by a camera installed inside the pipeline. The image data can be a static picture or a video stream.
[0058] Defect recognition module: connected to the image acquisition module, responsible for processing the acquired image data. Based on the pre-trained target detection algorithm, this module recognizes and classifies the defect features in the image data to detect defects in the pipeline, such as cracks, corrosion, wear, etc.;
[0059] Result generation module: connected with the defect recognition module, generates recognition results corresponding to the recognized defect features. The recognition results include information such as the defect type, location, and severity, which is convenient for subsequent analysis and processing;
[0060] Output module: connected to the result generation module, used to output the generated defect identification results to the terminal device, such as the monitoring system or the maintenance personnel's terminal, for further viewing and processing.
[0061] The image acquisition module obtains image data from inside the pipeline through a camera. The camera can move inside the pipeline to capture real-time images of the internal conditions of the pipeline, or periodically capture images of specific locations. Each frame of the image or video is processed, and the defect features in the image are first detected and analyzed through a target detection algorithm. The algorithm is based on a pre-trained model and can automatically identify common pipeline defects such as cracks, deformation, corrosion, etc. Once a defect is detected, the result generation module will integrate the recognition results and generate a report containing information such as defect type and location. The report content can be customized to facilitate subsequent analysis and maintenance decisions. The output module sends the recognition results to the designated terminal device, such as the central control system, the maintenance personnel's tablet or mobile device, so that the maintenance team can instantly obtain the recognition information and respond. Through automated image acquisition and defect recognition based on target detection algorithms, the time and cost of manual operation are reduced. It is especially suitable for long-distance or difficult-to-access pipeline inspections. The pre-trained target detection algorithm can accurately identify various common defects, reduce the possibility of human misjudgment, and improve the accuracy and robustness of the inspection. It can process image data in real time and generate recognition results. Especially when the pipeline system needs to be continuously monitored, the system can continuously provide real-time data to help detect potential problems early. The automatically generated defect report is not only fast but also highly accurate, and can directly provide a basis for subsequent maintenance decisions.
[0062] The image acquisition module can use different image acquisition devices according to different pipeline types and working environments. For example, thermal imaging devices or infrared cameras can be used instead of ordinary cameras to obtain clear images even in low light or high temperature environments. In the recognition module, different target detection algorithms can be used or combined with deep learning algorithms, such as YOLO, Faster R-CNN, etc., to further improve the speed and accuracy of defect recognition. The output module can combine multiple output methods, such as uploading defect data to cloud storage, or sending it to multiple terminal devices through the network, supporting cross-platform monitoring and remote maintenance, and can be further integrated into a large-scale pipeline monitoring platform, combined with other sensor data (such as pressure and temperature sensor data) to perform multi-dimensional pipeline status analysis, to achieve more comprehensive pipeline maintenance and safety assurance.
[0063] The defect recognition module of the present invention processes the image data based on a pre-trained target detection algorithm to automatically identify defect features in the pipeline. The processing method includes the following steps:
[0064] Histogram equalization: First, the system pre-processes each frame of the image and adjusts the brightness of the image through the histogram equalization algorithm. This step is mainly used to solve the problem of uneven lighting inside the pipeline, enhance the image contrast, and make subsequent defect detection more accurate. Especially in areas with weak light or local shadows, the equalized image can significantly improve the detection effect;
[0065] Optical flow method to track defects: When processing image data of consecutive frames, the system uses the optical flow method to track the position changes of defects between adjacent frames. The optical flow method can identify the position changes of defects in the video stream by analyzing the motion information of the image, ensuring that during the dynamic detection process of the pipeline video, the system can stably and accurately locate and track defects in the pipeline. This plays an important role in the continuity and accuracy of pipeline detection;
[0066] Synthetic data enhancement technology: In order to improve the robustness of the detection algorithm, the system uses synthetic data enhancement technology to generate various types of defect samples and expand the training data set. This technology generates diverse defect samples by simulating different defect shapes, sizes, locations, etc., so that the target detection algorithm can identify more diverse defect types and improve the performance of the model in practical applications;
[0067] Multi-scale analysis strategy: The system uses a multi-scale analysis strategy to deal with defects of different distances and sizes. By analyzing and processing images at different scales, the system can effectively detect defects near and far in the pipeline and accurately classify them according to the size of the defects. This multi-scale strategy ensures that the system can accurately identify defects regardless of their size and location;
[0068] Real-time processing and parallel computing: To meet the real-time requirements of pipeline inspection and ensure efficient operation under limited computing resources, the system performs preliminary image processing at the front end to filter out unnecessary background noise. This step reduces the computational burden of subsequent processing. At the same time, the back-end system uses model parallel computing to accelerate the execution of the inspection algorithm, further improving the system's real-time processing capabilities and ensuring rapid response to defect identification.
[0069] The working principle of the defect recognition module is based on a pre-trained object detection model, which is trained on a large number of pipeline defect image datasets. By combining image preprocessing (such as histogram equalization) and advanced defect tracking techniques (such as optical flow), the system is able to maintain efficient defect detection capabilities when dealing with complex scenes (such as lighting changes, defect motion, etc.). Synthetic data enhancement technology further improves the generalization ability of the model, and the multi-scale analysis strategy ensures that defects of different distances and sizes can be accurately identified. In addition, the system combines real-time processing requirements and uses front-end image processing and background parallel computing to ensure efficient operation. Through histogram equalization and multi-scale analysis strategies, the system can cope with uneven lighting and defects at different distances, improving the accuracy of defect recognition. The front-end image preprocessing combined with the background parallel computing technology effectively improves the real-time processing capability of the system, which is suitable for real-time monitoring and defect detection of long-distance pipelines. The optical flow method is used to track the defect position, allowing the system to continuously track the defect position when processing dynamic video data, ensuring stable detection effects when moving inside the pipeline. Through synthetic data enhancement technology, the system can simulate a variety of defect samples, greatly enriching the training data set and improving the adaptability and robustness of the detection model.
[0070] In addition to using histogram equalization, other image enhancement algorithms such as adaptive histogram equalization or local contrast enhancement can also be used to further optimize the defect recognition effect under complex lighting conditions. The optical flow method can be replaced by a deep tracking algorithm based on a convolutional neural network (CNN), such as target tracking technology using correlation filters, to further improve the defect tracking accuracy in dynamic video streams. In addition to synthetic data enhancement, it can also be combined with actual collected defect data for training to improve the accuracy of the model. GAN (generative adversarial network) can also be used to generate realistic defect images and expand the data set. In terms of parallel processing, the system's processing capabilities can be enhanced through distributed computing or cloud computing to meet the real-time processing needs of large-scale or high-resolution image data.
[0071] The image acquisition module is used to acquire image data inside the pipeline, which is achieved by placing or installing an image acquisition device (including an industrial endoscope, a camera, and a machine vision device) inside the pipeline or on the detection path along the pipeline. According to the lighting conditions, image resolution requirements, and acquisition speed of the internal environment of the pipeline, the parameters of the image acquisition device (including exposure time, image resolution, frame rate, and focal length) will be appropriately set to ensure the acquisition of clear and high-quality image data. In order to supplement the insufficient lighting inside the pipeline, an auxiliary lighting device including an LED light source and a laser illuminator is started to provide sufficient light intensity for the image acquisition area. After that, the image acquisition device continuously or at a set time interval acquires static images or dynamic video data inside the pipeline. These image data are transmitted to the data processing unit via a wired or wireless network. The transmission mode can be real-time transmission or batch storage. The image data is stored in a local storage device or a cloud server to ensure the security and accessibility of the data.
[0072] The core of the image acquisition module is to set up appropriate image acquisition equipment and parameter configuration according to the specific inspection requirements of the pipeline. First, by optimizing the exposure time, resolution, frame rate and other parameters of the equipment, it is ensured that clear image data can be obtained under different pipeline conditions. The auxiliary lighting device supplements the ambient light through LED and laser lighting, so that the image acquisition device can work efficiently inside the pipeline with poor light. After the data acquisition is completed, the system transmits the data to the data processing unit through the network. The storage method is flexible. You can choose real-time transmission to ensure fast feedback or batch storage for later analysis. The parameters of the image acquisition module are adjustable, so that the system can adapt to different pipeline environments, such as low light or high resolution scenes, to ensure image acquisition quality. The system supports static image and dynamic video acquisition modes to meet the needs of different inspection tasks, and the acquisition efficiency can be optimized by setting the time interval. The auxiliary lighting provided by the LED light source and laser illuminator can effectively solve the problem of insufficient lighting inside the pipeline and ensure image clarity. It supports real-time transmission and batch storage to ensure the flexibility of data transmission. At the same time, it supports data storage locally or upload to the cloud to meet different storage requirements.
[0073] In addition to industrial endoscopes, cameras and machine vision equipment, thermal imaging cameras or ultrasonic imaging equipment can also be used to meet special inspection needs, such as pipes with changing temperatures or materials. Depending on the actual environment, light sources of different powers or types can be selected, such as infrared light sources, to enhance imaging capabilities in complex environments. Depending on the network conditions of the pipeline inspection environment, the transmission protocol can be improved or the network buffering strategy can be added to deal with possible network delays or data packet loss problems, further improving transmission efficiency.
[0074] The collected image data is transmitted to the data processing unit via a wired or wireless network, and the image data is stored in a local storage device or a cloud server in real-time transmission or batch storage, including:
[0075] Using multi-path TCP transmission protocol and edge computing cache strategy, the transmission delay optimization formula is:
[0076]
[0077] Among them, T total represents the total delay time of data transmission, D represents the amount of data, B represents the transmission bandwidth, and T cache Indicates the cache delay time.
[0078] This implementation improves the reliability and efficiency of image data transmission by using a multipath TCP protocol. Data can be transmitted in parallel through multiple transmission paths, reducing the bandwidth limitation problem of single path transmission. At the same time, through the edge computing cache strategy, the system can cache image data at the edge node close to the data acquisition device, reducing the delay time of cloud storage. The transmission delay optimization formula clarifies the impact of data volume, transmission bandwidth and cache delay on the total transmission time, allowing the system to optimize the configuration of these parameters in practical applications to further improve the overall performance. The multipath TCP transmission protocol disperses the network pressure, allowing image data to be transmitted to the data processing unit faster, reducing the total delay of data transmission. The edge cache reduces the delay problem caused by long-distance transmission and improves the real-time processing capability of the system. The transmission mode of the system can be automatically adjusted according to the network conditions to ensure the stability and continuity of data transmission.
[0079] In addition to the TCP protocol, the QUIC protocol can be used to further reduce transmission delays, especially in unstable network environments. The image data can be compressed before transmission to reduce the amount of data and further optimize the transmission speed and delay time.
[0080] The defect recognition module processes image data based on a pre-trained object detection algorithm, and identifies defect features including:
[0081] In image data processing, the histogram equalization algorithm is used to adjust the brightness of each frame of the image. The specific formula is:
[0082]
[0083] Among them, H(b) represents the pixel value after equalization, L represents the grayscale level of the image, a represents the grayscale value in the original image, b represents the current grayscale value in the cumulative distribution function, and p(a) represents the probability of occurrence of a pixel with grayscale value a.
[0084] When processing the internal image of the pipeline, the defect recognition module first uses the histogram equalization method to balance the brightness of the image to deal with the problem of uneven lighting inside the pipeline. The algorithm adjusts the pixel distribution of the image so that the details of the original dark area are enhanced and the bright area is not overexposed, thereby improving the visibility of the defect features in the image. The core of histogram equalization is to redistribute the pixel values in the image so that the number of pixels at each gray level is more uniform. Through this treatment, the defect area in the pipeline can be more prominent, improving the detection accuracy of the subsequent algorithm. Through histogram equalization, the contrast of the image can be significantly improved, making the defects inside the pipeline more obvious, thereby improving the accuracy of defect detection. Histogram equalization is particularly effective for scenes with insufficient light. It can evenly process areas that are too dark or too bright, and improve the robustness of detection. The algorithm can enhance the details in the image, especially in defect detection, which helps to more accurately identify and classify defect features.
[0085] In addition to conventional histogram equalization, adaptive histogram equalization (CLAHE) can also be used to further improve the image processing effect in complex lighting environments through local equalization. Before equalization, Gaussian filtering or median filtering can be introduced to reduce the interference of noise on image brightness processing and ensure a more accurate image equalization effect.
[0086] The defect recognition module processes image data based on a pre-trained object detection algorithm, and identifies defect features including:
[0087] The optical flow method is used to track the position changes of defects in consecutive frame images. The optical flow field is expressed by the following equation:
[0088] I(x,y,t)=I(x+Δx,y+Δy,t+Δt),
[0089] Among them, (x, y) represents the pixel position coordinates, t represents time, I(x, y, t) represents the grayscale value of the image (x, y) at position and time t, Δx represents the horizontal displacement, Δy represents the vertical displacement, and Δt represents the time interval between two consecutive image frames.
[0090] The optical flow method is a tracking algorithm based on image motion information. When detecting pipeline defects, the system processes continuous image frames and tracks the movement of defects in different frame images by calculating the displacement vector in the optical flow field. This method enables the system to accurately track the position changes of defects by analyzing the pixel movement between adjacent frames. Even when the defect moves or the pipeline detection equipment moves, it can also maintain continuous tracking of defects. During the processing of the optical flow method, the system will calculate the change of image grayscale and generate motion vectors. Based on these vectors, the system can update the position information of defects in real time, providing data support for subsequent defect classification and position labeling. The optical flow method enables the system to continuously track defects when processing dynamic video data, which is suitable for real-time detection in pipeline monitoring. This method can handle the changes in the position of defects in the image caused by the movement of the detection equipment or the flow of liquid inside the pipeline, ensuring that the defects will not be lost during the detection process. The optical flow method can accurately calculate the displacement of defects, providing accurate data support for further defect classification and position labeling.
[0091] The optical flow method can be replaced by a target tracking algorithm based on deep learning (such as Siamese network or correlation filter method) to improve the tracking accuracy and robustness in complex environments. The sparse optical flow method can be used to track only a small number of significant feature points in the image, reducing the computational complexity, which is suitable for scenarios with limited computing resources.
[0092] The defect recognition module processes image data based on a pre-trained object detection algorithm, and identifies defect features including:
[0093] During the model training process, synthetic data augmentation techniques are used to enrich the dataset. Different types of images in the pipeline are simulated by simulation or computer generation. The generated synthetic images are added to the training set. The enhanced sample dataset is generated by the following formula:
[0094]
[0095] Where D′ represents the enhanced data set, D represents the original data set, n represents the number of data enhancement operations, and Aug(D, θ i ) represents the enhancement operation function, θ i Represents a set of enhancement parameters, and i represents the sequence number of the enhancement operation.
[0096] During the model training phase, the system expands the training set through synthetic data enhancement technology, especially for some rare or difficult-to-obtain defect samples, and simulates various possible defect scenarios through simulation or computer generation. The synthetic images generated by this data enhancement technology are added to the training set, so that the detection model can be trained under richer samples, thereby improving the generalization ability of the model in practical applications. Data enhancement operations include random rotation, translation, scaling, noise addition, etc. These operations change the appearance or geometric properties of the image to make the model more capable of identifying defects, especially when facing complex scenes or new types of defects. Synthetic data enhancement technology can generate a large amount of different types of defect data, so that the model can still maintain a high recognition accuracy when facing complex and changing defect scenes. By generating synthetic data, the dependence on actual pipeline defect data is reduced, and the cost of collecting large-scale defect data is reduced. Through various enhancement operations, the model can be exposed to more diverse samples during training, which improves the robustness and adaptability of the model.
[0097] GAN can be used to generate more realistic pipeline defect images, further enrich the training set, improve model performance, and adjust enhancement parameters such as the enhanced rotation angle and scaling ratio to make the enhanced data more consistent with the distribution of actual pipeline defects.
[0098] The defect recognition module processes image data based on a pre-trained object detection algorithm, and identifies defect features including:
[0099] The detection model is adapted to defects of different sizes through the multi-scale image pyramid extraction algorithm. The multi-scale image pyramid is expressed as:
[0100] I s (u, w) = I (u, w) × G (σ s ),
[0101] Among them, u represents the horizontal coordinate of the image pixel, w represents the vertical coordinate of the image pixel, σ s represents the scale parameter in the Gaussian blur function, I s (u, w) represents the pixel value of the image at the coordinate (u, w) after multi-scale pyramid processing, I(u, w) represents the pixel value of the original image at the coordinate (u, w), G(σ s ) represents the Gaussian kernel function, and s represents the scale parameters of different levels in the image pyramid.
[0102] During pipeline defect identification, the size and distance of defects may vary significantly. Therefore, in order to ensure that defects of different sizes can be detected, the system uses a multi-scale image pyramid algorithm. The algorithm reduces the image size layer by layer and creates a series of image versions with different resolutions, enabling the system to perform defect analysis at multiple scales. Each scale of the image is smoothed by a Gaussian blur function to reduce the impact of noise, and then defect detection is performed at different resolutions to ensure that the defect can be accurately identified regardless of its position or size in the original image. This multi-scale strategy is particularly effective in detecting defects at long distances or small in size. The multi-scale pyramid algorithm is able to handle defects of different sizes, ensuring that the system can accurately detect defects regardless of whether they are far or near, or how the size of the defects varies. By analyzing at multiple scales, the system can detect small defects that may be missed at a single scale, improving the comprehensiveness of the overall detection. The Gaussian blur function helps reduce background noise in the image, further improving the accuracy of defect identification.
[0103] In addition to using the traditional multi-scale pyramid algorithm, the detection efficiency can be further improved by optimizing the design of the scale space and selecting a scale level that is more suitable for pipeline defect detection. The multi-scale feature extraction capability of the convolutional neural network can be combined to extract features at different network layers to enhance the recognition ability of defects of different scales.
[0104] The defect recognition module processes image data based on a pre-trained object detection algorithm, and identifies defect features including:
[0105] Using front-end preliminary processing and back-end parallel computing, simple background noise filtering operations are performed on the front-end device, and parallel computing or cloud services are used in the background to process complex tasks. Specifically, the parallel processing framework is used to slice the data for parallel processing. The formula for parallel acceleration can be expressed as:
[0106]
[0107] Among them, T parallel is the parallel processing time, T serial is the serial processing time, N is the number of processing units, α is a scaling factor, αT overhead Represents the overhead introduced by parallelization.
[0108] During the defect recognition process, the system first performs preliminary image processing on the front-end device, mainly to filter out background noise and low-frequency interference, reducing the burden of subsequent processing. After preliminary processing, the system transmits the image data to the backend server or cloud for parallel processing. By dividing the image data into several data fragments, the system can use multi-core processors or distributed computing nodes to perform complex computing tasks in parallel, such as defect detection, classification, and location annotation. Parallel computing significantly improves the processing speed of the system, especially when processing high-resolution pipeline image data. The parallel acceleration formula explains the impact of the number of processing units on the acceleration effect, while taking into account the additional overhead that may be introduced during the parallelization process.
[0109] By assigning complex tasks to multiple processing units for parallel execution, the processing speed of defect identification is greatly accelerated, especially in resource-constrained environments, which can improve overall efficiency. The preliminary processing at the front end reduces the computing pressure of the background by filtering background noise, effectively reduces the amount of data transmitted, and optimizes the data transmission and processing chain. The parallel computing framework enables the system to quickly process large-scale image data, meet the requirements of real-time defect detection, and is suitable for online monitoring scenarios.
[0110] It can be further combined with edge computing to complete some complex computing tasks directly at edge nodes close to the pipeline, reducing data transmission delays and improving processing efficiency. Parallel computing can also be expanded to cloud-based distributed computing, which can handle large-scale pipeline inspection tasks by mobilizing more cloud computing resources. It is suitable for situations that require ultra-large-scale computing.
[0111] The specific process of the result generation module generating defect identification results is as follows:
[0112] Convolutional neural network feature extraction: The system first extracts features from the input image data using a pre-trained convolutional neural network (CNN) to identify defect features in the image;
[0113] Defect classification and comparison: The extracted defect features are compared with the pre-trained data set, and the system classifies the defects based on the classifier. The classification results include the type of defect (such as cracks, corrosion, wear, etc.);
[0114] Confidence score: For each identified defect, the system generates a confidence score, which indicates the accuracy of the defect identification result. The confidence score can be used for subsequent result screening and decision-making;
[0115] Position annotation: The position of the defect is annotated in the image in the form of a bounding box, and the coordinate information of the bounding box will be output to help users locate the defect.
[0116] The result generation module relies on convolutional neural networks to extract features from image data. CNN uses multi-layer convolution operations to gradually extract different levels of features in the image, including edges, textures, and higher-order semantic information. After that, the extracted features are compared with the training data, and the defect type is predicted through the classifier. The confidence score represents the system's confidence in the defect classification results. The higher the score, the higher the recognition accuracy. The bounding box is used to mark the location of the defect, which is convenient for users to quickly locate and process the defect. Through CNN for feature extraction and classification, the system can quickly identify and classify different types of defects in the pipeline. Through confidence scoring, the system can help users judge the accuracy of the recognition results and improve the reliability of the overall decision. The defect location is marked with a bounding box to intuitively display the location of the defect, which is convenient for users to view and subsequently process.
[0117] A deeper CNN model (such as ResNet, Effi cientNet, etc.) can be used to improve the accuracy of feature extraction and adapt to more complex defect types. The non-maximum suppression (NMS) algorithm can be combined to screen multiple bounding boxes to ensure that each defect has only one valid bounding box, thereby improving the accuracy of the results.
[0118] The output module outputs the defect identification results to the terminal device in a standardized format, which includes the following steps:
[0119] Standardized result organization: The identified defect results are organized in a standardized format, including images, coordinates, classification results, confidence scores, defect dimensions, etc. These data are uniformly formatted for easy subsequent analysis and processing;
[0120] Image annotation display: The recognition results will be superimposed on the original image. The system will display the defect area through image annotation and visualize the specific location of the defect;
[0121] Real-time transmission of results: If it is an online detection system, the identification results will be transmitted to the remote terminal device in real time through the network, so that maintenance personnel can respond in time;
[0122] Automatic report generation: The system will automatically generate a pipeline defect detection report, which includes the identification results, location and classification of each defect, facilitating subsequent analysis and maintenance work;
[0123] Terminal device data feedback: After the defect recognition results are output to the terminal device, the system also supports the terminal device to provide feedback on the recognition results. The terminal device operator can verify, adjust or make comments on the recognition results. After the system receives the feedback information, it can be used to further optimize the model or adjust the detection strategy.
[0124] The output module is responsible for standardizing the defect identification results and visually displaying them on the terminal device. First, the identified defect information (including location, classification, confidence and size, etc.) is standardized to generate an output result in a unified format. This result is not only convenient for subsequent analysis and processing, but can also be displayed to the operator in an intuitive way by superimposing it on the original image. For online detection, the system can quickly send the defect identification results to the remote terminal through real-time network transmission, so that the operator can obtain the defect information of the pipeline at the first time. At the same time, the report automatically generated by the system integrates all the detection data to provide complete data support for maintenance and decision-making. In addition, the terminal device can provide feedback function, and the operator can further verify the identification results or make modification suggestions. The feedback results will be reflected in the system to help the system optimize the subsequent detection process. The standardized format generated by the system enables the defect detection results to be seamlessly connected to other systems or processes, simplifying data management and subsequent analysis. The real-time result transmission function provided by the online detection system ensures that the maintenance team can quickly respond to potential problems in the pipeline and reduce the time delay of accidents. It automatically generates reports containing all key detection information, improves the efficiency of data processing and report generation, and provides strong support for subsequent maintenance decisions. Operators can directly provide feedback on the results of system identification and optimize the defect recognition model, so that the detection system can gradually improve its accuracy and reliability with use.
[0125] The output module can provide customized report formats. Users can adjust the data display format in the report according to specific needs, increase or reduce the output of specific information, and adapt to the requirements of different application scenarios. The output module can also support a variety of different terminal devices, including mobile devices, PCs or industrial control panels, to ensure convenience and operability in different usage environments. It can automatically feed back the operator's feedback information to the defect recognition model, use the feedback data to further optimize the accuracy and robustness of the model, and gradually improve the system's recognition capabilities.
[0126] The present invention provides an efficient and accurate pipeline defect recognition system by combining a variety of advanced image processing and target detection technologies. The system adopts a multi-module architecture, including image acquisition, defect recognition, result generation and output modules. Each module plays an important role in the pipeline detection process. In particular, through optical flow method, multi-scale analysis and synthetic data enhancement and other technologies, it ensures that the system can perform efficient and robust defect detection in different pipeline environments. The system combines parallel computing and front-end preliminary processing to meet the needs of real-time detection and efficient processing. The standardized results of the final output are not only visualized, but also automatically generate reports, and support feedback interaction of terminal devices, further improving the applicability and flexibility of the system. Through these technical innovations, the pipeline defect recognition system of the present invention can significantly improve the efficiency and accuracy of pipeline maintenance, reduce labor costs and misjudgment rate, especially in pipeline monitoring over long distances and in complex environments. It has broad application prospects.
[0127] Although embodiments of the present invention have been shown and described, it will be appreciated by those skilled in the art that various changes, modifications, substitutions and variations may be made to the embodiments without departing from the principles and spirit of the present invention, and that the scope of the present invention is defined by the appended claims and their equivalents.
Claims
1. A pipeline defect recognition system based on target detection algorithm, characterized in that: The system comprises: An image acquisition module, used to acquire image data inside the pipeline; A defect recognition module is connected to the image acquisition module and is used to process the image data based on a pre-trained target detection algorithm to identify defect features therein; A result generation module, connected to the defect identification module, for generating defect identification results; An output module, connected to the result generation module, for outputting the defect identification result to a terminal device; Among them, the defect recognition module processes the image data based on the pre-trained target detection algorithm, and identifies the defect features therein, including adjusting the brightness and uneven lighting areas for each frame of the image data using a histogram equalization algorithm, tracking the position of defects between consecutive frames using the optical flow method during the detection process, and using synthetic data enhancement technology to simulate different types of defect samples to increase the learning data set. According to the detected defect location, a multi-scale analysis strategy is applied to ensure that defects of different distances can be correctly identified and classified. Based on real-time requirements and resource constraints, while performing preliminary image processing on the front end to filter background noise, the model is used for parallel computing in the background.
2. According to claim 1, a pipeline defect recognition system based on target detection algorithm is characterized in that: The image acquisition module acquires the image data inside the pipeline including: Placing or installing image acquisition devices including industrial endoscopes, cameras, and machine vision equipment inside the pipeline or along the inspection path of the pipeline; According to the lighting conditions, image resolution requirements, and acquisition speed of the pipeline's internal environment, set the parameters of the image acquisition device, including exposure time, image resolution, frame rate, and focal length; Start the auxiliary lighting device including LED light source and laser illuminator to supplement the light intensity of the collection area; Starting the image acquisition device to acquire image data inside the pipeline continuously or at a set time interval, wherein the image acquisition includes a static image or a dynamic video; The collected image data is transmitted to the data processing unit via a wired or wireless network, and the image data is stored in a local storage device or a cloud server in real-time transmission or batch storage.
3. According to claim 2, a pipeline defect recognition system based on target detection algorithm is characterized in that: The method of transmitting the collected image data to the data processing unit via a wired or wireless network and storing the image data in a local storage device or a cloud server in a real-time transmission or batch storage manner includes: Using multi-path TCP transmission protocol and edge computing cache strategy, the transmission delay optimization formula is: Among them, T total represents the total delay time of data transmission, D represents the amount of data, B represents the transmission bandwidth, and T cache Indicates the cache delay time.
4. According to claim 1, a pipeline defect recognition system based on target detection algorithm is characterized in that: The defect recognition module processes the image data based on a pre-trained target detection algorithm, and the defect features identified therein also include: In image data processing, the histogram equalization algorithm is used to adjust the brightness of each frame of the image. The specific formula is: Among them, H(b) represents the pixel value after equalization, L represents the grayscale level of the image, a represents the grayscale value in the original image, b represents the current grayscale value in the cumulative distribution function, and p(a) represents the probability of occurrence of a pixel with grayscale value a.
5. According to claim 1, a pipeline defect recognition system based on target detection algorithm is characterized in that: The defect recognition module processes the image data based on a pre-trained target detection algorithm, and the defect features identified therein also include: The optical flow method is used to track the position changes of defects in consecutive frame images. The optical flow field is expressed by the following equation: I(x,y,t)=I(x+Δx,y+Δy,t+Δt), Among them, (x, y) represents the pixel position coordinates, t represents time, I(x, y, t) represents the grayscale value of the image (x, y) at position and time t, Δx represents the horizontal displacement, Δy represents the vertical displacement, and Δt represents the time interval between two consecutive image frames.
6. The pipeline defect recognition system based on target detection algorithm according to claim 1 is characterized in that: The defect recognition module processes the image data based on a pre-trained target detection algorithm, and the defect features identified therein also include: During the model training process, synthetic data augmentation techniques are used to enrich the dataset. Different types of images in the pipeline are simulated by simulation or computer generation. The generated synthetic images are added to the training set. The enhanced sample dataset is generated by the following formula: Among them, D′ represents the enhanced data set, D represents the original data set, n represents the number of data enhancement operations, AUg(D, θi) represents the enhancement operation function, θi represents the enhancement parameter set, and i represents the sequence number of the enhancement operation.
7. The pipeline defect recognition system based on target detection algorithm according to claim 1 is characterized in that: The defect recognition module processes the image data based on a pre-trained target detection algorithm, and the defect features identified therein also include: The detection model is adapted to defects of different sizes through the multi-scale image pyramid extraction algorithm. The multi-scale image pyramid is expressed as: AND s (u,w)=I(u,w)×G(σ s ), Among them, u represents the horizontal coordinate of the image pixel, w represents the vertical coordinate of the image pixel, σ s represents the scale parameter in the Gaussian blur function, I s (u, w) represents the pixel value of the image at the coordinate (u, w) after multi-scale pyramid processing, I(u, w) represents the pixel value of the original image at the coordinate (u, w), G(σ s ) represents the Gaussian kernel function, and s represents the scale parameters of different levels in the image pyramid.
8. The pipeline defect recognition system based on target detection algorithm according to claim 1 is characterized in that: The defect recognition module processes the image data based on a pre-trained target detection algorithm, and the defect features identified therein also include: Using front-end preliminary processing and back-end parallel computing, simple background noise filtering operations are performed on the front-end device, and parallel computing or cloud services are used in the background to process complex tasks. Specifically, the parallel processing framework is used to slice the data for parallel processing. The formula for parallel acceleration can be expressed as: Among them, T parallel is the parallel processing time, T serial is the serial processing time, N is the number of processing units, α is a scaling factor, αT overhead Represents the overhead introduced by parallelization.
9. The pipeline defect recognition system based on target detection algorithm according to claim 1 is characterized in that: The defect recognition result generated by the result generation module includes: Through convolutional neural networks, features in image data are extracted; The extracted defect features are compared with the pre-trained dataset, and the defects are classified through the model’s classifier; For each identified defect, a confidence score is generated to indicate whether the defect identification is accurate; The location of the defect is represented in the form of a bounding box, and the coordinates of the defect in the image are output.
10. The pipeline defect recognition system based on target detection algorithm according to claim 1 is characterized in that: The output module outputs the defect identification result to the terminal device, including: The results of defect identification are organized in a standardized format, including images, coordinates, classification results, confidence, and size; The recognition results will be superimposed on the original image, and the defect area will be displayed through image annotation; If it is an online detection system, the recognition results will be transmitted to the remote terminal device in real time through the network; Automatically generate pipeline defect detection reports, including the identification results, location and classification of each defect; After the defect identification results are output, the terminal device will feedback the data.
Citation Information
Patent Citations
Monocrystalline silicon solar wafer defect detection method based on optical flow method and confidence coefficient method
CN112381759A
Detection method for identifying small target
CN114049572A
Flaw target detection method based on yov5
CN114998704A
Cage stranding broken wire defect identification method and system based on artificial intelligence
CN118279253A
Pipeline defect detection system and method
CN118628473A
Cited By
Pipeline defect intelligent identification system and method based on pipe network microorganisms
CN119555891A
Defect detection system, method and device based on artificial intelligence image processing
CN119579602A
Intelligent petroleum oil heating pipeline detection system and method
CN120107267A
AI identification method and system for pipeline defects, medium and product
CN120912943A
An ai identification method, system, medium and product for pipeline defects
CN120912943B
