Drainage pipeline defect detection method based on improved target detection model

Through the improved object detection model, including YOLOv5, cross-stage space pyramid pooling module, attention mechanism module GAM and BN algorithm, the problem of insufficient detection accuracy of drainage pipeline defects in the existing technology is solved, and more accurate detection results are achieved.

CN119991646APending Publication Date: 2025-05-13WANJITAI TECH GRP DIGITAL CITY TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510163991.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-02-14
Publication Date
2025-05-13

AI Technical Summary

Technical Problem

The existing drainage pipeline defect detection algorithm has insufficient accuracy when detecting defect categories similar and small target defects, making it difficult to effectively extract different characteristics of similar defects and enhance the ability to identify small target defects.

Method used

The improved object detection model is adopted, including starting the YOLOv5 algorithm, introducing a cross-stage spatial pyramid pooling module, adding an attention mechanism module GAM, and standardizing the BN algorithm at the output layer to improve detection accuracy.

Benefits of technology

Through the improved target detection model, similar defects and small target defects in the drainage pipe can be more accurately detected, improving detection accuracy and efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119991646A_ABST
    Figure CN119991646A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of pipeline defect detection, and discloses a drainage pipeline defect detection method based on an improved target detection model, and the method comprises the following steps: S1, employing an algorithm model of a convolutional neural network, starting a defect detection algorithm of YOLOv5, employing three loss functions in YOLOv5, and employing a detection process of YOLOv5; according to the method, original maximum pooling is changed into average pooling, so that jitter of a certain point can be avoided, distribution of most numerical values in a sampling area is ignored, cross-stage feature connection is performed on an original multi-scale feature map, semantic information of the multi-scale feature map is greatly enriched, semantic information of the feature map is greatly enriched, and the accuracy of the multi-scale feature map is improved. Compared with the prior art, the method provided by the invention has the advantages that the method has the advantages that the multi-scale feature map is obtained, similar defect details are allowed to be controlled deeper, and the CSSPF module not only enhances the expression ability of the multi-scale feature map, but also greatly enriches the semantic information of the feature map, so that the model is more accurate when detecting similar defects in the drainage pipeline.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of pipeline defect detection, and in particular to a drainage pipeline defect detection method based on an improved target detection model. Background Art

[0002] Drainage pipe defect detection technology is one of the key technologies to ensure the safe operation of urban drainage systems. With the acceleration of urbanization and the continuous expansion of urban infrastructure, the maintenance and management of drainage pipes have become particularly important. There are various drainage pipe defect detection technologies, including CCTV, sonar, periscope, laser, infrared thermal imaging and ground penetrating radar. These technologies can be used to find hidden or covered inspection wells or unknown pipe sections in the drainage system, determine the source and connection points of illegal sewage discharge, investigate the causes of pipeline siltation and poor drainage, and detect pipeline corrosion, damage, interface misalignment, siltation, sewage leakage and pollution.

[0003] With the progress in computing efficiency and data storage capacity, deep learning methods, especially convolutional neural networks, have been widely adopted in defect detection. It can automatically identify the type, location, degree and other information of pipeline defects by analyzing and processing images and video data obtained by CCTV detection, periscope detection, etc. At present, the mainstream defect detection algorithms are mainly divided into two categories: two-stage detection algorithms and one-stage detection algorithms. Among them, the two-stage detection algorithm converts the detection problem into a classification problem of local images in the generated proposal area through explicit region proposals. The one-stage detection algorithm regards defect detection as a regression problem, directly mapping from image pixels to bounding box coordinates and category probabilities. However, in the case of similar defect categories and defects belonging to small targets, the accuracy of these two algorithms may be affected. Therefore, how to effectively extract different features of similar defects and enhance the recognition ability of small target defects is a research hotspot today. Summary of the invention

[0004] The present invention provides a drainage pipe defect detection method based on an improved target detection model, which has the advantages of accurate and efficient detection of drainage pipe defects and solves the problems raised by the above-mentioned background technology.

[0005] The present invention provides the following technical solution: a drainage pipe defect detection method based on an improved target detection model, comprising the following steps:

[0006] Step S1:

