Lightweight target detection and fault identification method, device and system

By designing a lightweight target detection and fault identification method, and using the ShuffleCSP module and the Fuse fusion module to optimize the network model, we solve the problems of large model size and low detection accuracy in traditional methods, and achieve efficient power generation on lightweight devices. Inspection task deployment.

CN113569672BActive Publication Date: 2024-09-10STATE GRID ELECTRIC POWER RES INST +4
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110803857.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-07-16
Publication Date
2024-09-10
Estimated Expiration
2041-07-16

AI Technical Summary

Technical Problem

Traditional UAV power inspection target detection and fault identification methods have the problem of large model size and difficulty in applying on lightweight equipment, resulting in low detection accuracy.

Method used

A lightweight target detection and fault identification method is designed, including feature extraction network, multi-scale fusion network and multi-scale detection head. The ShuffleCSP module and Fuse fusion module are used to reduce the amount of model parameters and optimize the network model to run on lightweight devices. achieve efficient detection.

Benefits of technology

It achieves efficient target detection and fault identification on lightweight devices, with only 5.5M parameters and a mAP of 40.6. It can be easily deployed on CPU-only devices and has high engineering application value.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113569672B
    Figure CN113569672B
Patent Text Reader

Abstract

The present invention discloses a lightweight target detection and fault identification method, device and system, the method comprising obtaining an original lightweight target detection and fault identification network model; optimizing parameters of the original lightweight target detection and fault identification network model to obtain an optimized lightweight target detection and fault identification network model; and performing target detection and fault identification on received power inspection image data using the optimized lightweight target detection and fault identification network model. The present invention realizes a lightweight design of the network to achieve a good compromise between detection rate and detection accuracy.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of image recognition and fault detection applied to power inspection, and specifically relates to a lightweight target detection and fault identification method, device and system. Background Art

[0002] With the development of the national economy and the continuous improvement of people's living standards, the scale of the power grid has continued to expand. The reliable operation of power grid lines and power grid equipment directly affects the production safety and social benefits of power companies. UAV power inspection operations have gradually replaced manual inspection operations, greatly improving inspection efficiency and saving labor costs.

[0003] Traditional methods for target detection and fault identification in drone inspections are generally divided into two steps. The first step is to extract features based on artificially predefined feature extraction methods. After abstracting and analyzing the original data, features used to express the main information of the original data are extracted, such as texture features, color features, contour features, gradient features, motion features, etc.; the second step is to use machine learning methods on the extracted features, such as random forests, support vector machines, and boosting methods. However, artificially defined feature expressions often have some shortcomings and problems. It is difficult to express overly complex data structures, and may not be able to express key information in the original information, resulting in low accuracy. Deep learning is different from traditional machine learning methods. It uses computer autonomous learning to abstract data instead of abstract representation of manually specified data, which improves accuracy. As a typical tool for deep learning, convolutional neural networks are widely used in the field of target detection and recognition. The network structure of convolutional neural networks is complex and has many parameters. The model size generally reaches tens of megabytes or even hundreds of megabytes, which is difficult to apply on lightweight devices. For this reason, there is an urgent need for a target detection and fault identification method that can simultaneously ensure lightweight and detection accuracy. Summary of the invention

[0004] In view of the above problems, the present invention proposes a lightweight target detection and fault identification method, device and system, which can ensure light weight and detection accuracy at the same time, and can facilitate dispatchers to understand the status of transmission lines and perform fault troubleshooting.

[0005] In order to achieve the above technical objectives and the above technical effects, the present invention is implemented through the following technical solutions:

[0006] In a first aspect, the present invention provides a lightweight target detection and fault identification method, comprising:

[0007] Get the original lightweight target detection and fault recognition network model;

[0008] Optimizing parameters of the original lightweight target detection and fault identification network model to obtain an optimized lightweight target detection and fault identification network model;

[0009] The optimized lightweight target detection and fault identification network model is used to perform target detection and fault identification on the received power inspection image data.

[0010] Optionally, the lightweight target detection and fault recognition network model includes a feature extraction network, a multi-scale fusion network and a multi-scale detection head which are arranged in sequence;

[0011] The feature extraction network extracts features from the received image to form a feature map;

[0012] The multi-scale fusion network fuses the feature maps output by the feature extraction network to form a fused feature map;

[0013] The multi-scale detection head outputs the fused feature map.

