Distribution line unmanned aerial vehicle inspection target identification method fused with multi-feature extraction module

By integrating multiple feature extraction modules, the problem of missed detections due to differences in target scale and low detection accuracy due to complex backgrounds in power distribution line inspections was solved, achieving efficient and accurate target recognition.

CN120997715APending Publication Date: 2025-11-21NANJING AOTU INFORMATION TECH CO LTD
View PDF 5 Cites 0 Cited by

Patent Information

Application Number
CN202511079108.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-08-02
Publication Date
2025-11-21

AI Technical Summary

Technical Problem

Existing technologies for power distribution line inspection suffer from several drawbacks, including large differences in target size leading to missed detections, small targets being prone to being missed, complex backgrounds resulting in low detection accuracy, insufficient feature extraction, and a lack of targeted constraint mechanisms, leading to frequent false detections and multiple detections.

Method used

A multi-feature extraction module approach is adopted, including Mosaic data augmentation, adaptive scaling and minimum black border padding, Focus module, Swin Transformer module, SPP module, BiFPN and CBAM attention modules, CIoU loss function and hierarchical prediction strategy, to construct an object detection model for end-to-end training.

Benefits of technology

It improves the detection accuracy and efficiency of power distribution line inspection, reduces false detections and multiple detections, enhances the generalization performance and robustness of the model, and ensures accurate positioning of small targets.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120997715A_ABST
    Figure CN120997715A_ABST
Patent Text Reader

Abstract

The invention relates to the field of image recognition and data analysis, in particular to a distribution line unmanned aerial vehicle inspection target recognition method fused with a multi-feature extraction module. The method comprises the steps of collecting an unmanned aerial vehicle inspection image containing a distribution line component and a defect target as a training sample, preprocessing the training sample, constructing a target detection model containing a backbone network, a neck network and a detection head, inputting the preprocessed training sample into the model for end-to-end training, and obtaining a target detection result; and loading the trained model for reasoning to output a visual result and the like. The method also relates to various specific operations such as data enhancement, feature extraction, loss function and prediction strategy. According to the method, the technical effects that the distribution line unmanned aerial vehicle inspection target can be identified more accurately and efficiently, the identification precision and effect can be improved through various strategies and modules, and the inspection requirement in a complex scene is met are achieved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of image recognition, in particular to a power distribution line unmanned aerial vehicle inspection target recognition method fusing a multi-feature extraction module. BACKGROUND

[0002] In the field of power distribution line inspection, unmanned aerial vehicles are widely used for image acquisition due to their high flexibility and wide coverage. Target detection (such as identifying cracks in power poles) on the collected images is a key link to ensure the safe operation of power distribution lines. Traditional target detection algorithms have the following problems when processing power distribution line inspection images: first, the scale difference of targets in the image is large, and small targets (such as fine cracks) are prone to be missed; second, the background is complex, with many useless information disturbances, resulting in low detection accuracy; third, the feature extraction is insufficient, and the fusion effect of different levels of features is poor, affecting the accuracy of target positioning; fourth, there is a lack of constraint mechanism for power distribution line scenes, which is prone to false detection and multiple detection.

[0003] To solve the above problems, existing technologies mostly use single feature extraction networks or simple feature fusion methods, which are difficult to balance detection accuracy and efficiency. For example, the traditional feature pyramid network (FPN) has information loss when fusing multi-scale features, and the ordinary convolutional neural network has insufficient ability to capture long-distance dependent features, and no special attention mechanism and constraint strategy are designed for power distribution line images, resulting in unsatisfactory detection effect in actual inspection scenes. Therefore, a target detection technical solution that combines the advantages of multiple modules and is optimized for power distribution line inspection images is needed to improve detection accuracy and efficiency. SUMMARY

[0004] The purpose of the present application is to overcome the above technical problems, and a power distribution line unmanned aerial vehicle inspection target recognition method fusing a multi-feature extraction module is provided.