[0007] The algorithm model of convolutional neural network, starting the defect detection algorithm of YOLOv5, the three loss functions used in YOLOv5, and the detection process of YOLOv5;

[0008] Step S2:

[0009] Start the cross-stage spatial pyramid pooling module;

[0010] Step S3:

[0011] Add the attention mechanism module GAM to solve the unnecessary computation and time costs in the defect detection process;

[0012] Step S4:

[0013] The output layer uses the BN algorithm to standardize small batches of data so that the output data has a mean of 0 and a variance of 1, resulting in the following formula:

[0014] y=σ(BN(Conv([x0,x1,x2,...,xn]))) (8).

[0015] Preferably, step 1 specifically includes:

[0016] The working principle of YOLOv5 is to divide the input image into an S×S grid. If the center point of the detected object falls within a certain grid cell, the cell is responsible for predicting the bounding box and category probability of the object. Each grid cell predicts B bounding boxes and the confidence of these bounding boxes. The confidence reflects the model's confidence in the objects contained in the bounding box and the accuracy of the predicted box. The algorithm predicts C conditional category probabilities for each bounding box, where C is the total number of categories. These probabilities indicate the possibility of detecting objects of a specific category within the bounding box. During the prediction process, multiple bounding boxes may be generated for a single object. YOLOv5 uses non-maximum suppression (NMS) to handle this problem.

[0017] The steps of the YOLOv5 algorithm are as follows:

[0018] ① Divide all frames into categories and remove the background category;

[0019] ② Arrange the bounding boxes in each object class in descending order of classification confidence;

[0020] ③ In a certain category, select the bounding box BOX1 with the highest confidence, remove BOX1 from the input list, and add it to the output list;

[0021] ④ Calculate the intersection over union (IoU) of BOX1 and the remaining BOX2 one by one. The formula is as follows:

[0022]

[0023] This formula can be visualized as follows:

[0024]

[0025] If IoU(BOX1,BOX2)>preset threshold, remove BOX2 from the input;

[0026] ⑤ Repeat steps 3 to 4 until the input list is empty, completing the traversal of an object class;

[0027] ⑥ Repeat 2 to 5 until the NMS processing of all object classes is completed;

[0028] ⑦ Output list, the algorithm ends;

[0029] The following three loss functions are used in YOLOv5:

[0030]

[0031] In the formula where x i is the predicted value of the current category, y i is the probability of the current category after the activation function, is the true value of the current category (0 or 1), N is the number of prediction boxes, C is the number of categories, L class is the classification loss;

[0032]

[0033] In the formula, BOX p is the prediction box, BOX t is the real box, where v is the normalized difference between the length and width ratio of the predicted box and the real box, The value of the part is between 0 and Between, multiply by After that, it can be converted to between 0 and 1, and α is a balance factor that weighs the loss caused by the aspect ratio and the loss caused by the IOU part. CIOU is the bounding box loss;

[0034]

[0035] is the true value of confidence (0 or 1), p i is the confidence value predicted by the model, L obj is the confidence loss;

[0036] The overall loss of YOLOv5 is L v5 The weighted addition of the above three is as follows:

[0037] L v5 =λ class L class +λ CIOU L CIOU +λ obj L obj(7)

[0038] Where λ class , CIOU and λ obj They are the weight coefficients of classification loss, bounding box loss and confidence loss respectively. The attention paid to the three losses can be adjusted by changing the weights;

[0039] The detection process of YOLOv5 is as follows:

[0040] ① Input layer: receives input images;

[0041] ② Use convolution and C3 modules to perform preliminary feature extraction on the input image. The C3 module is the core component in YOLOv5. It consists of multiple convolutional layers and residual connections for further feature extraction.

[0042] ③ At the end of the backbone, the SPPF module is used to further extract and fuse multi-scale features. The structure of SPPF is as follows: Figure 2 As shown in the figure, compared with the traditional SPP, which realizes multi-scale feature extraction by applying pooling kernels of different sizes in parallel, SPPF achieves this goal by serially applying pooling kernels of the same size. This serial structure reduces the amount of calculation of SPPF, thereby improving the operation speed. Compared with SPP, SPPF reduces the amount of calculation and improves the running speed of the model. After the SPPF module, the convolution layer is used again to further process the features.