[0014] Optionally, the feature extraction network includes a Focus module, N sequentially arranged feature extraction blocks and a downsampling convolution layer;

[0015] The Focus module reduces the scale of the received image and expands the number of channels;

[0016] Each feature extraction block extracts features from the input feature map in sequence to form an output feature map, wherein the 1st, 2nd, ... N-1st feature extraction blocks all include 3×3 convolution and ShuffleCSP arranged in sequence, and the Nth feature extraction block includes 3×3 convolution, SPP multi-scale fusion module and ShuffleCSP arranged in sequence, the 3×3 convolution is used for downsampling, the ShuffleCSP is used for feature extraction; the SPP multi-scale fusion module is used for multi-scale fusion;

[0017] The downsampling convolution layer uses a 3×3 convolution kernel to perform feature extraction on the output feature map output by the feature extraction block to obtain an output feature map.

[0018] Optionally, the ShuffleCSP includes two separately arranged Shuffle branches, a CSP branch, and a fusion module;

[0019] The input feature map changes the number of channels through the CSP branch;

[0020] The Shuffle branch includes several stacked ShuffleBlocks; the ShuffleBlock includes a discrete unit mapping module and a feature extraction module, as well as a feature fusion module; the unit mapping module is used to perform unit mapping; the feature extraction module changes the number of channels of the input feature map through 1x1 grouped convolution in sequence, disrupts the channel features through channelshuffle, extracts features through 3x3 depth convolution, and finally changes the number of channels through 1x1 grouped convolution, and the feature fusion module adds the results of the unit mapping module and the feature extraction module and outputs them;

[0021] The fusion module fuses the results of the Shuffle branch and the CSP branch.

[0022] Optionally, the SPP multi-scale fusion module first reduces the number of channels through a 1×1 convolution, then pools the image several times at different scales, and then concatenates and fuses the pooled feature map with the input feature map to complete the combination of the pooled local features and the input global features, and finally changes the number of channels through a 1×1 convolution.

[0023] Optionally, the multi-scale fusion network module includes an up module and a down module;

[0024] The up module includes two cascaded upsampling modules, each of which performs convolution, upsampling, splicing fusion and ShuffleCSP feature extraction operations in sequence;

[0025] The down module includes two cascaded downsampling modules, each of which performs 3×3 convolution, Fuse fusion, and ShuffleCSP feature extraction operations in sequence;

[0026] The input of the multi-scale fusion network module is the feature map output by the feature extraction network. The feature map is first up-sampled twice by the up module to obtain feature maps of three different scales. After each upsampling, the up module will splice and fuse the current feature map with the feature map of the same scale in the feature extraction network; then down-sample twice by the down module to obtain a multi-scale feature map as output. The two downsampling operations are achieved by 3×3 convolutions with a step size of 2. After each downsampling, the down module will fuse the current feature map with the feature map of the same scale in the up module.

[0027] Optionally, the Fuse fusion is specifically:

[0028] Different weights are assigned to feature maps at different stages, and then they are fused element by element.

[0029] Optionally, the multi-scale detection head uses 1×1 convolution on the feature maps output by the multi-scale fusion network module to convert the number of channels into the required number of output feature channels, and finally integrates the detection results of each scale and uses non-maximum suppression NMS for screening to obtain the final detection result.

[0030] In a second aspect, the present invention provides a lightweight target detection and fault identification device, comprising:

[0031] An acquisition module, used to acquire the original lightweight target detection and fault identification network model;

[0032] An optimization module, used for optimizing parameters of the original lightweight target detection and fault recognition network model to obtain an optimized lightweight target detection and fault recognition network model;

[0033] The detection and identification module is used to perform target detection and fault identification on the received power inspection image data using the optimized lightweight target detection and fault identification network model.

[0034] In a third aspect, the present invention provides a lightweight target detection and fault identification system, including a storage medium and a processor;

[0035] The storage medium is used to store instructions;

[0036] The processor is configured to operate according to the instructions to execute the method according to any one of the first aspects.

[0037] Compared with the prior art, the present invention has the following beneficial effects:

[0038] 1) The present invention implements a lightweight target detection and fault identification method. A ShuffleCSP module is designed in the model. Because of the setting of this module, the present invention has the effect of reducing the number of model parameters while ensuring detection performance.

[0039] 2) The Fuse fusion designed by the present invention realizes weighted fusion feature maps, so the network has the effect of accurately measuring the importance of feature maps and improving detection performance.

