Electric meter box defect detection method and system based on ICM-YOLO

The ICM-YOLO network quickly and accurately identify the defects of the meter box, which solves the problems of low detection efficiency and high resource consumption in the existing technology, and realizes lightweight meter box defect detection, improving the detection efficiency and accuracy.

CN120339767APending Publication Date: 2025-07-18JIANGSU KAOU WANHONG ELECTRON
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202510402813.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-04-01
Publication Date
2025-07-18

AI Technical Summary

Technical Problem

The existing meter box detection technology is backward, relying on manual inspection efficiency, deep learning neural network models are complex and resource consumption is high, making it difficult to apply in real time on mobile edge computing devices, and lacks efficient intelligent detection solutions.

Method used

Using the ICM-YOLO network, combined with the high-efficiency inverse residual moving module IRMB designed with CNN and Transformer cascade design, the multi-scale feature fusion module CARAFE upsampling operator, and the minimum point distance cross-parameter ratio loss function MPDIoU is used to construct a lightweight meter box defect detection method.

Benefits of technology

It realizes the rapid and accurate identification of meter box defects, reduces model complexity and deployment costs, improves detection efficiency and accuracy, and supports real-time inspection and maintenance.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120339767A_ABST
    Figure CN120339767A_ABST
Patent Text Reader

Abstract

The invention discloses an electric meter box defect detection method, which is characterized in that a YOLOv8 algorithm is used as a basic structure, a backbone network is composed of an efficient multi-scale cascade attention feature extraction network IRMB module, and the parameter quantity and the calculation quantity of a model are remarkably reduced; by using a multi-scale feature fusion module CARAFE up-sampling operator, the focusing capability and the recognition precision of the model under a complex background are improved, a minimum point distance intersection-to-sum ratio loss function MPDIoU is adopted as bounding box loss of the model, the network convergence speed is improved, and the positioning accuracy of a defect target is further enhanced. According to the detection method, defect detection and deep learning are combined, the defect type of the electric meter box is rapidly and accurately identified, subsequent overhaul and maintenance are facilitated, and the maintenance efficiency is improved. According to the ICM-YOLO-based electric meter box defect detection method, the high efficiency, rapidness and accuracy of the detection performance can be ensured, and the complexity and deployment cost of the algorithm can be reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of meter box detection, and in particular designs an electric meter box defect detection method based on ICM-YOLO. Background Art

[0002] Electricity meters are widely used in the field of electricity consumption and are the main metering equipment of power companies. Due to mandatory legislation worldwide in the past few years requiring the use of smart meters, their ownership has reached a considerable scale. As of 2020, the number of smart meters installed in China has grown to 377 million units, and it is expected that by the end of December 2022, the number of smart meters will exceed 650 million. In order to ensure the normal operation of so many smart meters, it is necessary to regularly inspect the meter boxes and smart meters. As the shell of the smart meter, the meter box plays an important role in protecting the equipment. However, since most meter boxes are exposed to the outdoors and have serious problems of over-age use, many meter boxes have varying degrees of damage, resulting in high repair and complaint rates. If the meter box is damaged, it may cause regional power outages, accelerate the aging of smart meter components, leakage, fire and other safety hazards, and easily lead to the occurrence of power theft, thereby causing property losses to the power grid company.

[0003] With the popularization of smart meters, there are nearly 700 million smart meter users in my country. In order to ensure the normal operation of smart meters, it is crucial to detect defects in the meter box to maintain its integrity. The meter box detection technology is backward and not integrated with advanced technology. At present, the detection of meter boxes still mainly relies on manual inspection, but whether it is the detection of meter box defects during the inspection process or the reading of information displayed on the smart meter, the process involves multiple inspection points, and manual inspection is prone to omissions. In addition, professional knowledge is required in the defect inspection process. If ordinary users are asked to report repairs, it is difficult to identify or understand the defect type, which makes it impossible for maintenance personnel to provide targeted maintenance, which also leads to low maintenance efficiency.