[0043] ④The Neck part adopts the FPN-PAN structure and constructs a feature pyramid through multiple downsampling and upsampling operations to capture features of different scales;

[0044] ⑤Concat operation: concatenate feature maps between different layers of the feature pyramid to achieve feature fusion;

[0045] ⑥At each level of the feature pyramid, use the detection layer to predict bounding boxes, class probabilities, and confidence scores;

[0046] ⑦Finally output the detection results, including the location, category and confidence of the target.

[0047] Preferably, step 2 specifically includes:

[0048] First, the original maximum pooling is changed to average pooling, which can avoid jitter at a certain point and ignore the distribution of most values ​​in the sampling area. Secondly, by performing cross-stage feature connection on the original multi-scale feature map, not only the semantic information of the multi-scale feature map is greatly enriched, but also the main network can grasp the deep semantic information when extracting features in the first stage, and can grasp the shallow detail features when fusing shallow features, which greatly enriches the semantic information of the feature map and allows for deeper control of similar defect details. The CSSPPF module not only enhances the expressive power of the multi-scale feature map, but also greatly enriches the semantic information of the feature map, making the model more accurate in detecting similar defects in drainage pipes.

[0049] Preferably, step 3 specifically includes:

[0050] The GAM enables the entire network to suppress complex and irrelevant background information in the pipeline image, highlight the hot spots of pipeline defects in the image, and detect defective objects faster and more accurately.

[0051] Preferably, step 4 specifically includes:

[0052] Adding a fourth detection zone to YOLOv5 and replacing the C3 module with a dense convolutional neural network architecture enables the model to better detect small object defects and further improve detection accuracy;

[0053] The output of each layer of DenseNet is connected to all previous layers on the data channel and used as the input of the next layer. The output layer uses the BN algorithm to standardize small batches of data.

[0054] The collaborative output structure of the multi-layer network strengthens the reuse of features, thereby enhancing the detection ability of small objects.

[0055] The present invention has the following beneficial effects:

[0056] 1. The drainage pipe defect detection method based on the improved target detection model changes the original maximum pooling to average pooling, which can avoid jitter at a certain point and ignore the distribution of most values ​​in the sampling area. Secondly, by performing cross-stage feature connection on the original multi-scale feature map, not only the semantic information of the multi-scale feature map is greatly enriched, but also the main network can grasp the deep semantic information when extracting features in the first stage, and can grasp the shallow detail features when fusing shallow features, which greatly enriches the semantic information of the feature map and allows for deeper control of similar defect details. The CSSPPF module not only enhances the expression ability of the multi-scale feature map, but also greatly enriches the semantic information of the feature map, making the model more accurate in detecting similar defects in drainage pipes.

[0057] 2. This drainage pipe defect detection method based on the improved target detection model introduces the GAM attention mechanism, which enables the GAM to enable the entire network to suppress complex and irrelevant background information in the pipeline image, highlight the hotspots of pipeline defects in the image, and detect defective objects faster and more accurately. A fourth detection area is added to YOLOv5 and the C3 module is replaced with a dense convolutional neural network architecture, so that the model can better detect small object defects and further improve the detection accuracy. The output of each layer of DenseNet is connected to all the previous layers on the data channel and serves as the input of the next layer. The output layer uses the BN algorithm to standardize small batches of data. The collaborative output structure of the multi-layer network strengthens the reuse of features, thereby enhancing the detection ability of small targets. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] Figure 1 It is a schematic diagram of the structure of YOLOv5 of the present invention;

[0059] Figure 2 It is a schematic diagram of the SPPF structure of the present invention;

[0060] Figure 3 This is a schematic diagram of the CSSPPF module structure of the present invention;

[0061] Figure 4 This is a schematic diagram of the GAM module structure of the present invention;

[0062] Figure 5 This is a schematic diagram of the DenseNet structure of the present invention;

[0063] Figure 6 This is a schematic diagram of the improved YOLOv5 structure of the present invention. DETAILED DESCRIPTION

[0064] 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.