[0040] 3) The final parameter volume of the lightweight target detection and fault identification network model in the present invention is only 5.5M, and the mAP can reach up to 40.6 on the constructed power inspection dataset. Because the present invention designs a lightweight target detection and fault identification method that can guarantee performance, the power inspection task can be easily deployed on a lightweight device that only contains a CPU, without the need for a GPU, and has a high engineering application value. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] In order to make the content of the present invention more clearly understood, the present invention is further described in detail below based on specific embodiments and in conjunction with the accompanying drawings, wherein:

[0042] Figure 1 A schematic diagram of a flow chart of a lightweight target detection and fault identification method according to an embodiment of the present invention;

[0043] Figure 2 is a network structure diagram of the present invention;

[0044] Figure 3 This is a schematic diagram of the Backbone structure of the feature extraction network;

[0045] Figure 4 This is a schematic diagram of the ShuffleCSP module structure;

[0046] Figure 5 It is a schematic diagram of the Neck structure of the multi-scale fusion network;

[0047] Figure 6 This is the schematic diagram of the Fuse module;

[0048] Figure 7 It is a schematic diagram of the multi-scale detection head structure. DETAILED DESCRIPTION

[0049] In order to make the purpose, technical solution and advantages of the present invention more clear, the present invention is further described in detail below in conjunction with the embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the scope of protection of the present invention.

[0050] The application principle of the present invention is described in detail below in conjunction with the accompanying drawings.

[0051] Example 1

[0052] The embodiment of the present invention provides a lightweight target detection and fault identification method, which can be used for smart grid power inspection scenarios, including the following steps:

[0053] Step (1) obtaining an original lightweight target detection and fault recognition network model;

[0054] Step (2) optimizing the parameters of the original lightweight target detection and fault identification network model to obtain an optimized lightweight target detection and fault identification network model;

[0055] Step (3) uses the optimized lightweight target detection and fault identification network model to perform target detection and fault identification on the received power inspection image data.

[0056] In a specific implementation of the embodiment of the present invention, the following steps are also included before step (1):

[0057] The power inspection scene images are obtained as the original data set. The power inspection scene images are specifically multi-scene and multi-angle transmission line images taken by drone power inspection, including 8 detection categories such as connectors, insulators, poles and towers, shock hammers, lightning arresters, clamps, spacers, and people. The original data set is expanded by manually constructing inspection data under abnormal conditions, including 3 types of abnormal detection categories such as bird nest abnormalities, bird abnormalities, and insulator breakage abnormalities, and manual annotation is performed to form a complete power inspection data set.

[0058] In a specific implementation of the embodiment of the present invention, Figure 2 As shown, the lightweight target detection and fault recognition network model includes a feature extraction network Backbone, a multi-scale fusion network Neck and a multi-scale detection head Head which are arranged in sequence; wherein the feature extraction network extracts features from the received image to form a feature map; the multi-scale fusion network fuses the feature map output by the feature extraction network to form a fused feature map; and the multi-scale detection head outputs the fused feature map.

[0059] like Figure 3 As shown, the feature extraction network Backbone includes a Focus module, N sequentially arranged feature extraction blocks and a downsampling convolution layer;

[0060] The Focus module reduces the scale of the received image and expands the number of channels. In the specific implementation process, the Focus module implements a downsampling function by stacking adjacent features to different channels, reducing the image scale by half while increasing the number of channels to four times the original.

[0061] Each feature extraction block extracts features from the input feature map in turn to form an output feature map, wherein the 1st, 2nd, ... N-1th feature extraction blocks all include 3×3 convolution and ShuffleCSP set in sequence, and the Nth feature extraction block includes 3×3 convolution, SPP multi-scale fusion module and ShuffleCSP set in sequence, wherein the 3×3 convolution sets the stride to 2 for downsampling, and the ShuffleCSP is used for feature extraction, which can realize lightweight and efficient feature extraction; the SPP multi-scale fusion module is used for multi-scale fusion to extract richer features;

[0062] The downsampling convolution layer uses a 3×3 convolution kernel to extract features from the input feature map to obtain an output feature map;

[0063] In summary, the feature extraction network Backbone is downsampled 5 times with a stride of 32.

[0064] like Figure 4 As shown, the ShuffleCSP includes two independently arranged Shuffle branches, a CSP branch and a fusion module;

[0065] The input feature map changes the number of channels through the CSP branch;