[0004] Although some researchers are currently introducing deep learning into automatic image analysis of power equipment, with the continuous pursuit of detection accuracy, the size of deep learning neural network models continues to increase and the structure becomes more and more complex. Along with this, the deep network model has disadvantages such as high power consumption and high computing power requirements, which seriously restricts the application of deep neural networks in mobile edge computing devices with limited resources and real-time online processing. Due to the backwardness of meter box detection technology, from smart meter users to power workers, no efficient and modern intelligent solutions have been established, and traditional detection solutions are still used. Therefore, there is still a need to further improve the existing meter box defect detection method. Summary of the invention

[0005] The technical problem to be solved by the present invention is to provide a defect detection method for an electric meter box, which combines defect detection with deep learning, quickly and accurately identifies the defect types of the electric meter box, facilitates subsequent maintenance and improves the maintenance efficiency in view of the deficiencies of the prior art.

[0006] A defect detection method for an electric meter box based on ICM-YOLO, comprising the following steps: 1) Obtain the appearance image of the electric meter box, classify the appearance graphics of the electric meter box, set the detection label categories, and preprocess the appearance image of the electric meter box to form a labeled image dataset; 2) Construct an ICM-YOLO network, the network includes a Backbone module, a Neck module and a Head module, the Backbone module is used to achieve lightweight dynamic global feature extraction, the Neck module uses the CARAFE upsampling operator for multi-scale feature fusion, and the Head module outputs the detection result; 3) Use the preprocessed image dataset to train the ICM-YOLO network, save the model after evaluating the model performance through the validation set; 4) Deploy the trained ICM-YOLO network to the detection platform to achieve real-time detection and visual interaction of the defects of the electric meter box.

[0007] Preferably, in step 1), the appearance image of the electric meter box is obtained by camera shooting and Internet collection, covering the appearance images of the electric meter box under different scenarios and weather conditions.

[0008] Preferably, the detection label categories in step 1) include box body damage, viewing window damage, seal loss, box body rust, and image integrity defect.

[0009] Preferably, in step 2), the Backbone module uses an efficient inverted residual mobile module IRMB combined with a cascaded design of CNN and Transformer to form a backbone network. The efficient inverted residual mobile module IRMB abstracts a general meta-mobile module MMB according to the inverted residual IRB and the MHSA module and FFN module in the Transformer, and models the general meta-mobile module MMB as a cascade of Expanded Window MHSA (EW-MHSA) and Depthwise Convolution (DWConv), formulated as: F(·)=(DWConv,Skip)(EW-MHSA(·)), and the cascaded module is the efficient inverted residual mobile module IRMB.

[0010] Preferably, in step 2), the CARAFE upsampling operator includes an upsampling kernel prediction module and a feature reorganization module, wherein in the upsampling kernel prediction module, the feature map is subjected to channel compression to reduce the channels of the input feature map, and then the content encoding module takes the compressed feature map as input and encodes the content to generate a reorganized kernel; finally, weights are generated through Softmax normalization processing; in the feature reorganization module composition, feature upsampling is achieved by rearranging the generated features into spatial blocks.

[0011] Preferably, the upsampling kernel prediction module α is based on X l The sub-region predicts a position kernel M for each position l' l' , M l' =α(N(X l ,K encoder )); The feature recombination module α transforms X l Neighborhood and kernel M l' Through weighted combination, the spatial relationship between feature points and the semantic information in the feature map are obtained to produce a more accurate upsampling result, X′ l′ =α(N(X l ,K up ),M l' ).

[0012] Preferably, in step 2), the detection result output by the Head module uses the minimum point distance intersection-over-union loss function MPDIoU as the bounding box loss of the model.

[0013] Preferably, when performing data preprocessing in step 1), the ratio of dividing the training set to the validation set is 8:2.

[0014] Preferably, the model evaluation indicators of step 3) include: accuracy, recall rate, average precision mean, model parameter quantity, volume and floating-point operation quantity.

[0015] The present invention also discloses an electric meter box defect detection system based on ICM-YOLO, which comprises an ICM-YOLO network trained in the above steps.