[0005] The power distribution line unmanned aerial vehicle inspection target recognition method fusing a multi-feature extraction module includes the following steps: S01: Collecting unmanned aerial vehicle inspection images containing power distribution line components and defect targets as training samples; S02: Preprocessing the training samples, including: S02-01: Using the Mosaic data augmentation strategy: randomly selecting 4 power distribution equipment images, respectively scaling, cropping and splicing them into new samples; S02-02: Using adaptive scaling and minimum black edge padding: scaling the image to the longest side of 640px, and symmetrically padding black edges when the shortest side is not enough; S03: Building a target detection model, including: S03-01: Backbone Network: Passed sequentially through the Focus module, the Swin Transformer module, and the SPP module; the Focus module generates four sets of feature maps by sampling at 2×2 pixel intervals and then concatenates them by channel; the Swin Transformer module divides the image into blocks by Patch Partition and uses W-MSA and SW-MSA alternately to extract features; the SPP module fuses multi-scale features by connecting parallel 5×5, 9×9, and 13×13 max pooling layers; S03-02: Neck network: A weighted bidirectional feature pyramid network (BiFPN) with three stacked layers is adopted, and a CBAM attention module is inserted after each fusion path; the CBAM module performs channel attention (global pooling + MLP) and spatial attention (channel pooling + 7×7 convolution) in sequence; S03-03: Detection head: adopts CIoU loss function and implements hierarchical prediction strategy under semantic constraints; S04: Input the preprocessed training samples into the model for end-to-end training; S05: Load the trained model for inference and output a visualization of the detection boxes.

[0006] By employing the above technical solutions, UAV inspection images containing power distribution line components and defective targets are collected as training samples to provide a data foundation for model training. A Mosaic data augmentation strategy is used to allow the model to encounter multi-scale targets and enrich the background within a single image, improving the model's generalization performance and robustness. Adaptive scaling and minimum black border padding are used to scale and pad while maintaining the image's aspect ratio, reducing information loss. The backbone network sequentially passes through a Focus module, a Swin Transformer module, and an SPP module. The Focus module expands the input channels and obtains double-downsampled features while preserving original information, avoiding information loss. The Swin... The Transformer module alternately captures local and global dependencies, while the SPP module fuses multi-scale features to alleviate missed detections. The neck network employs a stacked three-layer weighted bidirectional feature pyramid network with an inserted CBAM attention module. BiFPN enables progressive feature fusion, and the CBAM attention module suppresses redundant information and highlights key features. The detection head uses the CIoU loss function, considers the difference in aspect ratio between the predicted and ground truth boxes, and implements a hierarchical prediction strategy under semantic constraints to improve detection accuracy and interpretability. Preprocessed training samples are input into the model for end-to-end training, enabling the model to learn effective features. The trained model is then loaded for inference, outputting a visualized result with detection boxes to complete the target recognition for UAV inspection of power distribution lines, solving the problem of balancing detection accuracy and efficiency in existing technologies.

[0007] Preferably, the Mosaic data enhancement in S02-01 specifically includes: The random scaling ratio ranges from 0.5 to 1.5 times the original size; The cropped area is not less than 40% of the original image; The four images are arranged in a random grid layout when splicing.

[0008] By adopting the above technical solution, the random scaling ratio ranges from 0.5 to 1.5 times the original size, which can make the model contact more targets of different scales; the cropped area is not less than 40% of the original image, which ensures that enough effective information is retained after cropping; the four images are arranged in a random grid layout when splicing, which greatly enriches the background of the target, and comprehensively improves the generalization performance and robustness of the model.

[0009] Preferably, the operation of the Focus module includes: Pixel sampling is performed on the input image at a fixed interval of 2x2 to generate four groups of feature maps with halved spatial resolution; The four groups of feature maps are spliced along the channel dimension to expand the number of channels from 3 to 12.

[0010] By adopting the above technical solution, in the multi-scale feature extraction of the backbone network, pixel sampling is performed on the input image at a fixed interval of 2x2 to generate four groups of feature maps with halved spatial resolution, which can completely retain all pixel information of the original image; the four groups of feature maps are spliced along the channel dimension to expand the number of channels from 3 to 12, which can effectively expand the input channel while keeping the original information intact, and naturally obtain double down-sampling features through subsequent convolution operations, avoiding the information loss problem that may be caused by traditional down-sampling methods and improving the network processing speed.

[0011] Preferably, the operation of the SPP module includes: The input feature channel number is compressed to C / 2 through 1x1 convolution; Parallelly execute maximum pooling with kernel size of 5, 9, and 13 and step size of 1, and the padding amount is k / / 2 to maintain the output size; After splicing the original feature and the three groups of pooling outputs along the channel dimension, map to the target channel number through 1x1 convolution.