[0066] The Shuffle branch includes a plurality of stacked ShuffleBlocks, and the ShuffleBlock includes a unit mapping module, a feature extraction module and a feature fusion module which are separately arranged. The unit mapping module is used for unit mapping; the feature extraction module changes the number of channels of the input feature map through 1x1 grouped convolution in sequence, disrupts the channel features through channelshuffle, extracts features through 3x3 depth convolution, and finally changes the number of channels through 1x1 grouped convolution. The feature fusion module adds the results of the unit mapping module and the feature extraction module and outputs them;

[0067] The fusion module fuses the results of the Shuffle branch and the CSP branch.

[0068] The SPP multi-scale fusion module first reduces the number of channels through a 1×1 convolution, then performs pooling of the image at different scales for several times, and then concatenates and fuses the pooled feature map with the input feature map to achieve the combination of the pooled local features and the input global features, and finally changes the number of channels through a 1×1 convolution.

[0069] like Figure 5 As shown, the multi-scale fusion network module includes an up module and a down module;

[0070] The up module includes two cascaded upsampling modules, each of which performs convolution, upsampling, splicing fusion and ShuffleCSP feature extraction operations in sequence;

[0071] The down module includes two cascaded downsampling modules, each of which performs 3×3 convolution, Fuse fusion, and ShuffleCSP feature extraction operations in sequence;

[0072] The input of the multi-scale fusion network module is the feature map output by the feature extraction network. The feature map is first upsampled twice by the up module to obtain feature maps of three different scales. After each upsampling, the up module will concatenate and fuse the current feature map with the feature map of the same scale in the feature extraction network. Then, it is downsampled twice by the down module to obtain a multi-scale feature map as output. The two downsampling operations are achieved through 3×3 convolutions with a step size of 2. After each downsampling, the down module will fuse the current feature map with the feature map of the same scale in the up module.

[0073] Fuse fusion is achieved through the Fuse module, such as Figure 6 As shown in the figure, the Fuse module assigns different weights to the feature maps of different stages, and then performs element-by-element addition and fusion. From a global perspective, the Fuse module learns a weight for each feature map, that is, it regards all channel features of each feature map as equally important. Fuse is equivalent to paying equal attention to all details in the feature map of each stage, and paying different degrees of attention to the feature maps of different stages, so as to better fuse the features of different stages and different levels, and better combine the location information and semantic information in the image.

[0074] like Figure 7 As shown in FIG, the multi-scale detection head uses 1×1 convolution on the feature maps output by the multi-scale fusion network module to convert the number of channels into the required number of output feature channels. Finally, the detection results of each scale are combined and screened using non-maximum suppression (NMS) to obtain the final detection result. In the specific implementation process, Figure 7 As shown in the figure, the input of the multi-scale detection head is composed of three feature maps of different scales with strides of 8, 16, and 32 respectively derived from the Neck module, forming a multi-scale detection head. 1×1 convolution is used on the three feature maps respectively to convert the number of channels into output dimensions, so as to complete the detection of each scale. Finally, the detection results of each scale are combined and screened by NMS to obtain the final detection result.

[0075] In a specific implementation of the embodiment of the present invention, the step (2) specifically includes the following steps:

[0076] Step S21: Perform preprocessing operations such as data enhancement on the complete power inspection data set, including horizontal flipping, random scaling, HSV color space conversion, and mosaic data enhancement. Mosaic data enhancement is to scale and flip four different images, and then combine them together to input the network. Through mosaic data enhancement, one batch can train four images at the same time. Only a small batch size can achieve the effect of training more images per batch. In the experiment, the batch size is set to 16 and the input image size is 640.

[0077] Step S22: First pre-train on the COCO 2017 dataset released by Microsoft to give the network parameters a better initial distribution, and then perform targeted training on the complete power inspection dataset based on the pre-trained model. The network is pre-trained on COCO for 300 epochs, and then trained on the power inspection dataset for 300 epochs. The optimizer used in training is stochastic gradient descent with momentum (SGDM), the momentum is set to 0.937, the learning strategy is cosine annealing decay, the initial learning rate is 0.01, and the maximum learning rate is 0.2. The loss function of the network is L=l iou +l obj +l cls , where l obj and l cls They represent confidence loss and classification loss respectively, both of which are calculated using binary cross entropy loss; l iou Represents the positioning loss, which is calculated using GIOU. The overall network loss is calculated, and then the loss is back-propagated using the gradient descent method to update and optimize the parameters in the network to obtain the optimal parameter settings.