[0016] The above technical solution has the following beneficial effects: The defect detection method for the electric meter box is based on the YOLOv8 algorithm with high speed and flexibility. The backbone network consists of the IRMB module of the efficient multi-scale cascaded attention feature extraction network, significantly reducing the number of model parameters and computational complexity. By using the CARAFE upsampling operator of the multi-scale feature fusion module, the focusing ability and recognition accuracy of the model in complex backgrounds are improved. The minimum point distance intersection over union loss function MPDIoU is used as the bounding box loss of the model to enhance the network convergence speed and further improve the localization accuracy of defect targets. This detection method combines defect detection with deep learning to quickly and accurately identify the defect types of the electric meter box, facilitating subsequent maintenance and improving maintenance efficiency. The defect detection method for the electric meter box based on ICM-YOLO can not only ensure high efficiency, fast speed, and accurate detection performance, but also reduce the algorithm complexity and deployment cost.

[0017] Aiming at the problem of the imperfect electric meter box defect detection system, the present invention uses the proposed ICM-YOLO network as the core of the detection function to develop a set of detection system platforms, realizing diversified detections.

[0018] To further understand the features and technical content of the present invention, please refer to the following detailed description and diagrams of the present invention. However, the provided diagrams are only for reference and illustration, and are not used to limit the present invention. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 It is a flowchart of the method according to an embodiment of the present invention.

[0020] Figure 2 It is a structural diagram of the ICM-YOLO network according to an embodiment of the present invention.

[0021] Figure 3(a) is a structural diagram of the meta-mobile module MMB according to an embodiment of the present invention.

[0022] Figure 3(b) is a structural diagram of the inverted residual mobile module IRMB according to an embodiment of the present invention.

[0023] Figure 4 It is a structural diagram of the multi-scale feature fusion module CARAFE according to an embodiment of the present invention.

[0024] Figure 5 It is an interface diagram of the detection platform according to an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS

[0025] The following are specific embodiments to illustrate the disclosed embodiments of the present invention. Those skilled in the art can understand the advantages and effects of the present invention from the content disclosed in this specification. The present invention can be implemented or applied through other different specific embodiments, and various details in this specification can also be modified and changed based on different viewpoints and applications without departing from the concept of the present invention. Additionally, the drawings of the present invention are only for simple schematic illustration and are not depicted according to actual dimensions, hereby stating in advance. The following embodiments will further detail the related technical content of the present invention, but the disclosed content is not used to limit the protection scope of the present invention.

[0026] As Figure 1 shown, an embodiment of the present invention provides a method for detecting defects in an electric meter box based on ICM - YOLO, including the following steps:

[0027] Step 1: Obtain an image dataset, classify the appearance graphics of the electric meter box, set the detection label categories, and preprocess the appearance images of the electric meter box to form a labeled image dataset. Images of instrument boxes in different indoor and outdoor scenarios were collected through camera shooting and by gathering Internet pictures, and images of the instrument box were also taken on-site in different outdoor scenarios and different weather conditions. Some similar, incomplete, blurred, and low-quality images were removed through preprocessing, resulting in a high-quality dataset. The appearance graphics of the electric meter box were classified, and the detection label categories were set. The label category defects include: whether the box body is damaged, whether the peephole is damaged, whether the box body seal is missing, whether the box body is rusted, whether the image of the electric meter box is complete, etc. The number of dataset label categories is not less than 10. The dataset was divided according to the ratio of training set: validation set = 8:2.

[0028] Step 2: Construct an ICM - YOLO network based on YOLOv8, including a Backbone module, a Neck module, and a Head module. The ICM - YOLO network structure proposed by the present invention is as Figure 2 shown. In the Backbone module, an efficient inverted residual mobile module IRMB combining CNN and Transformer cascade design is used to form the backbone network. The efficient multi-scale cascade attention feature extraction network IRMB is adopted as the backbone network of the improved model to reduce the computational complexity and improve the detection speed; in the Neck module, the multi-scale feature fusion module CARAFE is used for upsampling operations to improve the focusing ability and recognition accuracy of the network in complex backgrounds; in the Head module, the minimum point distance intersection over union loss function MPDIoU is used as the bounding box loss of the model to improve the network convergence speed and further enhance the localization accuracy of defect targets.