[0012] By adopting the above technical solution, the multi-scale receptive field information is compressed into a fixed channel expression while keeping the spatial resolution of the feature map unchanged, which improves the model's perception ability of defects of different scales; reduces the computational overhead of the subsequent parallel branches; obtains context information of different scales, and fuses multi-scale features to alleviate the missed detection problem caused by large defect size difference and complex background in power distribution line images; and outputs feature maps with details and global semantics.

[0013] Preferably, the construction of the BiFPN comprises: deleting the nodes with only single input edges in the traditional PANet; defining each bidirectional path as a feature network layer, and stacking three layers to realize progressive feature fusion.

[0014] By adopting the above technical solutions, the nodes with only single input edges in the traditional PANet are deleted to form more compact cross-layer connections; each bidirectional path is defined as a feature network layer and three layers are stacked to realize progressive feature fusion, which fully utilizes the multi-level features output by the backbone network and suppresses redundant background information, solves the problems of insufficient feature extraction and poor fusion effect of different levels of features of the traditional target detection algorithm in processing power line inspection images, and improves the detection accuracy and efficiency.

[0015] Preferably, the operation of the CBAM module comprises: channel attention: performing global max-pooling and average-pooling on the input features respectively, and generating channel weights through a shared weight MLP; spatial attention: performing max-pooling and average-pooling on the channel-weighted features along the channel axis, and generating spatial weights through a 7x7 convolution; multiplying the channel weights and the spatial weights element by element to output enhanced features.

[0016] By adopting the above technical solutions, global max-pooling and average-pooling are performed on the input features respectively, and channel weights are generated through a shared weight MLP, which can highlight the importance of different channels to target recognition; max-pooling and average-pooling are performed on the channel-weighted features along the channel axis, and spatial weights are generated through a 7x7 convolution, which can focus on the spatial position of the target; the channel weights and the spatial weights are multiplied element by element to output enhanced features, which can suppress redundant information in the power line image and highlight key features of defects, effectively enhancing the defect area and suppressing background noise.

[0017] Preferably, the CIoU loss function is defined as: The calculation method of the CIoU loss function includes three penalty factors: (1) boundary box overlap penalty term: 1-IoU, where IoU is the intersection over union of the predicted box and the real box; (2) center point distance penalty term: ρ 2 (b,b gt ) / c 2 , where ρ is the Euclidean distance between the center points of the predicted box and the real box, and c is the diagonal length of the minimum bounding rectangle; (3) aspect ratio consistency penalty term: αv, where v=(4 / π 2)[arctan(w gt / h gt )-arctan(w / h)] 2 , a = v / ((1 - IolU) + v); w, h are the width and height of the prediction box, w gt , h gt are the width and height of the real box.

[0018] By adopting the technical scheme, the unmanned aerial vehicle inspection image containing the power distribution line component and defect target is collected as a training sample, preprocessed through a Mosaic data enhancement strategy and adaptive scaling and minimum black edge filling, a backbone network (passing through a Focus module, a Swin Transformer module and an SPP module in sequence), a neck network (adopting a weighted bidirectional feature pyramid network BiFPN stacked for three layers and inserting a CBAM attention module) and a detection head (adopting a CIoU loss function and a hierarchical prediction strategy under semantic constraint) are used to construct a target detection model, the preprocessed sample is input into the model for training, and finally the model is loaded for inference and output of a result. The three penalty factors of the CIoU loss function, the boundary box overlap penalty term can make the overlap of the prediction box and the real box higher, the center point distance penalty term can reduce the distance between the center points of the prediction box and the real box, and the length-width ratio consistency penalty term can make the length-width ratio of the prediction box and the real box more consistent, thereby improving the precision and interpretability of the power distribution line defect detection.

[0019] Preferably, the hierarchical prediction strategy comprises: quantity constraint: limiting the number of detections of each type of defect in a single image; position constraint: detecting the connecting component first and then positioning the small target defect according to the relative position relationship between components; rule constraint: determining the target type to be detected in the image based on component position information.

[0020] By adopting the technical scheme, the quantity constraint can limit the number of detections of each type of defect in a single image, and reduce the false detection and multiple detection; the position constraint can solve the small target detection difficulty by detecting the connecting component first and then positioning the small target defect according to the relative position relationship between components; and the rule constraint can improve the recognition accuracy and efficiency of the power distribution line defects by determining the target type to be detected in the image based on component position information, combining the construction of the backbone network, the neck network and the detection head, and the steps of collecting, preprocessing and model training and inference of the training sample.