[0078] Step S23: In order to better perform target detection tasks for power inspection scenarios, 9 prior anchors of different scales are obtained by clustering the labeled target boxes on the complete power inspection dataset. Every 3 anchors are set as a group, divided into three scales: large, medium, and small. The large-scale anchors are assigned to the small-scale feature maps to detect large objects, and the small-scale anchors are assigned to the large-scale feature maps to detect small objects.

[0079] The following experiments are conducted to verify the effects of the network feature extraction network Backbone, the multi-scale fusion network Neck, and the fusion method in the embodiment of the present invention.

[0080] Step A: The evaluation indicators used in the comparative experiment are defined as follows:

[0081] TP is the number of correctly predicted boxes, FN is the number of missed boxes, and FP is the number of incorrectly detected boxes.

[0082] Precision (P): accuracy, the formula is: Recall (R): Recall rate, the formula is:

[0083] PR curve: Precision-Recall curve, the vertical axis is the precision rate Precision, the horizontal axis is the recall rate Recall, as the recall rate increases, the precision rate decreases

[0084] AP is the area under the PR curve, and mAP is the average AP of each category, which measures the average quality of all categories. Params and FLOPs represent the number of parameters and floating-point operations, respectively, and are used to measure the complexity of the network.

[0085] Step B: A comparative experiment was conducted on ShuffleCSP and BottleneckCSP. The results are shown in Table 1.

[0086] Table 1 Backbone experiment comparison

[0087] Backbone mAP <![CDATA[AP 50 ]]> P R Params FLOPs Shuffle 39.5 74.0 68.0 75.8 5.5M 12.8G Bottleneck 39.0 76.9 59.2 78.6 7.6M 17.6G

[0088] From the comparison results in Table 1, it can be found that ShuffleCSP can build a network feature extraction network Backbone to obtain a lighter model and achieve better performance.

[0089] Step C: The present invention mainly considers three commonly used multi-scale fusion modules, namely SPP, PPM, and ASPP, and tests and compares their performances. The results are shown in Table 2.

[0090] Table 2 Performance comparison of multi-scale fusion modules

[0091] Module mAP <![CDATA[AP 50 ]]> P R Params FLOPs SPP 40.6 76.8 66.5 75.7 5.5M 12.8G PPM 39.4 75.8 66.8 75.7 6.1M 14.2G ASPP 40.3 74.8 62.0 77.7 13.8M 19.3G

[0092] From the comparison results in Table 2, it is found that the network with SPP as a multi-scale module has the highest mAP, and the number of parameters and calculations are the smallest; the mAP of ASPP is only 0.3 lower than that of SPP, but the number of parameters and calculations are 2.5 times and 1.5 times of SPP respectively; the mAP of PPM is 1.2 lower than that of SPP, and the number of parameters and calculations are increased. Based on the above experiments, this project uses SPP as the final multi-scale fusion module of the network of the present invention.

[0093] Step D: In the present invention, three different PAN fusion methods are designed, namely Fuse, SEFuse, and GroupFuse. These three fusion methods all introduce adaptive learning fusion methods based on ordinary splicing fusion or element-by-element addition fusion to form an adaptive fusion method. In each fusion operation of PAN, the feature maps are all from the same scale feature maps of Backbone, FPN upsampling stage, and PAN downsampling stage.

[0094] Step D1: Fuse assigns different weights to feature maps at different stages and then performs element-by-element addition and fusion. Fuse learns a weight for each feature map from a global perspective, that is, it regards all channel features of each feature map as equally important. Fuse is equivalent to paying equal attention to all details in the feature map of each stage, and paying different degrees of attention to feature maps at different stages, so as to better fuse features at different stages and levels, and better combine the location information and semantic information in the image.

[0095] Step D2: SEFuse assigns different weights to each channel feature, and the weights can be learned. The specific implementation of SEFuse is to use the SEBlock channel attention module to extract weighted channel features from feature maps at different stages, and then splice and fuse the weighted channel features.

[0096] Step D3: GroupFuse divides the feature maps of each stage into arrays, learns a weight for each group of feature maps, and the number of groups is manually set. The specific implementation of GFuse is to use the GroupAttention grouped channel attention module to extract weighted grouped channel features from the feature maps of different stages, and then perform splicing and fusion. GroupAttention takes into account the interdependence between channel features. From the perspective of channels, it introduces the concept of grouping and groups the channels of feature maps. If the number of groups is g, then g weight parameters are learned for this feature map. These g parameters correspond to g groups respectively. The channel features in each group share a parameter, which is conducive to the communication between features and can also reduce the number of parameters to a certain extent.