[0029] (1) Inverted residual mobile module backbone network IRMB

[0030] Based on the fact that the inverted residual IRB has similar structural characteristics to the MHSA module and the FFN module in Transformer, a general Meta Mobile Block (MMB) is inductively abstracted, as shown in Fig. 3(a). It instantiates different modules using the dilation rate λ of the feature map and the efficient operator F. The effects of different models mainly come from the specific form of the efficient operator F. Considering lightweight and ease of use, F in MMB is modeled as a cascade of Expanded Window MHSA (EW-MHSA) and Depthwise Convolution (DWConv), formulated as:

[0031] F(·) = (DWConv,Skip)(EW-MHSA(·))(1)

[0032] The cascaded model is called the Inverted Residual Mobile Block (IRMB), as shown in Fig. 3(b). Taking into account the advantages of dynamic global modeling and static local information fusion, it has the lightweight network structure of IRB and the global feature extraction ability of Transformer, so as to ensure that the accuracy of downstream tasks will not be significantly reduced.

[0033] The backbone network used in the present invention consists of four efficient mobile inverted residual modules. IRMB benefits from DW convolution and can perform downsampling operations through Stride. Whether to use MHSA can be adjusted during the training of the IRMB module. Since CNN is more suitable for shallow networks and MHSA is more suitable for deep semantic feature models, MHSA is only used in the last two modules to further enhance the network feature extraction efficiency and reduce the computational amount of the network.

[0034] (2) CARAFE upsampling operator

[0035] The CARAFE structure is as Figure 4 shown, including an upsampling kernel prediction module and a feature recombination module. In the upsampling kernel prediction module, the feature map reduces the channels of the input feature map through channel compression; then, the content encoding module takes the compressed feature map as input and encodes the content to generate a recombination kernel; finally, weights are generated through Softmax normalization. In the composition of the feature recombination module, feature upsampling is achieved by rearranging the generated features into spatial blocks.