[0021] Preferably, the position constraint is specifically implemented as: for insulator defects, the position of the cross arm to which the insulator is attached is detected first, and then the insulator is searched in the coordinate neighborhood of the cross arm; For the conductor broken strand defect, the positions of adjacent power poles are first located, and then the conductor extension area is detected.

[0022] By adopting the above technical solutions, in terms of position constraint, for the insulator defect, the cross arm position is first detected and then the insulator in the neighborhood thereof is searched, which can reduce the detection range and improve the detection efficiency and accuracy of the insulator defect; for the conductor broken strand defect, the positions of adjacent power poles are first located and then the conductor extension area is detected, which can more accurately determine the detection area and improve the recognition effect of the conductor broken strand defect. In combination with the operations of collecting training samples, preprocessing the samples, constructing a target detection model containing a backbone network, a neck network and a detection head, end-to-end training the model and outputting a result, the precision and efficiency of the unmanned aerial vehicle inspection target recognition of the distribution line are overall improved.

[0023] Preferably, in the Swin Transformer module: Patch Partition divides the image into 4x4 non-overlapping blocks; W-MSA calculates self-attention in an 8x8 local window; SW-MSA realizes cross-window information interaction through cyclic shift.

[0024] By adopting the above technical solutions, the Swin Transformer module divides the image into 4x4 non-overlapping blocks to obtain the one-dimensional sequence required by the Transformer; calculates self-attention in an 8x8 local window to capture local dependency relationships; and realizes cross-window information interaction through cyclic shift to capture global dependency relationships, thereby balancing precision and efficiency, adapting to the inspection image task, and improving the recognition effect of the power pole crack target.

[0025] In summary, the present application includes at least one of the following beneficial technical effects: 1. The Mosaic data augmentation strategy and the adaptive scaling and minimum black edge padding strategy are used to preprocess the image, so that the model is exposed to multi-scale targets and rich backgrounds, and the generalization performance and robustness of the model are improved; 2. The backbone network uses Focus, Swin Transformer and SPP modules for multi-scale feature extraction, and the neck network uses a weighted bidirectional feature pyramid network and inserts a CBAM attention module, which fully utilizes multi-level features and suppresses redundant background information, thereby improving target positioning accuracy; 3. The detection head uses the CIoU loss function and implements a hierarchical prediction strategy under semantic constraints, which balances detection accuracy and efficiency and reduces false positives and multiple detections. BRIEF DESCRIPTION OF DRAWINGS

[0026] Figure 1This is a schematic diagram of the Mosaic data augmentation strategy according to an embodiment of this application.

[0027] Figure 2 This is a schematic diagram of the adaptive scaling and minimum black border filling strategy of an embodiment of this application.

[0028] Figure 3 This is a schematic diagram of the model structure of an embodiment of this application.

[0029] Figure 4 This is a schematic diagram of the Focus module in an embodiment of this application.

[0030] Figure 5 This is a schematic diagram of the Swing Transformer feature extraction module in an embodiment of this application.

[0031] Figure 6 This is a schematic diagram of the SPP module in an embodiment of this application.

[0032] Figure 7 This is a schematic diagram of the feature fusion module in an embodiment of this application.

[0033] Figure 8 This is a schematic diagram of the CBAM attention module in an embodiment of this application.

[0034] Figure 9 This is a schematic diagram of the channel attention module in an embodiment of this application.

[0035] Figure 10 This is a schematic diagram of the spatial attention module in an embodiment of this application. Detailed Implementation

[0036] The following is in conjunction with the appendix Figures 1-10 This application will be described in further detail.

[0037] The technical solutions in the embodiments of the present invention will be further described in detail below with reference to the accompanying drawings. The described embodiments are only possible technical implementations of the present invention, but are not limited thereto. Other embodiments obtained by those skilled in the art in conjunction with the embodiments of the present invention without creative effort are also within the protection scope of the present invention.

[0038] This application mainly adopts the steps of collecting inspection images, preprocessing, building models, training and inference, which achieves the effect of improving the accuracy and efficiency of target recognition in power distribution line inspection. The following is a further detailed description of this application.