[0065] See also Figure 1-6 ,The drainage pipe defect detection method based on the improved target detection model includes the following steps:

[0066] Step S1:

[0067] The algorithm model of convolutional neural network, starting the defect detection algorithm of YOLOv5, the three loss functions used in YOLOv5, and the detection process of YOLOv5;

[0068] Step S2:

[0069] Start the cross-stage spatial pyramid pooling module;

[0070] Step S3:

[0071] Add the attention mechanism module GAM to solve the unnecessary computation and time costs in the defect detection process;

[0072] Step S4:

[0073] The output layer uses the BN algorithm to standardize small batches of data so that the output data has a mean of 0 and a variance of 1, resulting in the following formula:

[0074] y=σ(BN(Conv([x0,x1,x2,...,xn]))) (8).

[0075] In a preferred embodiment, step 1 specifically includes:

[0076] YOLOv5 works by dividing the input image into an S×S grid. If the center point of the detected object falls within a grid cell, the cell is responsible for predicting the bounding box and category probability of the object. Each grid cell predicts B bounding boxes and the confidence of these bounding boxes. The confidence reflects the model's confidence in the objects contained in the bounding box and the accuracy of the predicted box. The algorithm predicts C conditional category probabilities for each bounding box, where C is the total number of categories. These probabilities indicate the possibility of detecting objects of a specific category within the bounding box. During the prediction process, multiple bounding boxes may be generated for a single object. YOLOv5 uses non-maximum suppression (NMS) to handle this problem.

[0077] The steps of the YOLOv5 algorithm are as follows:

[0078] ① Divide all frames into categories and remove the background category;

[0079] ② Arrange the bounding boxes in each object class in descending order of classification confidence;

[0080] ③ In a certain category, select the bounding box BOX1 with the highest confidence, remove BOX1 from the input list, and add it to the output list;

[0081] ④ Calculate the intersection over union (IoU) of BOX1 and the remaining BOX2 one by one. The formula is as follows:

[0082]

[0083] This formula can be visualized as follows:

[0084]

[0085] If IoU(BOX1,BOX2)>preset threshold, remove BOX2 from the input;

[0086] ⑤ Repeat steps 3 to 4 until the input list is empty, completing the traversal of an object class;

[0087] ⑥ Repeat 2 to 5 until the NMS processing of all object classes is completed;

[0088] ⑦ Output list, the algorithm ends;

[0089] The following three loss functions are used in YOLOv5:

[0090]

[0091] In the formula where x i is the predicted value of the current category, y i is the probability of the current category after the activation function, is the true value of the current category (0 or 1), N is the number of prediction boxes, C is the number of categories, L class is the classification loss;

[0092]

[0093]

[0094] In the formula, BOX p is the prediction box, BOX t is the real box, where v is the normalized difference between the length and width ratio of the predicted box and the real box, The value of the part is between 0 and Between, multiply by After that, it can be converted to between 0 and 1, and α is a balance factor that weighs the loss caused by the aspect ratio and the loss caused by the IOU part. CIOU is the bounding box loss;

[0095]

[0096] is the true value of confidence (0 or 1), p i is the confidence value predicted by the model, L obj is the confidence loss;

[0097] The overall loss of YOLOv5 is L v5 The weighted addition of the above three is as follows:

[0098] L v5 =λ classL class +λ CIOU L CIOU +λ obj L obj (7)

[0099] Where λ class , CIOU and λ obj They are the weight coefficients of classification loss, bounding box loss and confidence loss respectively. The attention paid to the three losses can be adjusted by changing the weights;

[0100] The detection process of YOLOv5 is as follows:

[0101] ① Input layer: receives input images;

[0102] ② Use convolution and C3 modules to perform preliminary feature extraction on the input image. The C3 module is the core component in YOLOv5. It consists of multiple convolutional layers and residual connections for further feature extraction.

[0103] ③ At the end of the backbone, the SPPF module is used to further extract and fuse multi-scale features. The structure of SPPF is as follows: Figure 2 As shown in the figure, compared with the traditional SPP, which realizes multi-scale feature extraction by applying pooling kernels of different sizes in parallel, SPPF achieves this goal by serially applying pooling kernels of the same size. This serial structure reduces the amount of calculation of SPPF, thereby improving the operation speed. Compared with SPP, SPPF reduces the amount of calculation and improves the running speed of the model. After the SPPF module, the convolution layer is used again to further process the features.

