A meter state identification method of a power distribution cabinet
By using a meter nameplate text recognition model and algorithm in the power distribution cabinet, the meter status is automatically identified, solving the problem of tedious work caused by traditional manual recording and achieving efficient and accurate meter status collection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- GUANGDONG KEYSTAR INTELLIGENCE ROBOT CO LTD
- Filing Date
- 2023-12-29
- Publication Date
- 2026-07-21
AI Technical Summary
In traditional power distribution cabinet equipment, the collection of meter status information relies on manual recording, which leads to tedious work and low efficiency.
The meter nameplate text recognition model and algorithm are adopted to automatically identify the location and name information of the meter nameplate text through image processing technology, determine the meter type, and call the corresponding meter recognition algorithm to obtain the status information.
It reduces the workload of inspection staff, improves work efficiency, and has higher recognition accuracy.
Smart Images

Figure CN117690141B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of meter status identification technology for power distribution cabinets, specifically a method for identifying the meter status of power distribution cabinets. Background Technology
[0002] The distribution cabinets in the power distribution room are equipped with multiple meters. By collecting the status information from these meters, the operating status of the distribution cabinets can be monitored in real time, enabling better control and ensuring the normal operation of the power system in the distribution room. The status information of the meters in the distribution cabinets includes meter readings and indicator light status. During power distribution room inspections, the collection of meter status information from traditional distribution cabinet equipment largely relies on manual recording, which is tedious and inefficient. Summary of the Invention
[0003] To address the aforementioned shortcomings, this invention proposes a method for identifying the status of meters in a power distribution cabinet. The aim is to solve the problem that the collection of meter status information in traditional power distribution cabinet equipment mostly relies on manual recording, which is cumbersome and inefficient.
[0004] To achieve this objective, the present invention adopts the following technical solution:
[0005] A method for identifying the meter status of a power distribution cabinet includes the following steps:
[0006] Step S1: Establish a training dataset, which includes a subset of text detection data and a subset of file recognition data;
[0007] Step S2: Establish a meter nameplate text recognition model. Use the training dataset to train the meter nameplate text recognition model to obtain the trained meter nameplate text recognition model.
[0008] Step S3: Obtain the image of the distribution cabinet to be identified, input the image of the distribution cabinet to be identified into the trained meter nameplate text recognition model, and output the location information and name information of the meter nameplate text in the distribution cabinet image;
[0009] Step S4: Based on the location and name information of the meter nameplate text in the distribution cabinet image, determine the location and type information of the meter corresponding to the meter nameplate in the distribution cabinet image;
[0010] Step S5: Based on the location information of the meter nameplate in the power distribution cabinet image, crop out the image of the meter corresponding to the meter nameplate in the power distribution cabinet image;
[0011] Step S6: Establish a meter identification algorithm library;
[0012] Step S7: Based on the type information of the meter corresponding to the meter nameplate in the distribution cabinet image, determine the meter recognition algorithm corresponding to the meter nameplate in the distribution cabinet image from the meter recognition algorithm library;
[0013] Step S8: Use the meter recognition algorithm to identify the meter corresponding to the meter nameplate in the distribution cabinet image to identify the image of the meter corresponding to the meter nameplate in the distribution cabinet image, and obtain the status information of the meter corresponding to the meter nameplate in the distribution cabinet image.
[0014] Preferably, step S1 specifically includes the following sub-steps:
[0015] Step S11: Obtain images of several power distribution cabinets;
[0016] Step S12: Use the PPOCRLabel tool to label the meter nameplates to be identified in each distribution cabinet image to obtain multiple nameplate frame images;
[0017] Step S13: Create a first blank document and store the images of each nameplate frame in the first blank document to complete the creation of the text detection data subset;
[0018] Step S14: Use the PPOCRLabel tool to annotate the text content of each nameplate frame image to obtain multiple annotated nameplate frame images;
[0019] Step S15: Create a second blank document and store the labeled nameplate frame images in the second blank document to complete the creation of the text recognition data subset.
[0020] Preferably, step S1 further includes the following step:
[0021] The text detection data subset is divided into a text detection training set and a text detection verification set; the text recognition data subset is divided into a text recognition training set and a text recognition verification set.
[0022] Preferably, step S2 specifically includes the following sub-steps:
[0023] Step S21: Establish a text detection sub-model, train the text detection sub-model using the text detection training set, and obtain the trained text detection sub-model;
[0024] Step S22: Establish a text recognition sub-model, train the text recognition sub-model using the text recognition training set, and obtain the trained text recognition sub-model.
[0025] Preferably, step S21 specifically includes the following sub-steps:
[0026] Step S211: Input the nameplate frame images from the text detection training set;
[0027] Step S212: Use the feature pyramid backbone network to extract features from multiple nameplate frame images to obtain feature maps at different scales;
[0028] Step S213: Sample feature maps of different scales to a uniform size to obtain new feature maps of different scales;
[0029] Step S214: Perform adaptive scale fusion on the new feature maps of different scales to obtain text features;
[0030] Step S215: Calculate the probability map and threshold map using text features;
[0031] Step S216: Calculate the approximate binary map using the probability map and the threshold map, and output the approximate binary map.
[0032] Preferably, step S22 specifically includes the following sub-steps:
[0033] Step S221: Input the labeled nameplate frame image from the text recognition training set;
[0034] Step S222: Divide the labeled nameplate frame image into several image patches, where each patch corresponds to each character, and obtain the corresponding embedding vector for each patch through linear transformation;
[0035] Step S223: Extract features from the corresponding embedding vectors using different block modules to obtain features at different scales;
[0036] Step S224: Combine features at different scales to obtain a feature representation;
[0037] Step S225: Input the feature representation into the linear layer, perform feature mapping, obtain the prediction result, and output it.
[0038] Preferably, in step S4, the type information of the meter corresponding to the meter nameplate in the distribution cabinet image is determined based on the name information of the meter nameplate text in the distribution cabinet image, specifically including the following sub-steps:
[0039] Step S41: Establish a meter database, which includes the names and types of different meters;
[0040] Step S42: Determine whether there is a meter in the meter database that matches the text name on the meter nameplate in the distribution cabinet image. If there is, obtain the type of the meter corresponding to the meter nameplate in the distribution cabinet image. If not, add the text name on the meter nameplate in the distribution cabinet image to the meter database and update the meter database.
[0041] The technical solutions provided in this application embodiment may include the following beneficial effects:
[0042] This solution uses a meter nameplate text recognition model to identify the location and name information of the text on the meter nameplate, thereby determining the type of meter corresponding to the nameplate. It then calls the appropriate meter recognition algorithm to accurately and quickly identify the status of the meter corresponding to the nameplate. Compared to manually recording meter status, this meter status recognition method reduces the workload of inspection personnel, improves work efficiency, and offers higher recognition accuracy. Attached Figure Description
[0043] Figure 1 This is a flowchart illustrating the steps of a method for identifying the meter status of a power distribution cabinet. Detailed Implementation
[0044] Embodiments of the present invention are described in detail below. Examples of these embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals denote the same or similar elements or elements having the same or similar functions throughout. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present invention, and should not be construed as limiting the present invention.
[0045] A method for identifying the meter status of a power distribution cabinet includes the following steps:
[0046] Step S1: Establish a training dataset, which includes a subset of text detection data and a subset of file recognition data;
[0047] Step S2: Establish a meter nameplate text recognition model. Use the training dataset to train the meter nameplate text recognition model to obtain the trained meter nameplate text recognition model.
[0048] Step S3: Obtain the image of the distribution cabinet to be identified, input the image of the distribution cabinet to be identified into the trained meter nameplate text recognition model, and output the location information and name information of the meter nameplate text in the distribution cabinet image;
[0049] Step S4: Based on the location and name information of the meter nameplate text in the distribution cabinet image, determine the location and type information of the meter corresponding to the meter nameplate in the distribution cabinet image;
[0050] Step S5: Based on the location information of the meter nameplate in the power distribution cabinet image, crop out the image of the meter corresponding to the meter nameplate in the power distribution cabinet image;
[0051] Step S6: Establish a meter identification algorithm library;
[0052] Step S7: Based on the type information of the meter corresponding to the meter nameplate in the distribution cabinet image, determine the meter recognition algorithm corresponding to the meter nameplate in the distribution cabinet image from the meter recognition algorithm library;
[0053] Step S8: Use the meter recognition algorithm to identify the meter corresponding to the meter nameplate in the distribution cabinet image to identify the image of the meter corresponding to the meter nameplate in the distribution cabinet image, and obtain the status information of the meter corresponding to the meter nameplate in the distribution cabinet image.
[0054] This application provides a method for identifying the meter status of a power distribution cabinet, such as... Figure 1As shown, the first step is to establish a training dataset, which includes a subset of text detection data and a subset of document recognition data. In this embodiment, establishing a training dataset is beneficial for the subsequent training of the meter nameplate text recognition model. The second step is to establish a meter nameplate text recognition model. The training dataset is used to train the meter nameplate text recognition model, resulting in a trained meter nameplate text recognition model. In this embodiment, the meter nameplate text recognition model includes a text detection sub-model and a text recognition sub-model. The text detection sub-model is trained using a subset of text detection data, and the text recognition sub-model is trained using a subset of text recognition data. Training the meter nameplate text recognition model helps improve its recognition accuracy. The third step is to acquire an image of the distribution cabinet to be recognized. The image of the distribution cabinet to be recognized is input into the trained meter nameplate text recognition model, which outputs the location information and name information of the meter nameplate text in the distribution cabinet image. In this embodiment, a camera is used to take real-time photos of the distribution cabinet surface to acquire the distribution cabinet image. During the process of inputting the distribution cabinet image into the trained meter nameplate text recognition model, the text detection sub-model can identify the location information of the meter nameplate text within the distribution cabinet, and the text recognition sub-model can identify the name information within the meter nameplate text. The fourth step is to determine the location and type information of the corresponding meter based on the location and name information of the meter nameplate text in the distribution cabinet image. In this embodiment, there is a certain relationship between the location information of the meter nameplate text and the location information of the corresponding meter; the meter is generally located above the meter nameplate text. Based on this relationship, the location range of the corresponding meter in the distribution cabinet image can be determined. Finally, based on the name information of the meter nameplate corresponding to the meter in the distribution cabinet image, a match is performed from the meter database to determine the meter type information. The fifth step is to crop out the image of the meter corresponding to the meter nameplate in the distribution cabinet image based on the position information of the meter in the meter nameplate. In one embodiment, the "voltage conversion switch" nameplate in the distribution cabinet image is a rectangular frame. The coordinates of the upper left pixel point of the nameplate are (x1, y1) and the coordinates of the lower right pixel point are (x2, y2). Calculations are performed based on these two coordinates, and the specific formulas are as follows: x1' = x1 - a, x2' = x2 + a, y1' = y1 - b, y2' = y2. This results in a new image, which is expanded by 'a' pixels to the left and right and 'b' pixels upward from the nameplate frame. This new image is the image of the meter corresponding to the meter nameplate in the distribution cabinet image. The sixth step is to establish a meter recognition algorithm library. Specifically, the meter recognition algorithm library includes recognition algorithms for various types of meters, and the recognition algorithm for each type of meter is an existing algorithm. The specific establishment steps are as follows: First, create a blank database, and then store the recognition algorithms for each type of meter in this blank database.The seventh step is to determine the meter recognition algorithm corresponding to the meter nameplate in the distribution cabinet image based on the meter type information of the meter in the distribution cabinet image, from the meter recognition algorithm library. In one embodiment, if the type information of the meter corresponding to the meter nameplate in the distribution cabinet image is an pointer-type meter, then the pointer-type meter recognition algorithm is called from the meter recognition algorithm library. The eighth step is to use the meter recognition algorithm corresponding to the meter nameplate in the distribution cabinet image to recognize the image of the meter corresponding to the meter nameplate in the distribution cabinet image, and obtain the status information of the meter corresponding to the meter nameplate in the distribution cabinet image. Specifically, the meter recognition algorithm can accurately identify the working status of the meter.
[0055] This solution uses a meter nameplate text recognition model to identify the location and name information of the text on the meter nameplate, thereby determining the type of meter corresponding to the nameplate. It then calls the appropriate meter recognition algorithm to accurately and quickly identify the status of the meter corresponding to the nameplate. Compared to manually recording meter status, this meter status recognition method reduces the workload of inspection personnel, improves work efficiency, and offers higher recognition accuracy.
[0056] Preferably, step S1 specifically includes the following sub-steps:
[0057] Step S11: Obtain images of several power distribution cabinets;
[0058] Step S12: Use the PPOCRLabel tool to label the meter nameplates to be identified in each distribution cabinet image to obtain multiple nameplate frame images;
[0059] Step S13: Create a first blank document and store the images of each nameplate frame in the first blank document to complete the creation of the text detection data subset;
[0060] Step S14: Use the PPOCRLabel tool to annotate the text content of each nameplate frame image to obtain multiple annotated nameplate frame images;
[0061] Step S15: Create a second blank document and store the labeled nameplate frame images in the second blank document to complete the creation of the text recognition data subset.
[0062] In this embodiment, PPOCRLabel is an open-source, semi-automated image annotation tool suitable for the OCR field. Its exported format can be directly used for training detection and recognition models. The PPOCRLabel tool is used to annotate the meter nameplates to be recognized in each distribution cabinet image. The annotation method involves marking the nameplate frame. The nameplate frame image in the text detection data subset contains the path of the distribution cabinet image and the position information of the nameplate frame within the image. The PPOCRLabel tool is also used to annotate the text content of each nameplate frame image. The annotated nameplate frame image in the text recognition data subset contains the path of the nameplate frame in the distribution cabinet image and the text content information of the nameplate frame.
[0063] Preferably, step S1 further includes the following steps: dividing the text detection data subset into a text detection training set and a text detection verification set; dividing the text recognition data subset into a text recognition training set and a text recognition verification set.
[0064] In this embodiment, the text detection data subset is divided into a text detection training set and a text detection validation set in an 8:2 ratio. The text detection training set is used to train the text detection sub-model, and the text detection validation set is used to adjust the hyperparameters of the text detection sub-model and select the optimal text detection sub-model. Similarly, the text recognition data subset is divided into a text recognition training set and a text recognition validation set in an 8:2 ratio. The text recognition training set is used to train the text recognition sub-model, and the text recognition validation set is used to adjust the hyperparameters of the text recognition sub-model and select the optimal text recognition sub-model.
[0065] Preferably, step S2 specifically includes the following sub-steps:
[0066] Step S21: Establish a text detection sub-model, train the text detection sub-model using the text detection training set, and obtain the trained text detection sub-model;
[0067] Step S22: Establish a text recognition sub-model, train the text recognition sub-model using the text recognition training set, and obtain the trained text recognition sub-model.
[0068] In this embodiment, training the text detection sub-model can improve the accuracy of recognizing the location of the meter nameplate in the distribution cabinet image. Training the text recognition sub-module can improve the accuracy of recognizing the text content of the meter nameplate.
[0069] Preferably, step S21 specifically includes the following sub-steps:
[0070] Step S211: Input the nameplate frame images from the text detection training set;
[0071] Step S212: Use the feature pyramid backbone network to extract features from multiple nameplate frame images to obtain feature maps at different scales;
[0072] Step S213: Sample feature maps of different scales to a uniform size to obtain new feature maps of different scales;
[0073] Step S214: Perform adaptive scale fusion on the new feature maps of different scales to obtain text features;
[0074] Step S215: Calculate the probability map and threshold map using text features;
[0075] Step S216: Calculate the approximate binary map using the probability map and the threshold map, and output the approximate binary map.
[0076] In this embodiment, in step S212, a feature pyramid backbone network is used to extract features from multiple nameplate frame images. The feature pyramid backbone network can extract features at different scales; high-level features can capture the overall structure and context of the image, while low-level features focus more on edges and details. In step S213, feature maps at different scales are sampled to a uniform size, which is beneficial for subsequent adaptive scale fusion. In step S215, the probability map refers to calculating the probability value of each pixel in the input image belonging to a certain target category and mapping these probability values to the corresponding pixel location. The probability map can be used to represent the confidence level of each pixel in the image belonging to the target category. Typically, the pixel values in the probability map range from 0 to 1, representing the probability that the pixel belongs to the target category. The threshold map is an image obtained by binarizing the pixel values in the probability map based on the probability map and a set threshold. The threshold map can be used to determine the location and boundary of the target. Typically, the pixel values in the threshold map are 0 or 1, indicating whether the pixel belongs to the target category. In step S216, the probability map and the threshold map are operated on, that is, the two matrices are operated on and the same position of the two matrices is compared. If the probability value is not less than the threshold, it is 1; if the probability value is less than the threshold, it is 0. Finally, an approximate binary map is output. In the approximate binary map, the pixel with a value of 1 belongs to the pixel of the meter nameplate text, and the pixel with a value of 0 does not belong to the pixel of the meter nameplate text.
[0077] Preferably, step S22 specifically includes the following sub-steps:
[0078] Step S221: Input the labeled nameplate frame image from the text recognition training set;
[0079] Step S222: Divide the labeled nameplate frame image into several image patches, where each patch corresponds to each character, and obtain the corresponding embedding vector for each patch through linear transformation;
[0080] Step S223: Extract features from the corresponding embedding vectors using different block modules to obtain features at different scales;
[0081] Step S224: Combine features at different scales to obtain a feature representation;
[0082] Step S225: Input the feature representation into the linear layer, perform feature mapping, obtain the prediction result, and output it.
[0083] In this embodiment, feature extraction of the embedding vector of each patch is beneficial for identifying the text content in the nameplate frame image.
[0084] Preferably, in step S4, the type information of the meter corresponding to the meter nameplate in the distribution cabinet image is determined based on the name information of the meter nameplate text in the distribution cabinet image. This specifically includes the following sub-steps:
[0085] Step S41: Establish a meter database, which includes the names and types of different meters;
[0086] Step S42: Determine whether there is a meter in the meter database that matches the text name on the meter nameplate in the distribution cabinet image. If there is, obtain the type of the meter corresponding to the meter nameplate in the distribution cabinet image. If not, add the text name on the meter nameplate in the distribution cabinet image to the meter database and update the meter database.
[0087] In this embodiment, establishing a meter database facilitates the archiving and management of different meter names and types. For example, a meter named "A-phase current" can be classified as a pointer ammeter. Based on the name information of the meter nameplate text in the distribution cabinet image, the database is searched for a matching meter type, which facilitates the subsequent use of the corresponding meter identification algorithm.
[0088] Furthermore, the functional units in the various embodiments of the present invention can be integrated into a processing module, or each unit can exist physically separately, or two or more units can be integrated into a module. The integrated module can be implemented in hardware or as a software functional module. If the integrated module is implemented as a software functional module and sold or used as an independent product, it can also be stored in a computer-readable storage medium.
[0089] Although embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present invention. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of the present invention.
Claims
1. A meter state recognition method of a power distribution cabinet, characterized in that: Includes the following steps: Step S1: Establish a training dataset, which includes a subset of text detection data and a subset of file recognition data; Step S2: Establish a meter nameplate text recognition model. Use the training dataset to train the meter nameplate text recognition model to obtain the trained meter nameplate text recognition model. Step S3: Obtain the image of the distribution cabinet to be identified, input the image of the distribution cabinet to be identified into the trained meter nameplate text recognition model, and output the location information and name information of the meter nameplate text in the distribution cabinet image; Step S4: Based on the location and name information of the meter nameplate text in the distribution cabinet image, determine the location and type information of the meter corresponding to the meter nameplate in the distribution cabinet image; Step S5: Based on the location information of the meter nameplate in the power distribution cabinet image, crop out the image of the meter corresponding to the meter nameplate in the power distribution cabinet image; Step S6: Establish a meter identification algorithm library; Step S7: Based on the type information of the meter corresponding to the meter nameplate in the distribution cabinet image, determine the meter recognition algorithm corresponding to the meter nameplate in the distribution cabinet image from the meter recognition algorithm library; Step S8: Use the meter recognition algorithm to identify the meter corresponding to the meter nameplate in the distribution cabinet image to identify the image of the meter corresponding to the meter nameplate in the distribution cabinet image, and obtain the status information of the meter corresponding to the meter nameplate in the distribution cabinet image.
2. The meter state identification method of a power distribution cabinet according to claim 1, characterized in that: Step S1 specifically includes the following sub-steps: Step S11: Obtain images of several power distribution cabinets; Step S12: Use the PPOCRLabel tool to label the meter nameplates to be identified in each distribution cabinet image to obtain multiple nameplate frame images; Step S13: Create a first blank document and store the images of each nameplate frame in the first blank document to complete the creation of the text detection data subset; Step S14: Use the PPOCRLabel tool to annotate the text content of each nameplate frame image to obtain multiple annotated nameplate frame images; Step S15: Create a second blank document and store the labeled nameplate frame images in the second blank document to complete the creation of the text recognition data subset.
3. The method for identifying the meter status of a power distribution cabinet according to claim 2, characterized in that: Step S1 also includes the following steps: The text detection data subset is divided into a text detection training set and a text detection verification set; the text recognition data subset is divided into a text recognition training set and a text recognition verification set.
4. The method for identifying the meter status of a power distribution cabinet according to claim 3, characterized in that: Step S2 specifically includes the following sub-steps: Step S21: Establish a text detection sub-model, train the text detection sub-model using the text detection training set, and obtain the trained text detection sub-model; Step S22: Establish a text recognition sub-model, train the text recognition sub-model using the text recognition training set, and obtain the trained text recognition sub-model.
5. The method for identifying the meter status of a power distribution cabinet according to claim 4, characterized in that: Step S21 specifically includes the following sub-steps: Step S211: Input the nameplate frame images from the text detection training set; Step S212: Use the feature pyramid backbone network to extract features from multiple nameplate frame images to obtain feature maps at different scales; Step S213: Sample feature maps of different scales to a uniform size to obtain new feature maps of different scales; Step S214: Perform adaptive scale fusion on the new feature maps of different scales to obtain text features; Step S215: Calculate the probability map and threshold map using text features; Step S216: Calculate an approximate binary map using the probability map and the threshold map, and output the approximate binary map.
6. The method for identifying the meter status of a power distribution cabinet according to claim 4, characterized in that: Step S22 specifically includes the following sub-steps: Step S221: Input the labeled nameplate frame image from the text recognition training set; Step S222: Divide the labeled nameplate frame image into several image patches, where each patch corresponds to each character, and obtain the corresponding embedding vector for each patch through linear transformation; Step S223: Extract features from the corresponding embedding vectors using different block modules to obtain features at different scales; Step S224: Combine features at different scales to obtain a feature representation; Step S225: Input the feature representation into the linear layer, perform feature mapping, obtain the prediction result, and output it.
7. The method for identifying the meter status of a power distribution cabinet according to claim 1, characterized in that: In step S4, based on the name information of the meter nameplate text in the distribution cabinet image, the type information of the meter corresponding to the meter nameplate in the distribution cabinet image is determined, which specifically includes the following sub-steps: Step S41: Establish a meter database, which includes the names and types of different meters; Step S42: Determine whether there is a meter in the meter database that matches the text name on the meter nameplate in the distribution cabinet image. If there is, obtain the type of the meter corresponding to the meter nameplate in the distribution cabinet image. If not, add the text name on the meter nameplate in the distribution cabinet image to the meter database and update the meter database.