[0039] The target identification method for power distribution line UAV inspection provided in this application embodiment includes the following steps: S01: Collect UAV inspection images containing power distribution line components and defect targets as training samples; S02: Preprocessing the training samples, including: S02-01: Adopting Mosaic data augmentation strategy: randomly selecting 4 power distribution equipment images, respectively performing random scaling and cropping to splice into new samples; S02-02: Adopting adaptive scaling and minimum black edge padding: scaling the image to the longest side of 640px, and symmetrically padding the black edge when the shortest side is insufficient; S03: Constructing the target detection model, including: S03-01: Backbone network: sequentially passing through Focus module, Swin Transformer module and SPP module; wherein the Focus module generates four groups of feature maps through 2x2 pixel sampling and channel splicing; the Swin Transformer module divides the image blocks through Patch Partition, and alternately uses W-MSA and SW-MSA to extract features; the SPP module fuses multi-scale features through parallel 5x5, 9x9, 13x13 maximum pooling layers; S03-02: Neck network: adopting a weighted bidirectional feature pyramid network (BiFPN) stacked with three layers, and inserting a CBAM attention module after each fusion path; the CBAM module sequentially performs channel attention (global pooling + MLP) and spatial attention (channel pooling + 7x7 convolution); S03-03: Detection head: adopting CIoU loss function, and implementing hierarchical prediction strategy under semantic constraint; S04: Inputting the preprocessed training samples into the model for end-to-end training; S05: Loading the trained model for inference, and outputting the visualized results with detection boxes.

[0040] Through the orderly execution of these steps, the accuracy and efficiency of power line inspection target recognition are improved. This is because collecting images containing power line components and defect targets as training samples provides a rich data basis for model training; preprocessing the samples can enhance the generalization performance and robustness of the model; constructing a target detection model containing backbone network, neck network and detection head can fully extract and fuse image features; model training can enable the model to learn target features; and model inference can output accurate detection results.

[0041] Specifically, in the collecting training samples step, unmanned aerial vehicle inspection images containing power distribution line components and defect targets need to be collected. These images can be obtained by unmanned aerial vehicles during actual power distribution line inspection, and contain various power distribution line components and defect targets, such as power pole cracks, tree barriers, insulator defects, and conductor strand breaks. Collecting these images as training samples can enable the subsequent trained model to better identify various targets in the actual inspection scene.

[0042] Further, the sample preprocessing step includes: Mosaic data enhancement: Randomly extract 4 power distribution equipment images (such as insulators, conductors, towers, etc.); Perform random scaling (scaling range 0.5-1.5 times) and random cropping (cropping area ≥40% of the original image) on each image; Figure 1 Concatenate the processed images into new samples according to a random grid layout, so that a single image contains multiple scale targets and complex backgrounds.

[0043] Referring to Figure 2 Adaptive scaling and minimum black edge filling: Scale the image to the longest side of 640px; If the shortest side is less than 640px, enlarge it to the longest side of 640px while maintaining the aspect ratio; Symmetrically fill black edges on both sides (top and bottom or left and right) of the image using the "minimum principle" to minimize invalid information.

[0044] Referring to Figure 3 In the step of constructing a target detection model, the backbone network sequentially passes through the Focus module, the SwinTransformer module, and the SPP module. The Focus module samples the input image at a fixed interval of 2x2 to generate four groups of feature maps with halved spatial resolution, and then concatenates the four groups of feature maps along the channel dimension to expand the channel number from 3 to 12.

[0045] Referring to Figure 4 The Focus module is described as follows: Focus module: This module aims to improve network processing speed without increasing the index. Its core operation contains two key steps: first, the input image is subsampled by pixels, and 2x2 fixed interval is used for pixel extraction to generate four groups of feature maps with halved spatial resolution; then, these feature maps are spliced along the channel dimension, converting the spatial information (width and height) of the original image into channel dimension information. This operation expands the input channel number from the original three channels (RGB) to twelve channels. It is worth noting that since the sampling process uses a regular interval strategy, all pixel information of the original image is completely retained in the new feature map. This design enables the Focus module to effectively expand the input channel while maintaining the original information without loss, and naturally obtain double down-sampling features through subsequent convolution operations, while avoiding the information loss problem that may be caused by traditional down-sampling methods. Correspondingly, under the premise of maintaining the original information without loss, the input channel is effectively expanded, and double down-sampling features are naturally obtained through subsequent convolution operations, avoiding the information loss problem that may be caused by traditional down-sampling methods.