[0104] ④The Neck part adopts the FPN-PAN structure and constructs a feature pyramid through multiple downsampling and upsampling operations to capture features of different scales;

[0105] ⑤Concat operation: concatenate feature maps between different layers of the feature pyramid to achieve feature fusion;

[0106] ⑥At each level of the feature pyramid, use the detection layer to predict bounding boxes, class probabilities, and confidence scores;

[0107] ⑦Finally output the detection results, including the location, category and confidence of the target.

[0108] In a preferred embodiment, step 2 specifically includes:

[0109] First, the original maximum pooling is changed to average pooling, which can avoid jitter at a certain point and ignore the distribution of most values ​​in the sampling area. Secondly, by performing cross-stage feature connection on the original multi-scale feature map, not only the semantic information of the multi-scale feature map is greatly enriched, but also the main network can grasp the deep semantic information when extracting features in the first stage, and can grasp the shallow detail features when fusing shallow features, which greatly enriches the semantic information of the feature map and allows for deeper control of similar defect details. The CSSPPF module not only enhances the expressive power of the multi-scale feature map, but also greatly enriches the semantic information of the feature map, making the model more accurate in detecting similar defects in drainage pipes.

[0110] In a preferred embodiment, step 3 specifically includes:

[0111] GAM enables the entire network to suppress complex and irrelevant background information in pipeline images, highlight the hotspots of pipeline defects in images, and detect defective objects faster and more accurately.

[0112] In a preferred embodiment, step 4 specifically includes:

[0113] Adding a fourth detection zone to YOLOv5 and replacing the C3 module with a dense convolutional neural network architecture enables the model to better detect small object defects and further improve detection accuracy;

[0114] The output of each layer of DenseNet is connected to all previous layers on the data channel and used as the input of the next layer. The output layer uses the BN algorithm to standardize small batches of data.

[0115] The collaborative output structure of the multi-layer network strengthens the reuse of features, thereby enhancing the detection ability of small objects.

[0116] It should be noted that, in this article, relational terms such as first and second, etc. are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device.

[0117] 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 drainage pipe defect detection method based on an improved target detection model, characterized in that: The following steps are involved: Step S1: The algorithm model of convolutional neural network, starting the defect detection algorithm of YOLOv5, the three loss functions used in YOLOv5, and the detection process of YOLOv5; Step S2: Start the cross-stage spatial pyramid pooling module; Step S3: Add the attention mechanism module GAM to solve the unnecessary computation and time costs in the defect detection process; Step S4: The output layer uses the BN algorithm to standardize small batches of data so that the output data has a mean of 0 and a variance of 1, resulting in the following formula: y=σ(BN(Conv([x0,x1,x2,...,xn]))) (8).