[0097] Step D4: Based on the same network structure setting, the present invention conducts a comparative experiment on the three designed PAN fusion modules in the same experimental environment. The comparison results are shown in Table 3.

[0098] Table 3 Performance comparison of PAN fusion modes

[0099] Module mAP AP50 P R Params FLOPs Fuse 40.6 76.8 66.5 75.7 5.5M 12.8G SEFuse 39.9 75.9 64.9 75.8 6.1M 13.6G GroupFuse 40.1 75.2 63.9 76.1 6.2M 13.6G

[0100] Through comparative experiments, it is found that the Fuse module is the best PAN mode, with an mAP of 40.6, and the smallest number of parameters and calculations, 5.5M and 12.8G respectively; the mAP of the SEFuse module is 0.7 lower than that of Fuse, and the number of parameters and calculations are slightly higher than Fuse; the mAP of the GroupFuse module is similar to that of Fuse, but the number of parameters and calculations are also slightly higher than Fuse. Based on the above experiments, using Fuse as the final PAN fusion method can take into account both high accuracy and less parameters and calculations, meeting the requirements of lightweight.

[0101] Example 2

[0102] Based on the same inventive concept as that of Embodiment 1, a lightweight target detection and fault identification device is provided in an embodiment of the present invention, including:

[0103] An acquisition module, used to acquire the original lightweight target detection and fault identification network model;

[0104] An optimization module, used for optimizing parameters of the original lightweight target detection and fault recognition network model to obtain an optimized lightweight target detection and fault recognition network model;

[0105] The detection and identification module is used to perform target detection and fault identification on the received power inspection image data using the optimized lightweight target detection and fault identification network model.

[0106] The rest are the same as in Example 1.

[0107] Example 3

[0108] An embodiment of the present invention provides a lightweight target detection and fault identification system, including a storage medium and a processor;

[0109] The storage medium is used to store instructions;

[0110] The processor is configured to operate according to the instructions to execute the method according to any one of the embodiments 1.

[0111] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.

[0112] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0113] These computer program instructions may also be stored in a computer-readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer-readable memory produce an article of manufacture comprising an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

[0114] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0115] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A lightweight target detection and fault identification method, characterized in that: include: Get the original lightweight target detection and fault recognition network model; Optimizing parameters of the original lightweight target detection and fault identification network model to obtain an optimized lightweight target detection and fault identification network model; Using the optimized lightweight target detection and fault identification network model to perform target detection and fault identification on the received power inspection image data; The original lightweight target detection and fault recognition network model includes a feature extraction network, a multi-scale fusion network and a multi-scale detection head which are arranged in sequence; The feature extraction network extracts features from the received image to form a feature map; The multi-scale fusion network fuses the feature maps output by the feature extraction network to form a fused feature map; The multi-scale detection head outputs the fused feature map; The feature extraction network includes a Focus module, N sequentially arranged feature extraction blocks and a downsampling convolution layer; The Focus module reduces the scale of the received image and expands the number of channels; Each feature extraction block extracts features from the input feature map in sequence to form an output feature map, wherein the 1st, 2nd, ... N-1st feature extraction blocks all include 3×3 convolution and ShuffleCSP arranged in sequence, and the Nth feature extraction block includes 3×3 convolution, SPP multi-scale fusion module and ShuffleCSP arranged in sequence, the 3×3 convolution is used for downsampling, the ShuffleCSP is used for feature extraction; the SPP multi-scale fusion module is used for multi-scale fusion; The downsampling convolution layer uses a 3×3 convolution kernel to perform feature extraction on the output feature map output by the feature extraction block to obtain an output feature map; The ShuffleCSP includes two independently arranged Shuffle branches, a CSP branch, and a fusion module; The input feature map changes the number of channels through the CSP branch; The Shuffle branch includes several stacked ShuffleBlocks; the ShuffleBlock includes a discrete unit mapping module and a feature extraction module, as well as a feature fusion module; the unit mapping module is used to perform unit mapping; the feature extraction module changes the number of channels of the input feature map through 1x1 grouped convolution in sequence, disrupts the channel features through channelshuffle, extracts features through 3x3 depth convolution, and finally changes the number of channels through 1x1 grouped convolution, and the feature fusion module adds the results of the unit mapping module and the feature extraction module and outputs them; The fusion module fuses the results of the Shuffle branch and the CSP branch.

