Intelligent pipeline defect assessment method based on multi-modal large model
By using a multimodal large model to intelligently assess defects in urban drainage pipe networks, the problems of low efficiency, poor consistency, and insufficient accuracy in existing technologies have been solved. This enables efficient and accurate defect identification and assessment, supporting health monitoring and maintenance decisions for pipe networks.
Patent Information
- Application Number
- CN202511503361.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-21
- Publication Date
- 2026-01-30
AI Technical Summary
In existing technologies, the detection efficiency of urban drainage pipe networks is low, the results are inconsistent, the accuracy of intelligent assessment is insufficient, there is a lack of in-depth analysis and comprehensive assessment, the assessment dimensions are single, and it is difficult to accurately identify defects in complex backgrounds and assess their severity.
A pipeline defect intelligent assessment method based on a multimodal large model is adopted. By processing pipeline inspection videos, defects are identified and located. Deep semantic understanding is performed by combining a multimodal large language model. Standardized prompt words are used to intelligently score and comprehensively evaluate defects, and decision suggestions are generated.
It improves the accuracy and consistency of defect identification, reduces human subjective bias, significantly shortens the assessment cycle through automated processes, provides accurate defect location and maintenance suggestions, and supports dynamic monitoring and optimized maintenance of pipeline health status.
Smart Images