[0046] Further, referring to Figure 5 , in the Swin Transformer module, Patch Partition divides the image into 4x4 non-overlapping blocks, and each block is linearly projected into a token with a length of C to obtain a one-dimensional sequence required by the Transformer. W-MSA calculates self-attention within an 8x8 local window, and SW-MSA realizes cross-window information interaction through cyclic shift, and uses these two attention mechanisms to alternately capture local and global dependencies. The core computing unit is composed of LayerNorm+W / SW-MSA→LayerNorm→MLP, where the residual connection ensures gradient stability.

[0047] Correspondingly, the specific implementation of the Swin Transformer module is as follows: First, the input feature Figure X ∈R {H×W×C} is input into the CBS (Conv-BN-SiLU) unit for 1x1 convolution, which compresses the channel number to C / 2 to reduce the computational overhead of the subsequent parallel branches.

[0048] Then, three groups of maximum pooling are performed in parallel on the compressed feature map, with kernel sizes of 5, 9, and 13, step sizes of 1, and padding of k / / 2 to ensure that the output size is consistent with the input, thereby obtaining context information with receptive fields of 5x5, 9x9, and 13x13. To preserve the original fine-grained information, the original feature map and the outputs of the three pooling branches are spliced along the channel dimension to obtain a scale-context-rich fusion feature.

[0049] Finally, the channel number is mapped to the target dimension again through a 1x1 CBS convolution, and the feature map with both details and global semantics is output.

[0050] Further, referring to Figure 6 , the SPP module compresses the input feature channel number to C / 2 through a 1x1 convolution, reduces the computational overhead of the subsequent parallel branches, and then performs maximum pooling with a kernel size of 5, 9, and 13 and a step size of 1 in parallel, with a padding amount of k / / 2 to maintain the output size, thereby obtaining context information of 5x5, 9x9, and 13x13 receptive fields. After concatenating the original features and the three groups of pooled outputs along the channel dimension, a 1x1 convolution is performed to map to the target channel number, and a feature map with both details and global semantics is output.

[0051] In addition, referring to Figure 7 , the neck network adopts a stacked three-layer weighted bidirectional feature pyramid network (BiFPN), and a CBAM attention module is inserted after each fusion path. When constructing the BiFPN, the nodes containing only a single input edge in the traditional PANet are deleted to form a more compact cross-layer connection. Each bidirectional path is defined as a feature network layer, and three layers are stacked to achieve progressive feature fusion, which can fully utilize the multi-level features output by the backbone network and suppress redundant background information. The CBAM module sequentially performs channel attention and spatial attention.

[0052] The channel attention performs global maximum pooling and average pooling on the input features respectively, and generates channel weights through a shared weight MLP. The spatial attention performs maximum pooling and average pooling on the channel-weighted features along the channel axis, and generates spatial weights through a 7x7 convolution. The channel weights and spatial weights are multiplied element by element to output enhanced features, which can suppress redundant information in the power distribution line image and highlight key features of defects.

[0053] It should be noted that the traditional PANet only adds one bottom-up path based on the top-down path of the FPN, and there are several nodes with only a single input edge in the topology. Such nodes lack cross-scale feature interaction and have limited contribution to fusion. The present algorithm replaces the PANet with a BiFPN (multi-scale feature fusion). Simply put, the nodes with only one input edge and one output edge are deleted to form a more compact cross-layer connection; secondly, unlike the PANet which has only one top-down and one bottom-up path, the present algorithm regards each bidirectional (top-down and bottom-up) path as a learnable feature network layer L, and the network is stacked with N layers L (N=3 in this paper), realizing progressive fusion.