2. A lightweight target detection and fault identification method according to claim 1, characterized in that: The SPP multi-scale fusion module first reduces the number of channels through a 1×1 convolution, then performs pooling of the image at different scales for several times, and then concatenates and fuses the pooled feature map with the input feature map to complete the combination of the pooled local features and the input global features, and finally changes the number of channels through a 1×1 convolution.

3. The lightweight target detection and fault identification method according to claim 1, characterized in that: The multi-scale fusion network includes an up module and a down module; The up module includes two cascaded upsampling modules, each of which performs convolution, upsampling, splicing fusion and ShuffleCSP feature extraction operations in sequence; The down module includes two cascaded downsampling modules, each of which performs 3×3 convolution, Fuse fusion, and ShuffleCSP feature extraction operations in sequence; The input of the multi-scale fusion network is the feature map output by the feature extraction network. The feature map is first upsampled twice by the up module to obtain feature maps of three different scales. After each upsampling, the up module will splice and fuse the current feature map with the feature map of the same scale in the feature extraction network; then downsample twice by the down module to obtain a multi-scale feature map as output. The two downsampling operations are achieved by 3×3 convolutions with a step size of 2. After each downsampling, the down module will fuse the current feature map with the feature map of the same scale in the up module.

4. The lightweight target detection and fault identification method according to claim 3, characterized in that: The Fuse fusion is specifically as follows: Different weights are assigned to feature maps at different stages, and then they are fused element by element.

5. The lightweight target detection and fault identification method according to claim 1, characterized in that: The multi-scale detection head uses 1×1 convolution on the feature maps output by the multi-scale fusion network to convert the number of channels into the required number of output feature channels. Finally, the detection results of each scale are integrated and screened using non-maximum suppression (NMS) to obtain the final detection result.

6. A lightweight target detection and fault identification device, characterized in that: include: An acquisition module, used to acquire the original lightweight target detection and fault identification network model; An optimization module, used for optimizing parameters of the original lightweight target detection and fault recognition network model to obtain an optimized lightweight target detection and fault recognition network model; A detection and identification module, used to perform target detection and fault identification on the received power inspection image data using the optimized lightweight target detection and fault identification network model; The original lightweight target detection and fault recognition network model includes a feature extraction network, a multi-scale fusion network and a multi-scale detection head which are arranged in sequence; The feature extraction network extracts features from the received image to form a feature map; The multi-scale fusion network fuses the feature maps output by the feature extraction network to form a fused feature map; The multi-scale detection head outputs the fused feature map; The feature extraction network includes a Focus module, N sequentially arranged feature extraction blocks and a downsampling convolution layer; The Focus module reduces the scale of the received image and expands the number of channels; Each feature extraction block extracts features from the input feature map in sequence to form an output feature map, wherein the 1st, 2nd, ... N-1st feature extraction blocks all include 3×3 convolution and ShuffleCSP arranged in sequence, and the Nth feature extraction block includes 3×3 convolution, SPP multi-scale fusion module and ShuffleCSP arranged in sequence, the 3×3 convolution is used for downsampling, the ShuffleCSP is used for feature extraction; the SPP multi-scale fusion module is used for multi-scale fusion; The downsampling convolution layer uses a 3×3 convolution kernel to perform feature extraction on the output feature map output by the feature extraction block to obtain an output feature map; The ShuffleCSP includes two independently arranged Shuffle branches, a CSP branch, and a fusion module; The input feature map changes the number of channels through the CSP branch; The Shuffle branch includes several stacked ShuffleBlocks; the ShuffleBlock includes a discrete unit mapping module and a feature extraction module, as well as a feature fusion module; the unit mapping module is used to perform unit mapping; the feature extraction module changes the number of channels of the input feature map through 1x1 grouped convolution in sequence, disrupts the channel features through channelshuffle, extracts features through 3x3 depth convolution, and finally changes the number of channels through 1x1 grouped convolution, and the feature fusion module adds the results of the unit mapping module and the feature extraction module and outputs them; The fusion module fuses the results of the Shuffle branch and the CSP branch.

7. A lightweight target detection and fault identification system, characterized in that: including storage media and processors; The storage medium is used to store instructions; The processor is configured to operate according to the instructions to perform the method according to any one of claims 1-5.