2. The drainage pipe defect detection method based on the improved target detection model according to claim 1 is characterized in that: Step 1 specifically includes: The working principle of YOLOv5 is to divide the input image into an S×S grid. If the center point of the detected object falls within a certain grid unit, the unit is responsible for predicting the bounding box and category probability of the object. Each grid unit predicts B bounding boxes and the confidence of these bounding boxes. The confidence reflects the model's confidence in the objects contained in the bounding box and the accuracy of the predicted box. The algorithm predicts C conditional category probabilities for each bounding box, where C is the total number of categories. These probabilities represent the possibility of detecting objects of a specific category in the bounding box. During the prediction process, multiple bounding boxes may be generated for a single object. YOLOv5 uses non-maximum suppression (NMS) to handle this problem. The steps of the YOLOv5 algorithm are as follows: ① Divide all frames into categories and remove the background category; ② Arrange the bounding boxes in each object class in descending order of classification confidence; ③ In a certain category, select the bounding box BOX1 with the highest confidence, remove BOX1 from the input list, and add it to the output list; ④ Calculate the intersection over union (IoU) of BOX1 and the remaining BOX2 one by one. The formula is as follows: This formula can be visualized as follows: If IoU(BOX1,BOX2)>preset threshold, remove BOX2 from the input; ⑤ Repeat steps 3 to 4 until the input list is empty, completing the traversal of an object class; ⑥ Repeat 2 to 5 until the NMS processing of all object classes is completed; ⑦ Output list, the algorithm ends; The following three loss functions are used in YOLOv5: In the formula where x i is the predicted value of the current category, y i is the probability of the current category after the activation function, is the true value of the current category (0 or 1), N is the number of prediction boxes, C is the number of categories, L class is the classification loss; In the formula, BOX p is the prediction box, BOX t is the real box, where v is the normalized difference between the length and width ratio of the predicted box and the real box, The value of the part is between 0 and Between, multiply by After that, it can be converted to between 0 and 1, and α is a balance factor that weighs the loss caused by the aspect ratio and the loss caused by the IOU part. CIOU is the bounding box loss; is the true value of confidence (0 or 1), p i is the confidence value predicted by the model, L obj is the confidence loss; The overall loss of YOLOv5 is L v5 The weighted addition of the above three is as follows: L v5 =λ class L class +λ CIOU L CIOU +λ obj L obj (7) Where λ class , CIOU and λ obj They are the weight coefficients of classification loss, bounding box loss and confidence loss respectively. The attention paid to the three losses can be adjusted by changing the weights; The detection process of YOLOv5 is as follows: ① Input layer: receives input images; ② Use convolution and C3 modules to perform preliminary feature extraction on the input image. The C3 module is the core component in YOLOv5. It consists of multiple convolutional layers and residual connections for further feature extraction. ③ At the end of the backbone, the SPPF module is used to further extract and fuse multi-scale features. The structure of SPPF is shown in Figure 2. Compared with the traditional SPP, which realizes multi-scale feature extraction by applying pooling kernels of different sizes in parallel, SPPF achieves this goal by serially applying pooling kernels of the same size. This serial structure reduces the amount of calculation of SPPF, thereby improving the operation speed. Compared with SPP, SPPF reduces the amount of calculation and improves the running speed of the model. After the SPPF module, the convolution layer is used again to further process the features; ④The Neck part adopts the FPN-PAN structure and constructs a feature pyramid through multiple downsampling and upsampling operations to capture features of different scales; ⑤Concat operation: concatenate feature maps between different layers of the feature pyramid to achieve feature fusion; ⑥At each level of the feature pyramid, use the detection layer to predict bounding boxes, class probabilities, and confidence scores; ⑦Finally output the detection results, including the location, category and confidence of the target.

3. The drainage pipe defect detection method based on the improved target detection model according to claim 1 is characterized in that: Step 2 specifically includes: First, the original maximum pooling is changed to average pooling, which can avoid jitter at a certain point and ignore the distribution of most values ​​in the sampling area. Secondly, by performing cross-stage feature connection on the original multi-scale feature map, not only the semantic information of the multi-scale feature map is greatly enriched, but also the main network can grasp the deep semantic information when extracting features in the first stage, and can grasp the shallow detail features when fusing shallow features, which greatly enriches the semantic information of the feature map and allows for deeper control of similar defect details. The CSSPPF module not only enhances the expressive power of the multi-scale feature map, but also greatly enriches the semantic information of the feature map, making the model more accurate in detecting similar defects in drainage pipes.

4. The drainage pipe defect detection method based on the improved target detection model according to claim 1 is characterized in that: Step 3 specifically includes: The GAM enables the entire network to suppress complex and irrelevant background information in the pipeline image, highlight the hot spots of pipeline defects in the image, and detect defective objects faster and more accurately.

5. The drainage pipe defect detection method based on the improved target detection model according to claim 1 is characterized in that: Step 4 specifically includes: Adding a fourth detection zone to YOLOv5 and replacing the C3 module with a dense convolutional neural network architecture enables the model to better detect small object defects and further improve detection accuracy; The output of each layer of DenseNet is connected to all previous layers on the data channel and used as the input of the next layer. The output layer uses the BN algorithm to standardize small batches of data. The collaborative output structure of the multi-layer network strengthens the reuse of features, thereby enhancing the detection ability of small objects.