Figure CN121437403A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of urban drainage pipe network detection and evaluation technology, and in particular to an intelligent evaluation method for pipe defects based on a multimodal large model. Background Technology
[0002] As the "blood vessels" and "lifeline" of a city, urban drainage pipe networks bear the heavy responsibility of urban sewage and flood control. Maintaining urban drainage pipe network facilities, such as repair, upkeep, and renovation, requires first identifying and assessing defects in the pipe network.
[0003] Traditional CCTV video inspection mainly relies on manual viewing, interpretation, and recording, which is labor-intensive and inefficient. Different inspectors have different experience, condition, and sense of responsibility, resulting in inconsistent judgment standards for defects and making it difficult to guarantee the objectivity and consistency of the assessment results. Long hours of manual interpretation can easily lead to visual fatigue, resulting in missed defects or misjudgments, affecting the accuracy of the assessment. A large amount of video data is often only used for the current inspection and cannot be deeply mined and analyzed, making it difficult to form a dynamic and comprehensive understanding of the pipeline network condition.
[0004] Currently, many automated / intelligent inspection technologies and solutions on the market still have many shortcomings. Defect identification based on traditional image processing or simple machine learning models needs to improve its accuracy in situations with complex backgrounds, uneven lighting, and poor video quality. Even when defects can be identified, many systems have relatively simple models for assessing the severity of defects, mainly relying on the type and number of defects. The assessment dimensions are singular, lacking a comprehensive assessment of the spatial location, size, and impact on pipeline structure and function of the defects.
[0005] Traditional assessment methods lack deep semantic understanding, making it difficult to make comprehensive judgments and assess potential risks by combining multiple attributes of defects (such as whether the location is at an interface, whether the crack is penetrating, whether the deformation causes misalignment, etc.) like experts. Existing assessment methods still have a low level of intelligence in terms of standardized assessment scoring and automatic generation of grading and maintenance recommendations based on assessment results. Summary of the Invention
[0006] The technical problem to be solved by this invention is to provide a pipeline defect intelligent assessment method based on a multimodal large model, in order to address the problems of low efficiency and poor consistency of manual inspection in the existing technologies mentioned above, as well as the insufficient accuracy and single evaluation dimension of existing intelligent technologies, and the lack of in-depth analysis and intelligent decision-making.
[0007] The technical solution adopted by this invention to solve its technical problem is: a method for intelligent assessment of pipeline defects based on a multimodal large model, comprising the following steps: S1. Process the pipeline inspection video to identify and locate pipeline defects, and obtain a defect dataset containing defect category and location information; S2. Divide the pipeline into multiple continuous pipe segments, count the number and distribution of various defects in each segment, and calculate the statistical score of each segment according to preset rules. ; S3. Combine the defect image and / or text description corresponding to the defect identified in step S1 with preset standardized prompt words, and input them into the multimodal large language model; the multimodal large language model analyzes the severity of the defect based on the prompt words and outputs an intelligent score for each defect. Intelligent scoring of all defects within a pipe section By combining the results, an intelligent score for this pipe section is obtained. ; S4. Statistical scoring for each pipe segment. With intelligent scoring A weighted fusion is performed to obtain the comprehensive score for this pipe section. Based on the overall score The health status of pipe segments and / or the entire pipeline is classified and decision recommendations are generated.
[0008] According to one embodiment of the present invention, the standardized prompt word in step S3 includes instructions for guiding the multimodal large language model to perform at least one of the following tasks: Assess the extent to which the defects affect the stability of the pipeline structure; Assess the potential impact of the defect size on pipeline function; The overall severity of the defects is quantitatively scored; Explain the main criteria for scoring.
[0009] According to one embodiment of the present invention, step S3 involves intelligent scoring of all defects within a pipe segment. By combining the results, an intelligent score for this pipe section is obtained. The calculation formula is as follows: , Where N is the total number of defects identified within the pipe section. This represents the intelligent score for the i-th defect within the pipe section; or .
[0010] According to one embodiment of the present invention, the calculation formula for weighted fusion in step S4 is as follows: , in, and These are the weighting coefficients, and + =1.
[0011] According to one embodiment of the present invention, the health status in step S4 is divided into three levels: Level 1 status: ≥ This indicates that there are no defects or that the defects are minor. Level 2 status: ≤ < This indicates that there are defects that require attention; Level 3 status: < This indicates a serious defect; in, and For a preset threshold, and > .
[0012] According to one embodiment of the present invention, for a pipe segment whose health status is assessed as Level 3, a maintenance suggestion is output, which includes the starting position, ending position, and maintenance length of the pipe segment to be maintained.
[0013] According to an embodiment of the present invention, the processing of the pipeline inspection video in step S1 specifically includes the following steps: S101. Extract image frames from the pipeline inspection video, and perform distortion correction, image enhancement and data cleaning operations on the image frames in sequence to obtain a high-quality image set to be analyzed. S102. Input the set of images to be analyzed into a pre-trained instance segmentation model to obtain the model inference result for each image; the model inference result includes the category label, confidence score, bounding box coordinates and pixel-level binary mask for each detected defect instance; S103. Filter and smooth the model inference results, and calculate the geometric features of each defect instance based on the processed pixel-level binary mask.
[0014] According to one embodiment of the present invention, the image enhancement operation in step S101 employs the following algorithms sequentially: Histogram equalization: used to enhance image contrast; Adaptive contrast enhancement: Used for localized adjustment of bright and dark areas in an image; Adaptive texture enhancement filtering: used for image denoising and enhancing defect texture features; local region variance is used to address texture complexity. To represent, the calculation formula is: , Where W is a local window centered at (x, y); The number of pixels in window W; Let (i, j) be the grayscale value of pixel (i, j) within window W; It is the local mean of all pixels within window W; To sum all pixels within window W; Based on local regional variance Construct a texture weight adjustment factor h, calculated using the following formula: , in, , and The standard deviation parameter; For spatial distance, a Gaussian function is used to represent it. The formula for calculating the two-dimensional Gaussian function kernel is as follows: , Where (x, y) are the coordinates of a point in the kernel. The standard deviation parameter; The formula for calculating the overall weight w is: , Right now .
[0015] If the local variance It's very large (with complex textures), so A smaller value results in a lower overall weight w, leading to better preservation of edges and details. Conversely, a larger value in a flat region... Small, factor A value close to 1 indicates a stronger filtering effect.
[0016] According to an embodiment of the present invention, the pre-trained instance segmentation model in step S102 is a YOLACT model, which is trained through the following steps: S102a. Constructing the training dataset: Obtain images of the inside of the pipeline, use annotation tools to perform pixel-level contour annotations on various defect instances in the images, and generate annotation files containing bounding box coordinates, category labels, and instance masks; divide the annotated dataset into training set, validation set, and test set according to the proportions. S102b, Model Training: The training set and validation set are input into the YOLACT network for training; the overall loss function L of the YOLACT network... total Classification loss L cls Bounding box regression loss L box and mask loss L mask The calculation formula is based on a weighted average of three parts: , Where α, β, and γ are weight coefficients; classification loss L cls Cross-entropy loss function is used; bounding box regression loss L box Smooth L1 loss function is used; mask loss L mask A pixel-level binary cross-entropy loss function is used.
[0017] S102c, Model Testing and Selection: Evaluate the trained model on the test set, using the mean accuracy (mAP) based on the mask as the evaluation metric, and select the model with an mAP value greater than 95% as the final defect detection model.
[0018] According to an embodiment of the present invention, the post-processing operation in step S103 includes: Set a confidence threshold to filter out defect detection results with a confidence score below 0.9; The pixel-level binary mask of the defect is smoothed by using opening and closing operations in morphological operations. The geometric features of each defect instance are calculated based on the processed pixel-level binary mask. These features include the defect area A, the defect perimeter P, and shape parameters. The defect area A is obtained by counting the total number of pixels with a value of 1 in the binary mask. The defect perimeter P is obtained by calculating the total number of pixels on the outline of the binary mask. The shape parameters include roundness C and aspect ratio R. Circularity C describes how close a defect shape is to a circle, and its calculation formula is as follows: ; The length-width factor R represents the dimensional characteristics of a defect in two mutually perpendicular directions. It is used to describe non-circular or asymmetrical shapes. The minimum bounding rectangle of the defect region has a length of L and a width of B. The formula for calculating the length-width factor R is: ; The texture feature T of defect region A is represented as: ; Statistical scoring based on a combination of geometric and texture features w s The calculation formula is: , in, , and These are the weighting coefficients. This represents the maximum defect area in a single segment. This indicates that normalization is being performed.
[0019] The beneficial effects of this invention are: (1) The introduction of multimodal large model can simulate the cognitive process of experts, perform deep semantic understanding and comprehensive evaluation of defective images, and reduce human subjective bias; standardized prompt words ensure the consistency of LLM evaluation standards, improve the reproducibility of results, and combine statistical quantitative scoring and LLM intelligent scoring to make the evaluation dimensions richer and the results more comprehensive and accurate. (2) The automated defect identification and scoring process frees inspectors from the heavy and repetitive manual interpretation work, significantly shortens the evaluation cycle, and can quickly process massive amounts of video data; (3) The refined assessment can accurately locate the defect location and severity, providing a precise basis for formulating economical and efficient maintenance plans. The automated three-level status judgment and maintenance suggestions provide managers with clear and direct decision support. (4) By timely detection and assessment of potential risks, early intervention can be carried out, monitoring or preventive maintenance can be strengthened, and rapid response and location of serious defects can help eliminate dangers in a timely manner and ensure the safe operation of urban infrastructure. (5) The long-term accumulated pipe segment scoring data and defect information can form data on the health status of the pipeline network, providing data support for the long-term performance prediction, aging trend analysis and optimization of maintenance strategies of the pipeline network; it helps to identify common problems of pipelines in specific areas, with specific materials or in specific years, and provides a reference for future pipeline planning and construction. (6) By improving detection efficiency, achieving precise maintenance, and preventing major accidents, the long-term operation and maintenance costs of the pipeline network can be effectively reduced. Attached Figure Description
[0020] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0021] Figure 1 This is a flowchart of the present invention. Detailed Implementation
[0022] The present invention will now be described in further detail with reference to the accompanying drawings. These drawings are simplified schematic diagrams, illustrating only the basic structure of the invention, and therefore only show the components relevant to the invention.
[0023] like Figure 1 As shown, a method for intelligent assessment of pipeline defects based on a multimodal large model includes the following steps: S1. Process the pipeline inspection video to identify and locate pipeline defects, and obtain a defect dataset containing defect category and location information; S2. Divide the pipeline into multiple continuous pipe segments, count the number and distribution of various defects in each segment, and calculate the statistical score of each segment according to preset rules. ; S3. Combine the defect image and / or text description corresponding to the defect identified in step S1 with preset standardized prompt words, and input them into the multimodal large language model; the multimodal large language model analyzes the severity of the defect based on the prompt words and outputs an intelligent score for each defect. Intelligent scoring of all defects within a pipe section By combining the results, an intelligent score for this pipe section is obtained. ; S4. Statistical scoring for each pipe segment. With intelligent scoring A weighted fusion is performed to obtain the comprehensive score for this pipe section. Based on the overall score The health status of pipe segments and / or the entire pipeline is classified and decision recommendations are generated.
[0024] In step S1, the pipeline inspection video is a CCTV closed-circuit television inspection video of the urban underground pipe network. Computer vision technology is used to process and analyze the pipeline video, and output a series of images containing defect information, as well as preliminary information of each defect, including the defect type, such as cracks, ruptures, deformation, leakage, foreign object intrusion, corrosion, etc., and its location in the video, which usually corresponds to the pipeline mileage or the distance from the pipe opening.
[0025] The process of processing and analyzing pipeline videos using computer vision technology includes the following steps: S101. Extract image frames from the pipeline inspection video, and perform distortion correction, image enhancement and data cleaning operations on the image frames in sequence to obtain a high-quality image set to be analyzed. S102. Input the set of images to be analyzed into a pre-trained instance segmentation model to obtain the model inference result for each image; the model inference result includes the category label, confidence score, bounding box coordinates and pixel-level binary mask for each detected defect instance; S103. Filter and smooth the model inference results, and calculate the geometric features of each defect instance based on the processed pixel-level binary mask.
[0026] In step S101, a keyframe extraction algorithm is used to extract image frames from the video, extracting only frames with significant content changes. CCTV fisheye lenses cause image distortion, and distortion correction can improve the accuracy of subsequent defect analysis. To address issues such as uneven lighting, low contrast, and noise, histogram equalization, adaptive contrast enhancement, and Gaussian filtering algorithms are used sequentially to improve image quality and enhance the representation of defect features in the image. Data cleaning removes invalid frames that are completely blurry or have extremely high repetition. From the selected image frames, image samples containing typical defects such as cracks, breaks, misalignments, leaks, foreign objects, corrosion, and deformation, as well as defect-free image samples, are selected.
[0027] The following algorithms are used sequentially in the image enhancement operation: Histogram equalization: used to enhance image contrast; Adaptive contrast enhancement: Used for localized adjustment of bright and dark areas in an image; Adaptive texture enhancement filtering: used for image denoising and enhancing defect texture features; local region variance is used to address texture complexity. To represent, the calculation formula is: , Where W is a local window centered at (x, y); The number of pixels in window W; Let (i, j) be the grayscale value of pixel (i, j) within window W; It is the local mean of all pixels within window W; To sum all pixels within window W; Based on local regional variance Construct a texture weight adjustment factor h, calculated using the following formula: , in, , and The standard deviation parameter; For spatial distance, a Gaussian function is used to represent it. The formula for calculating the two-dimensional Gaussian function kernel is as follows: , Where (x, y) are the coordinates of a point in the kernel. The standard deviation parameter; The formula for calculating the overall weight w is: , Right now .
[0028] If the local variance It's very large (with complex textures), so A smaller value results in a lower overall weight w, leading to better preservation of edges and details. Conversely, a larger value in a flat region... Small, factor A value close to 1 indicates a stronger filtering effect.
[0029] The pre-trained instance segmentation model in step S102 is the YOLACT model, which is trained through the following steps: S102a. Constructing the training dataset: Obtain images of the inside of the pipeline, use annotation tools to perform pixel-level contour annotations on various defect instances in the images, and generate annotation files containing bounding box coordinates, category labels, and instance masks; divide the annotated dataset into training set, validation set, and test set according to the proportions. S102b, Model Training: The training set and validation set are input into the YOLACT network for training; the overall loss function L of the YOLACT network... total Classification loss L cls Bounding box regression loss L box and mask loss L mask The calculation formula is based on a weighted average of three parts: , Where α, β, and γ are weight coefficients; classification loss L cls Cross-entropy loss function is used; bounding box regression loss L box Smooth L1 loss function is used; mask loss L mask A pixel-level binary cross-entropy loss function is used.
[0030] S102c, Model Testing and Selection: Evaluate the trained model on the test set, using the mean accuracy (mAP) based on the mask as the evaluation metric, and select the model with an mAP value greater than 95% as the final defect detection model.
[0031] In step S102a, the ratio of training set, validation set, and test set is 7:2:1; in step S102b, the YOLACT network adopts a one-stage model, with end-to-end output, requiring no secondary processing and thus being faster.
[0032] The post-processing operations in step S103 include: Set a confidence threshold to filter out defect detection results with a confidence score below 0.9; The pixel-level binary mask of the defect is smoothed by using opening and closing operations in morphological operations. The geometric features of each defect instance are calculated based on the processed pixel-level binary mask. These features include the defect area A, the defect perimeter P, and shape parameters. The defect area A is obtained by counting the total number of pixels with a value of 1 in the binary mask. The defect perimeter P is obtained by calculating the total number of pixels on the outline of the binary mask. The shape parameters include roundness C and aspect ratio R. Circularity C describes how close a defect shape is to a circle, and its calculation formula is as follows: ; The length-width factor R represents the dimensional characteristics of a defect in two mutually perpendicular directions. It is used to describe non-circular or asymmetrical shapes. The minimum bounding rectangle of the defect region has a length of L and a width of B. The formula for calculating the length-width factor R is: ; The texture feature T of defect region A is represented as: ; Statistical scoring based on a combination of geometric and texture features w s The calculation formula is: , in, , and These are the weighting coefficients. This represents the maximum defect area in a single segment. This indicates that normalization is being performed.
[0033] Step S2 specifically involves: logically segmenting the entire pipeline into 1-meter units; for each 1-meter segment, calculating the total number of defects, the number of each type of defect, and the distribution of defects, such as their concentration and whether they are located in critical locations like joints; and, based on preset statistical scoring rules (e.g., lower scores for higher defect counts and greater weight for severe defects), performing a preliminary quantitative score for each 1-meter segment, which is recorded as the statistical score. .
[0034] The standardized prompt words in step S3 include instructions for guiding the multimodal large language model to perform at least one of the following tasks: Please analyze this image of the pipe defect. Assess the extent to which the defects affect the stability of the pipeline structure; Assess the potential impact of the defect size on pipeline function; The overall severity of the defects is quantified.
[0035] The multimodal large language model uses the Qwen2.5-vl model, which has image understanding capabilities. It intelligently scores all defects within a 1-meter pipe section. The average value is used to obtain the intelligent score for this pipe section. The calculation formula is as follows: , Where N is the total number of defects identified within the pipe section. This represents the intelligent score for the i-th defect within the pipe section; Alternatively, the minimum value can be used to obtain the intelligent score for that pipe section. The calculation formula is as follows: .
[0036] In step S4, the statistical score of each 1-meter pipe segment is calculated. With intelligent scoring The weighted fusion is calculated using the following formula: , in, and These are the weighting coefficients, and + =1, and The value can be adjusted based on practical experience and the emphasis placed on the two types of scores.
[0037] In step S4, the overall score of all 1-meter pipe sections is calculated. The minimum value is used as the overall score for the entire pipeline section. Comprehensive score based on pipe section (For precise positioning) or comprehensive scoring of pipelines (For overall evaluation), set thresholds for three levels of judgment: Level 1 status: ≥ This indicates that there are no defects or that the defects are minor. Level 2 status: ≤ < This indicates that there are defects that require attention; Level 3 status: < This indicates a serious defect; in, and For a preset threshold, and > Level 1 is a healthy state, with no defects or only a few minor defects that do not affect normal use and pipeline function; Level 2 is a concern state, with minor or general defects that may slightly affect pipeline function, requiring close monitoring and regular re-inspection is recommended; Level 3 is an emergency state, with serious defects that have significantly affected pipeline function or pose a safety hazard, requiring immediate repair.
[0038] For pipe sections assessed as Level 3, maintenance recommendations are generated, specifying the location and length requiring repair. The maintenance location is the starting and ending mileage of the pipe section with the serious defect, and the maintenance length is the total length requiring repair. Based on the main defect type, pipe material, structure, and other factors, a knowledge base is searched to automatically generate maintenance recommendations and solutions.
[0039] This embodiment combines statistical quantitative scoring with intelligent judgment scoring based on a multimodal large model, making the evaluation results more comprehensive and closer to expert judgment. By applying the multimodal large model to the in-depth analysis and evaluation of pipeline defect images, it can understand the image content and, in conjunction with fixed prompt words, perform more refined intelligent scoring of defects from multiple dimensions. By unifying the scoring standards and rules of the multimodal large model through preset standard prompt words, it overcomes the subjectivity and inconsistency of manual evaluation and improves the reliability and reproducibility of the evaluation results.
[0040] Analyzing, statistically analyzing, and scoring pipe sections in 1-meter increments allows for more precise location of problematic sections, providing a more accurate basis for subsequent maintenance decisions. Based on the comprehensive score, it automatically performs three-level status assessments and can clearly indicate the location and length requiring immediate repair, improving decision-making efficiency and practicality.
[0041] Based on the above-described preferred embodiments of the present invention, and through the foregoing description, those skilled in the art can make various changes and modifications without departing from the inventive concept. The technical scope of this invention is not limited to the contents of the specification, but must be determined according to the scope of the claims.
Claims
1. A method for intelligent assessment of pipeline defects based on a multimodal large model, characterized in that, Includes the following steps: S1. Process the pipeline inspection video to identify and locate pipeline defects, and obtain a defect dataset containing defect category and location information; S2. Divide the pipeline into multiple continuous pipe segments, count the number and distribution of various defects in each segment, and calculate the statistical score of each segment according to preset rules. ; S3. Combine the defect image and / or text description corresponding to the defect identified in step S1 with preset standardized prompt words, and input them into the multimodal large language model; the multimodal large language model analyzes the severity of the defect based on the prompt words and outputs an intelligent score for each defect. Intelligent scoring of all defects within a pipe section By combining the results, an intelligent score for this pipe section is obtained. ; S4. Statistical scoring for each pipe segment. With intelligent scoring A weighted fusion is performed to obtain the comprehensive score for this pipe section. Based on the overall score The health status of pipe segments and / or the entire pipeline is classified and decision recommendations are generated.
2. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 1, characterized in that: The standardized prompt words in step S3 include instructions for guiding the multimodal large language model to perform at least one of the following tasks: Assess the extent to which the defects affect the stability of the pipeline structure; Assess the potential impact of the defect size on pipeline function; The overall severity of the defects is quantitatively scored; Explain the main criteria for scoring.
3. The intelligent pipeline defect assessment method based on a multimodal large model according to claim 1, characterized in that: In step S3, intelligent scoring is performed on all defects within a pipe section. By combining the results, an intelligent score for this pipe section is obtained. The calculation formula is as follows: , Where N is the total number of defects identified within the pipe section. This represents the intelligent score for the i-th defect within the pipe section; or .
4. The intelligent pipeline defect assessment method based on a multimodal large model according to claim 3, characterized in that: The formula for calculating the weighted fusion in step S4 is: , in, and These are the weighting coefficients, and + =1.
5. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 1, characterized in that: In step S4, the health status is divided into three levels: Level 1 status: ≥ This indicates that there are no defects or that the defects are minor. Level 2 status: ≤ < This indicates that there are defects that require attention; Level 3 status: < This indicates a serious defect; in, and For a preset threshold, and > .
6. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 5, characterized in that: For pipe sections whose health status is assessed as Level 3, maintenance recommendations are generated. These recommendations include the starting and ending points of the pipe section requiring maintenance, as well as the maintenance length.
7. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 1, characterized in that: Step S1 involves processing the pipeline inspection video, specifically including the following steps: S101. Extract image frames from the pipeline inspection video, and perform distortion correction, image enhancement and data cleaning operations on the image frames in sequence to obtain a high-quality image set to be analyzed. S102. Input the set of images to be analyzed into a pre-trained instance segmentation model to obtain the model inference result for each image; the model inference result includes the category label, confidence score, bounding box coordinates and pixel-level binary mask for each detected defect instance; S103. Filter and smooth the model inference results, and calculate the geometric features of each defect instance based on the processed pixel-level binary mask.
8. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 7, characterized in that: The image enhancement operation in step S101 employs the following algorithms sequentially: Histogram equalization: used to enhance image contrast; Adaptive contrast enhancement: Used for localized adjustment of bright and dark areas in an image; Adaptive texture enhancement filtering: used for image denoising and enhancing defect texture features; local region variance is used to address texture complexity. To represent, the calculation formula is: , Where W is a local window centered at (x, y); The number of pixels in window W; Let (i, j) be the grayscale value of pixel (i, j) within window W; It is the local mean of all pixels within window W; To sum all pixels within window W; Based on local regional variance Construct a texture weight adjustment factor h, calculated using the following formula: , in, , and The standard deviation parameter; For spatial distance, a Gaussian function is used to represent it. The formula for calculating the two-dimensional Gaussian function kernel is as follows: , Where (x, y) are the coordinates of a point in the kernel. The standard deviation parameter; The formula for calculating the overall weight w is: , Right now .
9. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 7, characterized in that: The pre-trained instance segmentation model in step S102 is the YOLACT model, which is trained through the following steps: S102a. Constructing the training dataset: Obtain images inside the pipeline, use annotation tools to perform pixel-level contour annotations on various defect instances in the images, and generate annotation files containing bounding box coordinates, category labels, and instance masks; The labeled dataset is divided into training set, validation set and test set according to the proportions; S102b, Model Training: The training set and validation set are input into the YOLACT network for training; the overall loss function L of the YOLACT network... total Classification loss L cls Bounding box regression loss L box and mask loss L mask The calculation formula is based on a weighted average of three parts: , Where α, β, and γ are weight coefficients; classification loss L cls Cross-entropy loss function is used; bounding box regression loss L box Smooth L1 loss function is used; mask loss L mask A pixel-level binary cross-entropy loss function is used. S102c, Model Testing and Selection: Evaluate the trained model on the test set, using the mean accuracy (mAP) based on the mask as the evaluation metric, and select the model with an mAP value greater than 95% as the final defect detection model.
10. The intelligent assessment method for pipeline defects based on a multimodal large model according to claim 7, characterized in that: The post-processing operations in step S103 include: Set a confidence threshold to filter out defect detection results with a confidence score below 0.9; The pixel-level binary mask of the defect is smoothed by using opening and closing operations in morphological operations. The geometric features of each defect instance are calculated based on the processed pixel-level binary mask. These features include the defect area A, the defect perimeter P, and shape parameters. The defect area A is obtained by counting the total number of pixels with a value of 1 in the binary mask, and the defect perimeter P is obtained by calculating the total number of pixels on the outline of the binary mask. Shape parameters include roundness C and aspect ratio R. Circularity C describes how close a defect shape is to a circle, and its calculation formula is as follows: ; The length-width factor R represents the dimensional characteristics of a defect in two mutually perpendicular directions. It is used to describe non-circular or asymmetrical shapes. The minimum bounding rectangle of the defect region has a length of L and a width of B. The formula for calculating the length-width factor R is: ; The texture feature T of defect region A is represented as: ; Statistical scoring based on a combination of geometric and texture features w s The calculation formula is: , in, , and These are the weighting coefficients. This represents the maximum defect area in a single segment. This indicates that normalization is being performed.
Citation Information
Cited By
Intelligent grading method for pipeline disease defect indexes and related equipment
CN121685547A
A pipeline detection engineering data quality evaluation method, system and device
CN122285654A
