Electric energy meter fault detection method and device based on electric energy meter fault detection model, computer equipment and storage medium
Through the method based on the electric energy meter fault detection model, the feature extraction and training is used for wide-band impedance spectrum data, which solves the problem of low accuracy in the electric energy meter fault detection caused by manual detection, and achieves more efficient and reliable fault detection.
Patent Information
- Application Number
- CN202411333366.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-24
- Publication Date
- 2025-01-10
AI Technical Summary
In the prior art, the detection of power meter faults relies on manual detection, and subjective factors lead to low accuracy, making it difficult to effectively identify power meter faults.
Using the method based on the electric energy meter fault detection model, the wide-band impedance spectrum data of the sample electric energy meter is obtained for feature extraction and data division, the electric energy meter fault detection model is trained, and the trained model is used to detect the detected electric energy meter to improve the detection Accuracy.
No manual intervention is required, which improves the accuracy and efficiency of power meter fault detection, reduces detection errors, and enhances the reliability of power meter fault detection.
Smart Images

Figure CN119293633A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of power grid technology, and in particular to an electric energy meter fault detection method, device, computer equipment, computer-readable storage medium and computer program product based on an electric energy meter fault detection model. Background Art
[0002] In the power system, fault detection of electric energy meters is crucial to ensure the stable operation of the power grid.
[0003] In traditional technology, manual detection is generally used when fault detection is performed on electric energy meters; however, this manual detection method has subjective factors and is prone to errors, resulting in low accuracy in fault detection of electric energy meters. Summary of the invention
[0004] Based on this, it is necessary to provide an electric energy meter fault detection method, device, computer equipment, computer readable storage medium and computer program product based on an electric energy meter fault detection model, which can improve the fault detection accuracy of the electric energy meter in response to the above technical problems.
[0005] In a first aspect, the present application provides an electric energy meter fault detection method based on an electric energy meter fault detection model, comprising:
[0006] Acquiring sample broadband impedance spectrum data associated with a sample electric energy meter;
[0007] Performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data;
[0008] The feature vector is divided according to a preset ratio to obtain a training data set and a verification data set;
[0009] Iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model;
[0010] According to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model;
[0011] In a case where the prediction accuracy is greater than a preset accuracy, the trained electric energy meter fault detection model is used as a trained electric energy meter fault detection model;
[0012] Obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0013] In one embodiment, the iterative training of the electric energy meter fault detection model to be trained according to the training data set to obtain the trained electric energy meter fault detection model includes:
[0014] Obtaining the predicted probability of the actual category information of the training data set through the electric energy meter fault detection model to be trained;
[0015] Determining a target loss value according to the predicted probability;
[0016] According to the target loss value, the electric energy meter fault detection model to be trained is iteratively trained to obtain a trained electric energy meter fault detection model.
[0017] In one embodiment, obtaining the predicted probability of the actual category information of the training data set through the electric energy meter fault detection model to be trained includes:
[0018] Acquire multiple preset data sets corresponding to the electric energy meter fault detection model to be trained, and category information of each preset data set;
[0019] Determining, according to the training data set, each of the preset data sets, and the category information of each of the preset data sets, a plurality of predicted category information of the training data set, and a predicted probability of each of the predicted category information;
[0020] The predicted probabilities of the actual category information of the training data set are screened out from the predicted probabilities of the predicted category information.
[0021] In one embodiment, the step of obtaining sample broadband impedance spectrum data associated with a sample electric energy meter includes:
[0022] obtaining impedance data and phase angle data associated with a sample electric energy meter;
[0023] Preprocessing the impedance data and the phase angle data to obtain preprocessed impedance data and preprocessed phase angle data;
[0024] The preprocessed impedance data and the preprocessed phase angle data are both used as the sample broadband impedance spectrum data.
[0025] In one embodiment, the step of inputting the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected includes:
[0026] Inputting the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain multiple predicted working states of the electric energy meter to be detected and the probability of occurrence of each predicted working state;
[0027] From each of the predicted working states, the predicted working state with the highest probability of occurrence is screened out as the target working state of the electric energy meter to be detected.
[0028] In one embodiment, the feature extraction process is performed on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data, including:
[0029] Acquire the data type of the sample broadband impedance spectrum data;
[0030] Querying the correspondence between the data type and the feature extraction model to obtain the target feature extraction model corresponding to the data type of the sample broadband impedance spectrum data;
[0031] The target feature extraction model is used to perform feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0032] In a second aspect, the present application also provides an electric energy meter fault detection device based on an electric energy meter fault detection model, comprising:
[0033] A data acquisition module, used to acquire sample broadband impedance spectrum data associated with a sample electric energy meter;
[0034] A feature extraction module, used to perform feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data;
[0035] A data partitioning module is used to partition the feature vector according to a preset ratio to obtain a training data set and a verification data set;
[0036] A model training module, used for iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model;
[0037] A model verification module, used to verify the trained electric energy meter fault detection model according to the verification data set to obtain the prediction accuracy of the trained electric energy meter fault detection model;
[0038] A model determination module, configured to use the trained electric energy meter fault detection model as a trained electric energy meter fault detection model when the prediction accuracy is greater than a preset accuracy;
[0039] The model prediction module is used to obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0040] In a third aspect, the present application further provides a computer device, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are implemented:
[0041] Acquiring sample broadband impedance spectrum data associated with a sample electric energy meter;
[0042] Performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data;
[0043] The feature vector is divided according to a preset ratio to obtain a training data set and a verification data set;
[0044] Iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model;
[0045] According to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model;
[0046] In a case where the prediction accuracy is greater than a preset accuracy, the trained electric energy meter fault detection model is used as a trained electric energy meter fault detection model;
[0047] Obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0048] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, wherein when the computer program is executed by a processor, the following steps are implemented:
[0049] Acquiring sample broadband impedance spectrum data associated with a sample electric energy meter;
[0050] Performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data;
[0051] The feature vector is divided according to a preset ratio to obtain a training data set and a verification data set;
[0052] Iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model;
[0053] According to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model;
[0054] In a case where the prediction accuracy is greater than a preset accuracy, the trained electric energy meter fault detection model is used as a trained electric energy meter fault detection model;
[0055] Obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0056] In a fifth aspect, the present application further provides a computer program product, including a computer program, which implements the following steps when executed by a processor:
[0057] Acquiring sample broadband impedance spectrum data associated with a sample electric energy meter;
[0058] Performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data;
[0059] The feature vector is divided according to a preset ratio to obtain a training data set and a verification data set;
[0060] Iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model;
[0061] According to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model;
[0062] In a case where the prediction accuracy is greater than a preset accuracy, the trained electric energy meter fault detection model is used as a trained electric energy meter fault detection model;
[0063] Obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0064] The above-mentioned electric energy meter fault detection method, device, computer equipment, storage medium and computer program product based on the electric energy meter fault detection model first obtain sample broadband impedance spectrum data associated with the sample electric energy meter, and perform feature extraction processing on the sample broadband impedance spectrum data to obtain feature vectors corresponding to the sample broadband impedance spectrum data, and then divide the feature vectors according to a preset ratio to obtain a training data set and a verification data set. Then, according to the training data set, the electric energy meter fault detection model to be trained is iteratively trained to obtain a trained electric energy meter fault detection model. Then, according to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model. When the prediction accuracy is greater than the preset accuracy, the trained electric energy meter fault detection model is used as the trained electric energy meter fault detection model. Finally, the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected is obtained, and the broadband impedance spectrum data to be analyzed is input into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected. In this way, when fault detection is performed on an electric energy meter, the electric energy meter fault detection model is pre-trained by using the sample broadband impedance spectrum data associated with the sample electric energy meter, so that in practical applications, after obtaining the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, the fault detection result of the electric energy meter to be detected can be predicted; secondly, the electric energy meter fault detection model receives new data in each round of iterative training, so as to improve and optimize the model internally, so as to be able to make predictions more effectively, which is beneficial to improving the prediction accuracy of the electric energy meter fault detection model, and thus improving the fault detection accuracy of the electric energy meter; moreover, the entire process does not require human intervention, avoiding the defect of low fault detection accuracy of the electric energy meter caused by subjective factors in manual detection, which is prone to errors, and further improves the fault detection accuracy of the electric energy meter. BRIEF DESCRIPTION OF THE DRAWINGS
[0065] In order to more clearly illustrate the technical solutions in the embodiments of the present application or related technologies, the drawings required for use in the embodiments of the present application or related technical descriptions will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.
[0066] Figure 1 It is a flowchart of an electric energy meter fault detection method based on an electric energy meter fault detection model in one embodiment;
[0067] Figure 2 is a flow chart of an electric energy meter fault detection method based on an electric energy meter fault detection model in another embodiment;
[0068] Figure 3 A schematic diagram of a flow chart of an electric energy meter fault detection method based on broadband impedance data in one embodiment;
[0069] Figure 4 A schematic diagram of a flow chart of an electric energy meter fault detection method based on broadband impedance data in another embodiment;
[0070] Figure 5 A schematic diagram of the accuracy of a PNN neural network on a validation set in one embodiment;
[0071] Figure 6 A schematic diagram of a PNN neural network loss rate curve in one embodiment;
[0072] Figure 7 is a structural block diagram of an electric energy meter fault detection device based on an electric energy meter fault detection model in one embodiment;
[0073] Figure 8 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0074] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0075] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with relevant regulations.
[0076] In an exemplary embodiment, Figure 1 As shown, a method for detecting an electric energy meter fault based on an electric energy meter fault detection model is provided. This embodiment uses the method applied to a server as an example for illustration; it can be understood that the method can also be applied to a terminal, and can also be applied to a system including a terminal and a server, and is implemented through the interaction between the terminal and the server. Among them, the terminal can be, but is not limited to, various personal computers, laptops, smart phones, and tablet computers; the server can be implemented with an independent server or a server cluster consisting of multiple servers. In this embodiment, the method includes the following steps:
[0077] Step S101, obtaining sample broadband impedance spectrum data associated with a sample electric energy meter.
[0078] The sample electric energy meter refers to the electric energy meter used to train the electric energy meter fault detection model.
[0079] The sample broadband impedance spectrum data refers to broadband impedance spectrum data used to train the electric energy meter fault detection model, including impedance data and phase angle data.
[0080] Exemplarily, in response to a model training instruction for an electricity meter fault detection model, the server sends signals of different frequencies to a sample electricity meter through an impedance tester; then, the server collects impedance data and phase angle data of all exposed ports of the sample electricity meter at different frequencies, and uses both the impedance data and phase angle data as sample broadband impedance spectrum data associated with the sample electricity meter.
[0081] Step S102, performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0082] The feature extraction process refers to a process of obtaining a feature vector corresponding to the sample broadband impedance spectrum data based on the sample broadband impedance spectrum data.
[0083] The eigenvector is used to represent the characterization vector of the sample broadband impedance spectrum data.
[0084] Exemplarily, the server determines a target feature extraction model corresponding to the sample broadband impedance spectrum data; then, the server inputs the sample broadband impedance spectrum data into the target feature extraction model corresponding to the sample broadband impedance spectrum data, and performs feature extraction processing on the sample broadband impedance spectrum data through the target feature extraction model corresponding to the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0085] Step S103, dividing the feature vector according to a preset ratio to obtain a training data set and a verification data set.
[0086] The preset ratio refers to a preset ratio value, which is used to indicate the ratio of the training data set to the validation data set.
[0087] The training data set refers to a data set corresponding to adjusting the model parameters of the electric energy meter fault detection model.
[0088] The validation data set refers to a data set corresponding to the model performance of the electric energy meter fault detection model.
[0089] Exemplarily, the server divides the feature vectors according to a preset ratio to obtain a training data set and a verification data set; for example, the server uses 80% of the feature vectors as a training data set and 20% of the feature vectors as a verification data set according to a ratio of 80% and 20%.
[0090] Step S104: iteratively train the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model.
[0091] The electric energy meter fault detection model refers to a network model that can utilize broadband impedance spectrum data of the electric energy meter to obtain a fault detection result of the electric energy meter, such as a PNN (Probabilistic Neural Network) model.
[0092] Exemplarily, the server adjusts the model parameters of the electric energy meter fault detection model to be trained according to the training data set to obtain the electric energy meter fault detection model after the model parameters are adjusted; when the electric energy meter fault detection model after the model parameters are adjusted meets the preset conditions (for example, the obtained loss value is less than the preset loss value), the electric energy meter fault detection model after the model parameters are adjusted is used as the trained electric energy meter fault detection model.
[0093] Step S105, verifying the trained electric energy meter fault detection model according to the verification data set to obtain the prediction accuracy of the trained electric energy meter fault detection model.
[0094] Among them, the prediction accuracy is used to characterize the proportion of the number of successful samples corresponding to the prediction of the trained electric energy meter fault detection model to the total number of samples.
[0095] Exemplarily, the server verifies the trained electricity meter fault detection model based on a verification data set to obtain the number of successful identifications and the number of misdiagnoses of the trained electricity meter fault detection model; then, the server determines the prediction accuracy of the trained electricity meter fault detection model according to the corresponding relationship of "prediction accuracy = number of successful identifications / (number of successful identifications + number of misdiagnoses)".
[0096] Step S106, when the prediction accuracy is greater than the preset accuracy, the trained electric energy meter fault detection model is used as the trained electric energy meter fault detection model.
[0097] The preset accuracy rate refers to a preset accuracy rate threshold value, which is used to judge the prediction accuracy rate, such as 95%.
[0098] Exemplarily, when the prediction accuracy is greater than the preset accuracy, the server uses the trained electricity meter fault detection model as the trained electricity meter fault detection model; when the prediction accuracy is less than or equal to the preset accuracy, the trained electricity meter fault detection model is trained again until the prediction accuracy of the trained electricity meter fault detection model is greater than the preset accuracy.
[0099] Step S107, obtaining the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and inputting the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0100] The electric energy meter to be detected refers to an electric energy meter that needs to be fault-detected.
[0101] The broadband impedance spectrum data to be analyzed refers to broadband impedance spectrum data that needs to be analyzed.
[0102] The target working state refers to the state information of the electric energy meter to be detected, such as normal or abnormal.
[0103] The fault detection result is used to indicate the fault detection condition of the electric energy meter to be detected.
[0104] Exemplarily, in response to a fault detection instruction for an electric energy meter to be detected, the server obtains impedance data and phase angle data of the electric energy meter to be detected from a database, both of which are used as wide-band impedance spectrum data to be analyzed associated with the electric energy meter to be detected; then, the server inputs the wide-band impedance spectrum data to be analyzed into a trained electric energy meter fault detection model, and obtains the target working state of the electric energy meter to be detected through the trained electric energy meter fault detection model; then, the server uses the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0105] In the above-mentioned electric energy meter fault detection method based on the electric energy meter fault detection model, firstly, sample broadband impedance spectrum data associated with the sample electric energy meter is obtained, and feature extraction processing is performed on the sample broadband impedance spectrum data to obtain feature vectors corresponding to the sample broadband impedance spectrum data, and then the feature vectors are divided and processed according to a preset ratio to obtain a training data set and a verification data set. Then, according to the training data set, the electric energy meter fault detection model to be trained is iteratively trained to obtain a trained electric energy meter fault detection model. Then, according to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model. When the prediction accuracy is greater than the preset accuracy, the trained electric energy meter fault detection model is used as the trained electric energy meter fault detection model. Finally, the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected is obtained, and the broadband impedance spectrum data to be analyzed is input into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected. In this way, when fault detection is performed on an electric energy meter, the electric energy meter fault detection model is pre-trained by using the sample broadband impedance spectrum data associated with the sample electric energy meter, so that in practical applications, after obtaining the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, the fault detection result of the electric energy meter to be detected can be predicted; secondly, the electric energy meter fault detection model receives new data in each round of iterative training, so as to improve and optimize the model internally, so as to be able to make predictions more effectively, which is beneficial to improving the prediction accuracy of the electric energy meter fault detection model, and thus improving the fault detection accuracy of the electric energy meter; moreover, the entire process does not require human intervention, avoiding the defect of low fault detection accuracy of the electric energy meter caused by subjective factors in manual detection, which is prone to errors, and further improves the fault detection accuracy of the electric energy meter.
[0106] In an exemplary embodiment, the above step S104, based on the training data set, iteratively trains the electric energy meter fault detection model to be trained to obtain the trained electric energy meter fault detection model, specifically including the following contents: obtaining the predicted probability of the actual category information of the training data set through the electric energy meter fault detection model to be trained; determining the target loss value based on the predicted probability; and iteratively trains the electric energy meter fault detection model to be trained based on the target loss value to obtain the trained electric energy meter fault detection model.
[0107] The actual category information refers to the actual value corresponding to the category information to which the training data set belongs.
[0108] Among them, the prediction probability is used to represent the possibility that the electric energy meter fault detection model determines that the training data set belongs to the actual category information.
[0109] The target loss value is used to represent the difference between the model's predicted value and the actual value.
[0110] Exemplarily, the server obtains the predicted probability of actual category information of the training data set through the electric energy meter fault detection model to be trained; then, the server determines the loss value corresponding to the predicted probability according to the predicted probability as the target loss value; then, the server adjusts the model parameters of the electric energy meter fault detection model to be trained according to the target loss value; then, the server re-trains the electric energy meter fault detection model after the model parameters are adjusted, until the target loss value obtained by the electric energy meter fault detection model after the model parameters are adjusted is less than the loss value threshold, then the training is stopped, and the electric energy meter fault detection model after the model parameters are adjusted is used as the trained electric energy meter fault detection model.
[0111] For example, the server can determine the target loss value by the following formula:
[0112] , formula (1)
[0113] Among them, Loss refers to the target loss value, Refers to the predicted probability of the actual category information of the training data set.
[0114] In this embodiment, the target loss value is determined according to the predicted probability, and iterative training is performed, so that the electric energy meter fault detection model can continuously adjust its own parameters to better fit the training data; moreover, in each iteration, the electric energy meter fault detection model is optimized in the direction of reducing the loss value, which is conducive to gradually improving the prediction accuracy of the electric energy meter fault detection model.
[0115] In an exemplary embodiment, the predicted probability of actual category information of a training data set is obtained through an electric energy meter fault detection model to be trained, specifically including the following contents: obtaining multiple preset data sets corresponding to the electric energy meter fault detection model to be trained, and category information of each preset data set; determining multiple predicted category information of the training data set and the predicted probability of each predicted category information according to the training data set, each preset data set, and category information of each preset data set; and screening out the predicted probability of actual category information of the training data set from the predicted probabilities of each predicted category information.
[0116] The preset data set refers to a pre-set data set.
[0117] The category information of each preset data set is used to indicate the category information to which each preset data set belongs. For example, the category information of preset data set A is category a, and the category information of preset data set B is category b.
[0118] The predicted category information refers to the predicted value corresponding to the category information to which the training data set belongs.
[0119] Exemplarily, the server obtains multiple preset data sets corresponding to the electric energy meter fault detection model to be trained, and category information of each preset data set from a database; then, the server obtains the number of categories corresponding to the category information of each preset data set, and determines multiple prediction category information of the training data set and the prediction probability of each prediction category information according to the training data set, each preset data set, the category information of each preset data set, and the number of categories corresponding to the category information of each preset data set; then, the server normalizes the prediction probability of each prediction category information to obtain the processed prediction probability of each prediction category information; then, the server filters out the processed prediction probability of the actual category information of the training data set from the processed prediction probability of each prediction category information as the prediction probability of the actual category information of the training data set.
[0120] For example, the server may determine the prediction probability of each prediction category information by the following formula:
[0121] , formula (2)
[0122] in, refers to the predicted category information, is the training dataset, It means belonging to the category The preset data set, j refers to the category The number of preset data sets corresponding to Yes Category The number of categories, d refers to the dimension information of the training data set, It refers to the smoothing parameter of the preset Gaussian kernel function.
[0123] For example, the server can obtain the processed prediction probability of each prediction category information through the following formula:
[0124] , formula (3)
[0125] in, is the predicted probability after processing, Category C i The prior probability of Category C j The prior probability of .
[0126] In this embodiment, by making full use of multiple preset data sets, the problem of insufficient or one-sided data in a single data set is avoided. By integrating multiple data sets for training, the model can be continuously updated and expanded, thereby adapting to the ever-changing needs of electricity meter fault detection, which is conducive to improving the prediction accuracy of the electricity meter fault detection model.
[0127] In an exemplary embodiment, the above-mentioned step S101, obtaining sample broadband impedance spectrum data associated with the sample electric energy meter, specifically includes the following contents: obtaining impedance data and phase angle data associated with the sample electric energy meter; preprocessing the impedance data and phase angle data to obtain preprocessed impedance data and preprocessed phase angle data; and using the preprocessed impedance data and preprocessed phase angle data as sample broadband impedance spectrum data.
[0128] The impedance data refers to the impedance value output by the sample electric energy meter.
[0129] The phase angle data refers to the phase angle value output by the sample electric energy meter.
[0130] The preprocessed impedance data refers to the impedance data after preprocessing.
[0131] The preprocessed phase angle data refers to the phase angle data after preprocessing.
[0132] Exemplarily, the server performs an impedance experiment on a sample electric energy meter to obtain impedance data associated with the sample electric energy meter, and performs a phase angle experiment on the sample electric energy meter to obtain phase angle data associated with the sample electric energy meter; then, the server preprocesses the impedance data and the phase angle data to obtain preprocessed impedance data and preprocessed phase angle data; for example, the server identifies abnormal values in the impedance data and the phase angle data, and deletes these abnormal values to obtain preprocessed impedance data and preprocessed phase angle data; then, the server uses the preprocessed impedance data and the preprocessed phase angle data as sample broadband impedance spectrum data.
[0133] In this embodiment, by simultaneously acquiring the impedance data and phase angle data of the electric energy meter, the performance of the electric energy meter can be evaluated from multiple angles, providing a data basis for subsequent analysis; moreover, by preprocessing the data, noise and interference factors in the data can be removed, which is beneficial to improving the data quality of the sample broadband impedance spectrum data and facilitating subsequent analysis and processing.
[0134] In an exemplary embodiment, the above-mentioned step S107, inputting the wide-band impedance spectrum data to be analyzed into a trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected, specifically includes the following contents: inputting the wide-band impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain multiple predicted working states of the electric energy meter to be detected, and the probability of occurrence of each predicted working state; from each predicted working state, screening out the predicted working state with the highest probability of occurrence as the target working state of the electric energy meter to be detected.
[0135] The predicted working state refers to the predicted value corresponding to the working state in the electric energy meter to be tested.
[0136] The occurrence probability refers to the possibility that the electric energy meter to be detected fails as determined by the electric energy meter fault detection model.
[0137] Exemplarily, the server inputs the wide-band impedance spectrum data to be analyzed into a trained electric energy meter fault detection model to obtain multiple predicted working states of the electric energy meter to be detected, and the probability of occurrence of each predicted working state; then, the server sorts each predicted working state according to the probability of occurrence of each predicted working state to obtain the sorted predicted working state; then, the server selects the predicted working state with the highest probability of occurrence from the sorted predicted working states as the target working state of the electric energy meter to be detected.
[0138] In this embodiment, by analyzing multiple predicted working states of the electric energy meter to be tested and the probability of occurrence of each predicted working state, the types of possible faults in the electric energy meter can be comprehensively analyzed; moreover, the predicted working state with the highest probability of occurrence is used as the target working state, so that the focus can be quickly on the part most likely to fail, which is conducive to improving the efficiency of determining the target working state.
[0139] In an exemplary embodiment, the above step S102, performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data, specifically includes the following contents: obtaining the data type of the sample broadband impedance spectrum data; querying the correspondence between the data type and the feature extraction model to obtain a target feature extraction model corresponding to the data type of the sample broadband impedance spectrum data; performing feature extraction processing on the sample broadband impedance spectrum data through the target feature extraction model to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0140] The data type refers to the data category of the sample broadband impedance spectrum data, such as continuous data, discrete data, and time series data.
[0141] The correspondence between data types and feature extraction models is used to characterize the association information between data types and feature extraction models. For example, the feature extraction model corresponding to continuous data and discrete data is the t-SNE (t-Distributed Stochastic Neighbor Embedding, nonlinear dimensionality reduction) model, and the feature extraction model corresponding to time series data is the LSTM (Long Short-Term Memory, long short-term memory network) model.
[0142] The target feature extraction model refers to a feature extraction model corresponding to the data type of the sample broadband impedance spectrum data.
[0143] Exemplarily, the server improves a machine learning algorithm (such as an unsupervised learning algorithm, a time series analysis algorithm) to identify the data type of the sample broadband impedance spectrum data; then, the server queries the correspondence between the data type and the feature extraction model according to the data type of the sample broadband impedance spectrum data, and obtains a feature extraction model corresponding to the data type of the sample broadband impedance spectrum data as a target feature extraction model; then, the server inputs the sample broadband impedance spectrum data into the target feature extraction model, and performs feature extraction processing on the sample broadband impedance spectrum data through the target feature extraction model to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0144] In this embodiment, improving the target feature extraction model corresponding to the data type of the sample broadband impedance spectrum data is equivalent to matching the most suitable feature extraction model for the sample broadband impedance spectrum data, so that the data can be processed and effective feature vectors can be extracted in a relatively short time, which is conducive to improving the efficiency of determining the feature vector corresponding to the sample broadband impedance spectrum data.
[0145] In an exemplary embodiment, Figure 2 As shown, another electric energy meter fault detection method based on the electric energy meter fault detection model is provided, and the method is applied to a server as an example for explanation, including the following steps:
[0146] Step S201, obtaining impedance data and phase angle data associated with a sample electric energy meter; preprocessing the impedance data and phase angle data to obtain preprocessed impedance data and preprocessed phase angle data; and using the preprocessed impedance data and preprocessed phase angle data as sample broadband impedance spectrum data.
[0147] Step S202, obtaining the data type of the sample broadband impedance spectrum data; querying the correspondence between the data type and the feature extraction model to obtain the target feature extraction model corresponding to the data type of the sample broadband impedance spectrum data; performing feature extraction processing on the sample broadband impedance spectrum data through the target feature extraction model to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0148] Step S203: divide the feature vector according to a preset ratio to obtain a training data set and a verification data set.
[0149] Step S204, obtaining multiple preset data sets corresponding to the electric energy meter fault detection model to be trained, and category information of each preset data set.
[0150] Step S205 , determining a plurality of predicted category information of the training data set and a predicted probability of each predicted category information according to the training data set, each preset data set, and the category information of each preset data set.
[0151] Step S206, filtering out the prediction probability of the actual category information of the training data set from the prediction probabilities of each prediction category information.
[0152] Step S207, determining a target loss value according to the predicted probability; and iteratively training the electric energy meter fault detection model to be trained according to the target loss value to obtain a trained electric energy meter fault detection model.
[0153] Step S208, verifying the trained electric energy meter fault detection model according to the verification data set to obtain the prediction accuracy of the trained electric energy meter fault detection model.
[0154] Step S209, when the prediction accuracy is greater than the preset accuracy, the trained electric energy meter fault detection model is used as the trained electric energy meter fault detection model.
[0155] Step S210, obtaining broadband impedance spectrum data to be analyzed that is associated with the electric energy meter to be detected.
[0156] Step S211, input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain multiple predicted working states of the electric energy meter to be detected and the probability of occurrence of each predicted working state; from each predicted working state, select the predicted working state with the highest probability of occurrence as the target working state of the electric energy meter to be detected.
[0157] Step S212: taking the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0158] In the above-mentioned electric energy meter fault detection method based on the electric energy meter fault detection model, when the electric energy meter is fault detected, the electric energy meter fault detection model is pre-trained by using the sample broadband impedance spectrum data associated with the sample electric energy meter, so that in practical applications, after obtaining the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, the fault detection result of the electric energy meter to be detected can be predicted; secondly, the electric energy meter fault detection model receives new data in each round of iterative training, so as to improve and optimize the internal model, so as to be able to predict more effectively, which is beneficial to improve the prediction accuracy of the electric energy meter fault detection model, and thus improve the fault detection accuracy of the electric energy meter; moreover, the whole process does not require human intervention, avoiding the defect of low fault detection accuracy of the electric energy meter caused by subjective factors and prone to errors in manual detection, thereby further improving the fault detection accuracy of the electric energy meter.
[0159] In an exemplary embodiment, in order to more clearly illustrate the electric energy meter fault detection method based on the electric energy meter fault detection model provided in the embodiment of the present application, the electric energy meter fault detection method based on the electric energy meter fault detection model is specifically described below with a specific embodiment. In one embodiment, Figure 3 and Figure 4 As shown, the present application also provides an electric energy meter fault detection method based on broadband impedance data. When performing fault detection on the electric energy meter, first obtain the sample broadband impedance spectrum data associated with the sample electric energy meter, and perform feature extraction processing on the sample broadband impedance spectrum data to obtain the feature vector corresponding to the sample broadband impedance spectrum data, and then divide the feature vector according to the preset ratio to obtain the training data set and the verification data set. Then, according to the training data set, the electric energy meter fault detection model to be trained is iteratively trained to obtain the trained electric energy meter fault detection model. Then, according to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model. When the prediction accuracy is greater than the preset accuracy, the trained electric energy meter fault detection model is used as the trained electric energy meter fault detection model. Finally, obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected. Specifically including the following contents:
[0160] like Figure 3As shown in the figure, an impedance tester is used to collect the impedance and phase angle of all exposed ports of the electric energy meter at different frequencies, and broadband impedance spectrum data that can represent the internal characteristics of the electric energy meter are obtained. The collected data is processed by t-SNE, and the working principle of the electric energy meter is deeply studied based on the data. The study considers detecting the operating status of the internal circuits and components of the electric energy meter without opening the outer shell of the electric energy meter. The operating status is summarized to obtain its operating characteristics, and the different impedance characteristic data corresponding to the electric energy meter when the internal circuit and component of the electric energy meter fail are obtained. The probabilistic neural network PNN model is used for training to construct a neural network model corresponding to the faulty electric energy meter state and the impedance characteristic data. The change in external impedance parameters is used to derive the fault of the internal components, so that the fault of the electric energy meter can be identified without opening the cover of the electric energy meter.
[0161] like Figure 4 As shown, the following steps are included:
[0162] (1) Use an impedance tester to collect the impedance and phase angle of all exposed ports of the electric energy meter at different frequencies to obtain broadband impedance spectrum data that can represent the internal characteristics of the electric energy meter.
[0163] (2) In order to reduce the impact of differences between different feature data on the sensitivity and sensibility of diagnostic parameters, the collected impedance and phase angle feature data are preprocessed. The raw data are cleaned, converted and organized to make them more suitable for model training and analysis.
[0164] (3) The parameters collected by the impedance tester have many dimensions and strong coupling, which results in high computational complexity and consumes a lot of computing time. t-SNE is used to map high-dimensional broadband impedance spectrum data to low-dimensional space, process the nonlinear relationship in high-dimensional broadband impedance spectrum data, reduce the complexity of complex data sets, and significantly reduce the amount of computer computing.
[0165] (4) The obtained low-dimensional broadband impedance spectroscopy data sample set is divided into training samples and test samples in a ratio of 80% and 20%.
[0166] (5) Setting the parameter values of the PNN model and bringing the training samples into the PNN model to obtain the trained PNN diagnostic model.
[0167] (6) Send the test samples into the trained PNN model to test the diagnostic effect of the model.
[0168] (7) Output the prediction results of the training samples and test samples respectively, and use the confusion matrix to compare with the actual classification results of the samples to intuitively show the correspondence between the model's prediction results and the true categories. The accuracy and loss rate of the model are used to reflect the training results of the model, such as Figure 5 and Figure 6 shown.
[0169] Among them, the PNN neural network loss rate calculation includes the following steps:
[0170] (1) Given a feature vector and the corresponding labels ,Label For a category .
[0171] (2) Use Gaussian kernel function to calculate input samples The probability density of belonging to each category. The specific formula is:
[0172] , formula (2)
[0173] in, Belongs to the category Samples of Yes Category The number of samples; is the dimension of the input features; is the smoothing parameter of the Gaussian kernel function; Represents the input sample and Class Sample The Euclidean distance between .
[0174] (3) Normalize the probability density of each category. The normalized conditional probability is:
[0175] , formula (3)
[0176] in, Category C i The prior probability of It is in category C i The probability density function of .
[0177] (4) The loss function is usually based on negative log-likelihood (NLL), which is used to evaluate the difference between the model's prediction results and the true category. The formula is:
[0178] , formula (1)
[0179] in, Is the model for the sample Predicted as true category By minimizing the negative log-likelihood loss, the model gradually adjusts the parameters to maximize the probability of correct classification.
[0180] Among them, the fault sample table corresponding to the PNN model is shown in the following table:
[0181] Table 1 Fault sample table
[0182]
[0183] Among them, the fault diagnosis table corresponding to the PNN model is shown in the following table:
[0184] Table 2 Fault diagnosis table
[0185]
[0186] In the above embodiment, when the electric energy meter is fault-detected, the electric energy meter fault detection model is pre-trained by using the sample broadband impedance spectrum data associated with the sample electric energy meter, so that in practical applications, after obtaining the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, the fault detection result of the electric energy meter to be detected can be predicted; secondly, the electric energy meter fault detection model receives new data in each round of iterative training, so as to improve and optimize the model internally, so as to be able to predict more effectively, which is conducive to improving the prediction accuracy of the electric energy meter fault detection model, and further improving the fault detection accuracy of the electric energy meter; moreover, the whole process does not require manual intervention, avoiding the defects of subjective factors and easy errors in the manual detection method, resulting in low fault detection accuracy of the electric energy meter, and further improving the fault detection accuracy of the electric energy meter. At the same time, when the electric energy meter is fault-detected, it is not necessary to open the cover of the electric energy meter for detection, and non-destructive detection can be achieved. Only one fixed table position is required for detection, and no external adjustable power supply is required. Traditional fault detection methods usually require each electric energy meter to be opened for detection, which has the problems of low work efficiency, difficulty in fault discovery and troubleshooting, and limited monitoring timeliness. The non-destructive testing method based on impedance data processing solves these problems and reduces the time cost of detection. Multi-port, wide-spectrum impedance data is used as the internal structure characteristics of the electric energy meter. The characteristic data is classified through a probabilistic neural network to achieve a mapping from characteristic data to working status, achieving a deeper level of faulty electric energy meter identification. When the impedance data measured by the electric energy meter is input, the faulty electric energy meter can be identified with fast identification speed and high accuracy.
[0187] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0188] Based on the same inventive concept, the embodiment of the present application also provides an electric energy meter fault detection device based on an electric energy meter fault detection model for implementing the electric energy meter fault detection method based on an electric energy meter fault detection model. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the embodiments of one or more electric energy meter fault detection devices based on electric energy meter fault detection models provided below can refer to the limitations of the electric energy meter fault detection method based on the electric energy meter fault detection model above, and will not be repeated here.
[0189] In an exemplary embodiment, Figure 7 As shown, an electric energy meter fault detection device based on an electric energy meter fault detection model is provided, comprising: a data acquisition module 701, a feature extraction module 702, a data division module 703, a model training module 704, a model verification module 705, a model determination module 706 and a model prediction module 707, wherein:
[0190] The data acquisition module 701 is used to acquire sample broadband impedance spectrum data associated with the sample electric energy meter.
[0191] The feature extraction module 702 is used to perform feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
[0192] The data partitioning module 703 is used to partition the feature vector according to a preset ratio to obtain a training data set and a verification data set.
[0193] The model training module 704 is used to iteratively train the electric energy meter fault detection model to be trained according to the training data set to obtain the trained electric energy meter fault detection model.
[0194] The model verification module 705 is used to verify the trained electric energy meter fault detection model according to the verification data set to obtain the prediction accuracy of the trained electric energy meter fault detection model.
[0195] The model determination module 706 is used to use the trained electric energy meter fault detection model as the trained electric energy meter fault detection model when the prediction accuracy is greater than the preset accuracy.
[0196] The model prediction module 707 is used to obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
[0197] In an exemplary embodiment, the model training module 704 is also used to obtain the predicted probability of actual category information of the training data set through the electric energy meter fault detection model to be trained; determine the target loss value based on the predicted probability; and iteratively train the electric energy meter fault detection model to be trained based on the target loss value to obtain the trained electric energy meter fault detection model.
[0198] In an exemplary embodiment, the model training module 704 is also used to obtain multiple preset data sets corresponding to the electric energy meter fault detection model to be trained, and the category information of each preset data set; determine multiple predicted category information of the training data set and the predicted probability of each predicted category information according to the training data set, each preset data set, and the category information of each preset data set; and filter out the predicted probability of the actual category information of the training data set from the predicted probability of each predicted category information.
[0199] In an exemplary embodiment, the data acquisition module 701 is also used to acquire impedance data and phase angle data associated with the sample electric energy meter; preprocess the impedance data and phase angle data to obtain preprocessed impedance data and preprocessed phase angle data; and use the preprocessed impedance data and preprocessed phase angle data as sample broadband impedance spectrum data.
[0200] In an exemplary embodiment, the model prediction module 707 is also used to input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain multiple predicted working states of the electric energy meter to be detected, and the probability of occurrence of each predicted working state; from each predicted working state, the predicted working state with the highest probability of occurrence is screened out as the target working state of the electric energy meter to be detected.
[0201] In an exemplary embodiment, the feature extraction module 702 is also used to obtain the data type of the sample broadband impedance spectrum data; query the correspondence between the data type and the feature extraction model to obtain the target feature extraction model corresponding to the data type of the sample broadband impedance spectrum data; perform feature extraction processing on the sample broadband impedance spectrum data through the target feature extraction model to obtain the feature vector corresponding to the sample broadband impedance spectrum data.
[0202] Each module in the above-mentioned electric energy meter fault detection device based on the electric energy meter fault detection model can be implemented in whole or in part by software, hardware and a combination thereof. Each of the above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to each of the above modules.
[0203] In an exemplary embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as shown in FIG. Figure 8 As shown. The computer device includes a processor, a memory, an input / output interface (Input / Output, referred to as I / O) and a communication interface. The processor, the memory and the input / output interface are connected through a system bus, and the communication interface is connected to the system bus through the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data such as training data sets and verification data sets. The input / output interface of the computer device is used to exchange information between the processor and an external device. The communication interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, an electric energy meter fault detection method based on an electric energy meter fault detection model is implemented.
[0204] Those skilled in the art will understand that Figure 8 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0205] In an exemplary embodiment, a computer device is further provided, including a memory and a processor, wherein a computer program is stored in the memory, and the processor implements the steps in the above-mentioned method embodiments when executing the computer program.
[0206] In an exemplary embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0207] In an exemplary embodiment, a computer program product is provided, including a computer program, and when the computer program is executed by a processor, the steps in the above method embodiments are implemented.
[0208] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0209] The technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0210] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A method for detecting an electric energy meter fault based on an electric energy meter fault detection model, characterized in that: The method comprises: Acquiring sample broadband impedance spectrum data associated with a sample electric energy meter; Performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data; The feature vector is divided according to a preset ratio to obtain a training data set and a verification data set; Iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model; According to the verification data set, the trained electric energy meter fault detection model is verified to obtain the prediction accuracy of the trained electric energy meter fault detection model; In a case where the prediction accuracy is greater than a preset accuracy, the trained electric energy meter fault detection model is used as a trained electric energy meter fault detection model; Obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
2. The method according to claim 1, characterized in that The method of iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain the trained electric energy meter fault detection model comprises: Obtaining the predicted probability of the actual category information of the training data set through the electric energy meter fault detection model to be trained; Determining a target loss value according to the predicted probability; According to the target loss value, the electric energy meter fault detection model to be trained is iteratively trained to obtain a trained electric energy meter fault detection model.
3. The method according to claim 2, characterized in that The step of obtaining the predicted probability of the actual category information of the training data set through the electric energy meter fault detection model to be trained includes: Acquire multiple preset data sets corresponding to the electric energy meter fault detection model to be trained, and category information of each preset data set; Determining, according to the training data set, each of the preset data sets, and the category information of each of the preset data sets, a plurality of predicted category information of the training data set, and a predicted probability of each of the predicted category information; The predicted probabilities of the actual category information of the training data set are screened out from the predicted probabilities of the predicted category information.
4. The method according to claim 1, characterized in that: The step of obtaining sample broadband impedance spectrum data associated with the sample electric energy meter includes: obtaining impedance data and phase angle data associated with a sample electric energy meter; Preprocessing the impedance data and the phase angle data to obtain preprocessed impedance data and preprocessed phase angle data; The preprocessed impedance data and the preprocessed phase angle data are both used as the sample broadband impedance spectrum data.
5. The method according to claim 1, characterized in that: The step of inputting the to-be-analyzed broadband impedance spectrum data into the trained electric energy meter fault detection model to obtain the target working state of the to-be-detected electric energy meter includes: Inputting the to-be-analyzed broadband impedance spectrum data into the trained electric energy meter fault detection model to obtain a plurality of predicted working states of the to-be-detected electric energy meter and the occurrence probability of each predicted working state; From each of the predicted working states, the predicted working state with the highest probability of occurrence is screened out as the target working state of the electric energy meter to be detected.
6. The method according to any one of claims 1 to 5, characterized in that The step of performing feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data includes: Acquire the data type of the sample broadband impedance spectrum data; Querying the correspondence between the data type and the feature extraction model to obtain a target feature extraction model corresponding to the data type of the sample broadband impedance spectrum data; The target feature extraction model is used to perform feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data.
7. An electric energy meter fault detection device based on an electric energy meter fault detection model, characterized in that: The device comprises: A data acquisition module, used to acquire sample broadband impedance spectrum data associated with a sample electric energy meter; A feature extraction module, used to perform feature extraction processing on the sample broadband impedance spectrum data to obtain a feature vector corresponding to the sample broadband impedance spectrum data; A data partitioning module is used to partition the feature vector according to a preset ratio to obtain a training data set and a verification data set; A model training module, used for iteratively training the electric energy meter fault detection model to be trained according to the training data set to obtain a trained electric energy meter fault detection model; A model verification module, used to verify the trained electric energy meter fault detection model according to the verification data set to obtain the prediction accuracy of the trained electric energy meter fault detection model; A model determination module, configured to use the trained electric energy meter fault detection model as a trained electric energy meter fault detection model when the prediction accuracy is greater than a preset accuracy; The model prediction module is used to obtain the broadband impedance spectrum data to be analyzed associated with the electric energy meter to be detected, and input the broadband impedance spectrum data to be analyzed into the trained electric energy meter fault detection model to obtain the target working state of the electric energy meter to be detected as the fault detection result of the electric energy meter to be detected.
8. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
10. A computer program product, comprising a computer program, characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
Citation Information
Cited By
Bayesian optimization-based broadband impedance spectrum mode identification method and system
CN122365170A