[0054] Further, referring to Figure 8 and Figure 9To suppress the redundant information and highlight the key features of defects in power distribution line images, a lightweight CBAM attention module is embedded at the end of the backbone network. The module is composed of channel attention and spatial attention: ① Channel attention: the input feature map F∈ R{H×W×C} Global max-pooling and global average-pooling operations are performed respectively to obtain two 1×1×C channel description vectors. The MLP with shared weights first compresses and then expands the channel dimension, and then generates the channel attention weight M C ∈R {1×1× C} after element-wise summation and Sigmoid activation. Figure 10 ② Spatial attention: the channel attention weight M C is combined with the input feature map F to obtain the channel refined feature F', and then the maximum and average pooling operations are performed along the channel axis to generate two H×W×1 spatial description maps. After 7×7 convolution fusion and Sigmoid activation, the spatial attention weight M S ∈R {H×W×1} is obtained. S Finally, M 2 is multiplied with F' pixel by pixel to output a new feature map in which the defect region is significantly enhanced and the background noise is effectively suppressed. Further, the detection head adopts a CIoU loss function, which is defined as: and implements a hierarchical prediction strategy under semantic constraints.

[0055] Specifically, the calculation method of the CIoU loss function includes three penalty factors: a boundary box overlap penalty term 1-IoU, where IoU is the intersection over union of the predicted box and the real box; a center point distance penalty term ρ 2 (b,b gt ) / c 2 , where ρ is the Euclidean distance between the center points of the predicted box and the real box, and c is the diagonal length of the minimum bounding rectangle; a length-width ratio consistency penalty term αv, where v=(4 / π 2 )[arctan(w gt / h gt )-arctan(w / h)] 2 , α=v / ((1-IoU)+v), w and h are the width and height of the predicted box respectively, and w gt and h gt are the width and height of the real box respectively. The hierarchical prediction strategy includes quantity constraint, position constraint and rule constraint.

[0056] Among them, the quantity constraint limits the number of detection of each type of defect in a single image, avoiding false detection and multiple detection. The position constraint detects the connecting components first and then locates the small target defects according to the relative position relationship between components, for example, for insulator defects, the cross arm position attached to the insulator is detected first, and then the insulator is searched in the coordinate neighborhood of the cross arm; for wire breakage defects, the adjacent power pole position is located first, and then the wire extension area is detected. The rule constraint determines the target type to be detected in the image based on the component position information.

[0057] In addition, the model training step is to input the preprocessed training sample into the target detection model for end-to-end training, and a hierarchical prediction strategy based on semantic constraints is adopted in the training process to enable the model to learn the feature information of the target.

[0058] The model inference step is to convert the trained target detection model into inference mode and load the optimal model weight parameters after the model training converges, then input the power distribution line unmanned aerial vehicle inspection image to be detected into the model, and finally generate a visual image containing a detection frame label.

[0059] The implementation principle of the embodiment is that the method constructs a complete power distribution line unmanned aerial vehicle inspection target identification system through a series of steps. Starting from collecting samples, it ensures that the model has enough data to learn. The preprocessing step optimizes the data and improves the adaptability of the model. In the constructed target detection model, the backbone network is responsible for extracting multi-scale features, the neck network performs feature fusion and enhancement, and the detection head performs accurate target prediction. Model training enables the model to continuously learn and optimize, and the model inference outputs the results. The whole process combines a variety of advanced technologies and strategies, effectively solving the problem of difficult to balance detection accuracy and efficiency in the prior art, improving the accuracy and efficiency of power distribution line inspection target identification, and having important significance for ensuring the safe operation of power distribution lines.

[0060] The above are preferred embodiments of the present application, and are not intended to limit the protection scope of the present application, therefore: any equivalent changes made on the structure, shape, principle of the present application should be covered within the protection scope of the present application.

Claims

1. A method for target recognition in UAV inspection of power distribution lines integrating multiple feature extraction modules, characterized in that, Includes the following steps: S01: Collect UAV inspection images containing power distribution line components and defect targets as training samples; S02: Preprocess the training samples, including: S02-01: Mosaic data augmentation strategy is adopted: four images of power distribution equipment are randomly selected, and after random scaling and cropping, they are stitched together to form a new sample; S02-02: Adaptive scaling and minimum black border filling: The image is scaled proportionally to the longest side of 640px, and if it is smaller than the shortest side, black borders are symmetrically filled. S03: Construct an object detection model, including: S03-01: Backbone Network: Passed sequentially through the Focus module, the Swin Transformer module, and the SPP module; the Focus module generates four sets of feature maps by sampling at 2×2 pixel intervals and then concatenates them by channel; the Swin Transformer module divides the image into blocks using PatchPartition and alternately uses W-MSA and SW-MSA to extract features; the SPP module fuses multi-scale features by using parallel 5×5, 9×9, and 13×13 max pooling layers; S03-02: Neck network: A weighted bidirectional feature pyramid network (BiFPN) with three stacked layers is adopted, and a CBAM attention module is inserted after each fusion path; the CBAM module performs channel attention (global pooling + MLP) and spatial attention (channel pooling + 7×7 convolution) in sequence; S03-03: Detection head: adopts CIoU loss function and implements hierarchical prediction strategy under semantic constraints; S04: Input the preprocessed training samples into the model for end-to-end training; S05: Load the trained model for inference and output a visualization of the detection boxes.

2. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 1, characterized in that, The Mosaic data enhancement in S02-01 specifically includes: The random scaling ratio ranges from 0.5 to 1.5 times the original size; The cropped area should be no less than 40% of the original image; The four images are arranged in a random grid layout during stitching.

3. The method for target identification of power distribution line UAV inspection based on the integration of multiple feature extraction modules according to claim 1, characterized in that, The operation of the Focus module includes: The input image is sampled at a fixed interval of 2×2 to generate four sets of feature maps with half the spatial resolution. The four feature maps are spliced ​​along the channel dimension to expand the number of channels from 3 to 12.

4. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 1, characterized in that, The operation of the SPP module includes: The number of input feature channels is compressed to C / 2 using 1×1 convolution; Max pooling with kernel sizes of 5, 9, and 13 and a step size of 1 is performed in parallel, with a fill amount of k / / 2 to maintain the output size; The original features and three sets of pooling outputs are concatenated along the channel dimension and then mapped to the target number of channels via a 1×1 convolution.

5. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 1, characterized in that, The construction of the BiFPN includes: Remove nodes in a traditional PANet that contain only a single input edge; Each bidirectional path is defined as a feature network layer, and three layers are stacked to achieve progressive feature fusion.

6. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 1, characterized in that, The operation of the CBAM module includes: Channel attention: Global max pooling and average pooling are performed on the input features respectively, and channel weights are generated by shared weight MLP; Spatial attention: The channel-weighted features are subjected to max pooling and average pooling along the channel axis, and then spatial weights are generated by 7×7 convolution. The channel weights and spatial weights are multiplied element-wise to output the enhanced features.

7. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 1, characterized in that, The CIoU loss function is defined as follows: The calculation method of the CIoU loss function includes three penalty factors: (1) Bounding box overlap penalty term: 1-IoU, where IoU is the intersection-union ratio of the predicted box and the ground truth box; (2) Center point distance penalty: ρ 2 (b,b gt ) / c 2 , where ρ is the Euclidean distance between the center point of the predicted box and the center point of the ground truth box, and c is the diagonal length of the minimum bounding rectangle; (3) Aspect ratio consistency penalty term: αv, where v=(4 / π) 2 )[arctan(w gt / h gt )-arctan(w / h)] 2 α = v / ((1-IoU)+v); w and h are the width and height of the prediction box, respectively. gt h gt These are the width and height of the actual bounding box, respectively.

8. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 7, characterized in that, The hierarchical prediction strategy includes: Quantity constraint: Limit the number of each type of defect detected in a single image; Positional constraints: Based on the relative positional relationship between components, first inspect the connecting components and then locate the small target defects; Rule constraints: Determine the type of target to be detected in the image based on component location information.

9. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 8, characterized in that, The position constraint is specifically implemented as follows: For insulator defects, first detect the position of the crossarm to which it is attached, and then search for insulators in the neighborhood of the crossarm coordinates; For conductor strand breakage defects, first locate the adjacent utility pole, and then conduct inspection in the conductor extension area.

10. The method for identifying targets in UAV inspection of power distribution lines by integrating multiple feature extraction modules according to claim 1, characterized in that, In the Swin Transformer module: Patch Partition divides the image into 4×4 non-overlapping blocks; W-MSA computes self-attention within an 8×8 local window; SW-MSA enables cross-window information interaction through cyclic shifting.

Citation Information

Patent Citations

  • Method for acquiring salient target of RGB-D image

    CN111242238A

  • Improved YOLOv5 power transmission line aerial image defect detection method

    CN114494908A

  • Power transmission line small target detection method based on improved YOLOv5s

    CN120355893A

  • Method for recognizing distribution network equipment based on raspberry pi multi-scale feature fusion

    US11631238B1

  • Target Detection Method and Apparatus

    US20230045519A1