[0036] In the calculation process of CARAFE, the upsampling factor is set to δ, and a feature map X with a dimension of C×H×W is input. After processing by CARAFE, an upsampled feature map X' with a dimension of C×δH×δW is obtained. For any target position l'=(x',y') of the feature map X', the corresponding original position l=(x,y) can be found in the feature map X, where x=[x' / δ], y=[y' / δ]. N(X1,K) is defined as the k×k sub-region of the feature map X centered at position l.

[0037] The upsampling kernel prediction module α is based on X l The sub-region predicts a position kernel M for each position l' l' , as shown in formula (2). The feature recombination module α transforms X l Neighborhood and kernel M l' Through weighted combination, the spatial relationship between feature points and the semantic information in the feature map are obtained to produce more accurate upsampling results, as shown in formula (3).

[0038] M l' =α(N(X l ,K encoder )) (2)

[0039] X′ l′ =α(N(X l ,K up ),M l' ) (3)

[0040] The feature fusion network uses the CARAFE operator, which enables the algorithm to obtain more image information, improve the neighboring interpolation method to sample a single convolution kernel for image samples, and obtain an automatically adaptive image sample sampling method, so that the algorithm can focus more on the identification of defect targets.

[0041] (3) MPDIoU minimum point distance intersection-over-union loss function

[0042] In the actual meter box defect detection scenario, the high concentration and serious overlap of some targets lead to a decrease in the bounding box regression rate and regression accuracy during the detection process, resulting in inaccurate positioning of defective targets and missed detection. The performance of the original model's loss function CIoU is limited in this case. Therefore, in order to improve the accuracy of defect detection and accelerate the convergence of the model, the minimum point distance intersection and union loss function MPDIoU is used as the bounding box regression loss of the improved model.

[0043] MPDIoU minimizes the distances between the predicted defective bounding box and the upper-left and lower-right corner points of the true defective annotation box, making the predicted box approach the true box range, simplifies the calculation process, and at the same time comprehensively considers the center point distance, width and height deviations, as well as the overlapping and non-overlapping areas between the boxes, and is more suitable for defective detection scenarios with high target aggregation. Let A and B be any two figures, and w and h be the width and height of the input figure respectively. The MPDIoU calculation formula is:

[0044]

[0045] L MPDIoU = 1 - MPDIoU (7)

[0046] In the formula: respectively represent the upper-left and lower-right corner point coordinates of figure A, respectively represent the upper-left and lower-right corner point coordinates of figure B, d1 and d2 respectively represent the Euclidean distances between the upper-left and lower-right corner points of figure A and B, and L MPDIoU represents the bounding box regression loss function based on the minimum point distance intersection over union.

[0047] Step 3: Use the preprocessed image dataset to train the ICM-YOLO network, evaluate it, and finally save the trained ICM-YOLO network for defective detection of the electric meter box.

[0048] Use the validation set data in step 1) to detect and evaluate the improved algorithm. The experiment uses multiple performance metrics for evaluation, including detection precision AP, recall rate R, mean average precision mAP, the number of model parameters, the volume size of the model, and the number of floating-point operations FLOPs. Among them:

[0049] (1) The precision metric shows the proportion of true targets among the targets detected by the model. Among them, true positive predictions are TP, false positive predictions are FP, and false negative predictions are FN. The formula for precision:

[0050]

[0051] (2) The recall rate metric reflects the proportion of all actual targets successfully detected by the model. The formula for recall rate:

[0052]

[0053] (3) The mean average precision measures the detection accuracy of the model for targets of a specific category, and it is usually determined by calculating the area under the P-R (precision-recall) curve. The formula for mean average precision:

[0054]

[0055] (4) The mean average precision (mAP) represents the average level of AP values for all classes and is used to quantify the overall recognition accuracy of the model.

[0056] The calculation formula for the mean average precision:

[0057]

[0058] Step 4: Develop a defect detection platform for the electricity meter box, deploy the ICM-YOLO network, and achieve real-time detection of the appearance defects of the electricity meter box.

[0059] The present invention uses PySide6 based on Qt to develop the detection platform and uses the QT Designer tool for interface design. The ICM-YOLO network model proposed by the present invention is deployed by converting TensorRT to improve the detection efficiency. The detection interface of the platform is as Figure 5 shown. The interface of the detection platform mainly consists of three parts: a user operation area, a video display area, and a detection display area. The user operation area integrates buttons such as video detection, picture detection, camera detection, open file, confidence setting, and abort. In this area, users can complete operations such as detecting and browsing the files to be detected, equipped with a camera device, can turn on the camera for real-time detection, abort at any time, and the confidence setting can filter out labels below a certain threshold. The results of picture detection and video detection will be presented in the detection display area, and the original pictures and videos will be presented in the video display area for easy comparison and observation. The detection platform allows relevant personnel to perform diversified detections on the image data obtained from the inspected electricity meter box equipment, determine the types of defects, facilitate subsequent maintenance and repair, and eliminate potential safety hazards.

[0060] The electricity meter box defect detection method based on ICM-YOLO proposed by the present invention uses the YOLOv8 algorithm with high speed and high flexibility as the basic structure. The backbone network consists of the IRMB module of an efficient multi-scale cascaded attention feature extraction network, which significantly reduces the number of model parameters and the amount of computation. By using the CARAFE upsampling operator of the multi-scale feature fusion module, the focusing ability and recognition accuracy of the model in complex backgrounds are improved. The minimum point distance intersection over union loss function (MPDIoU) is used as the bounding box loss of the model to improve the network convergence speed and further enhance the localization accuracy of defect targets. The electricity meter box defect detection method based on the ICM-YOLO network combines defect detection with deep learning, quickly and accurately identifies the defect types of the electricity meter box, facilitates subsequent inspection and maintenance, and improves the maintenance efficiency; it can not only ensure high efficiency, fast and accurate detection performance, but also reduce the algorithm complexity and deployment cost.

[0061] The present invention utilizes the proposed ICM-YOLO network as the core of the detection function to develop a set of detection systems for the defects of electric meter boxes, realizing the diversified detection of the appearance defects of electric meter boxes.

[0062] The content disclosed above is only the preferred feasible embodiment of the present invention, and does not limit the scope of the patent application of the present invention. Therefore, all equivalent technical changes made by using the description and drawings of the present invention are included in the scope of the patent application of the present invention.

Claims

1. A method for detecting defects in an electric meter box based on ICM-YOLO, characterized in that, It includes the following steps: 1) Obtain the appearance image of the meter box, distinguish the categories of the appearance graphics of the meter box, set the detection label categories, and preprocess the appearance image of the meter box to form a labeled image dataset; 2) Construct an ICM-YOLO network, which includes a Backbone module, a Neck module, and a Head module. The Backbone module is used to achieve lightweight dynamic global feature extraction. The Neck module uses the CARAFE upsampling operator for multi-scale feature fusion. The Head module outputs the detection results; 3) Use the preprocessed image dataset to train the ICM-YOLO network, save the model after evaluating the model performance through the validation set; 4) Deploy the trained ICM-YOLO network to the detection platform to achieve real-time detection and visual interaction of meter box defects.

2. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 1, wherein, In step 1), the appearance image of the meter box is obtained by camera shooting and Internet collection, covering the appearance images of meter boxes under different scenarios and weather conditions.

3. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 1, characterized in that, The detection label categories in step 1) include box body damage, viewing window damage, seal missing, box body rust, and image integrity defect.

4. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 1, wherein, In step 2), the Backbone module uses an efficient inverted residual mobile module IRMB composed of a cascaded design of CNN and Transformer as the backbone network. The efficient inverted residual mobile module IRMB Abstracts a general meta-mobile module MMB based on the inverted residual IRB and the MHSA module and FFN module in Transformer, and models the general meta-mobile module MMB as Expanded The cascade of Window MHSA (EW-MHSA) and Depthwise Convolution (DWConv) is formulated as: F(·) = (DWConv, Skip)(EW-MHSA(·)), and the cascaded module is the efficient inverted residual mobile module IRMB.

5. The method for defect detection of an electric meter box based on ICM - YOLO according to claim 1, wherein In step 2), the CARAFE upsampling operator includes an upsampling kernel prediction module and a feature recombination module. In the upsampling kernel prediction module, the feature map reduces the channels of the input feature map through channel compression, and then the content encoding module takes the compressed feature map as input and encodes the content to generate a recombined kernel; finally, the weight is generated through Softmax normalization processing; In the composition of the feature recombination module, feature upsampling is achieved by rearranging the generated features into spatial blocks.

6. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 5, wherein, The upsampling kernel prediction module α predicts a location kernel M l ' for each location l' according to a sub-region of X l '. M l ' = α(N(X l , K encoder )); The feature recombination module α combines the neighborhood of X l with the kernel M l ' through weighted combination to obtain the spatial relationship between feature points and the semantic information in the feature map, producing a more accurate upsampling result, X l ” = α(N(X l , K up ), M l ').

7. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 1, characterized in that, In step 2), the Head module outputs the detection results using the minimum point distance intersection over union loss function MPDIoU as the bounding box loss of the model.

8. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 1, wherein When performing data preprocessing in step 1), the ratio of the training set to the validation set is 8:

2.

9. The method for detecting defects in an electric meter box based on ICM-YOLO according to claim 1, wherein, The model evaluation metrics in step 3) include: precision, recall, mean average precision, number of model parameters, volume, and floating-point operation amount.

10. An electric meter box defect detection system based on ICM-YOLO, characterized in that, It includes the trained ICM-YOLO network described in claims 1 to 9.

Citation Information

Cited By

  • Mylar adhesive tape surface defect detection system based on visual identification

    CN122492718A