Electric appliance monitoring method, device and equipment and computer readable storage medium
By calculating the electrical feature correlation score of electrical appliances and classifying them using a single-class support vector machine, the problems of feature irrelevance and redundancy in the existing technology are solved, and the accuracy of appliance monitoring is improved.
Patent Information
- Application Number
- CN202510768301.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-06-10
- Publication Date
- 2025-09-19
AI Technical Summary
In existing non-invasive household appliance load identification technologies, feature extraction methods rely on the experience of monitoring personnel, resulting in irrelevant and redundant features, which reduces the accuracy of load monitoring.
By calculating the correlation score of each electrical feature of the electrical appliance, an electrical feature sequence is generated based on the correlation score sorting, and the electrical feature subset is classified using a single-class support vector machine classifier to determine the target electrical feature subset and monitor the indicators to be measured.
The accuracy of electrical feature selection is improved, the accuracy of electrical appliance monitoring is enhanced, and the problems of feature irrelevance and redundancy are avoided.
Smart Images

Figure CN120669018A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of electrical appliance monitoring technology, and in particular to an electrical appliance monitoring method, apparatus, device, and computer-readable storage medium. Background Art
[0002] Non-intrusive household appliance load identification is a non-intrusive load monitoring technology for the user side. Its process can be summarized into four steps: data collection, event monitoring, feature extraction, and load identification.
[0003] In terms of feature extraction, existing methods usually subjectively determine the type of features to be extracted based on the experience of the monitoring personnel; however, this will lead to problems such as the extracted features being irrelevant and redundant, thereby reducing the accuracy of non-intrusive load monitoring. Summary of the Invention
[0004] In view of this, the purpose of this application is to overcome the deficiencies in the prior art and provide an electrical appliance monitoring method, the method comprising:
[0005] During the operation of the target electrical appliance, calculating a correlation score of each electrical feature of the target electrical appliance;
[0006] Sorting the electrical features based on the correlation scores to obtain an electrical feature sequence, and generating a preset number of electrical feature subsets based on the electrical feature sequence;
[0007] Classifying each of the electrical feature subsets based on a preset single-class support vector machine classifier to obtain a classification score for each of the electrical feature subsets;
[0008] A target electrical feature subset is determined based on the classification score, and a monitoring value of a to-be-monitored indicator of the target electrical appliance is determined based on the target electrical feature subset.
[0009] In one embodiment, the step of calculating the relevance score of each electrical feature of the target electrical appliance includes:
[0010] For each electrical feature, determining a discriminative score of the current electrical feature based on a feature mean and a feature variance of the current electrical feature;
[0011] determining a redundancy score for the current electrical feature based on the current electrical feature and each remaining electrical feature;
[0012] A relevance score of the current electrical signature is determined based on the discriminability score and the redundancy score.
[0013] In one embodiment, the step of determining the discriminative score of the current electrical feature based on the feature mean and feature variance of the current electrical feature includes:
[0014] Calculating an inter-class distance of the current electrical feature based on a feature mean of the current electrical feature and a preset first model;
[0015] Calculating the intra-class distance of the current electrical feature based on the feature variance of the current electrical feature and a preset second model;
[0016] A discriminability score of the current electrical feature is determined based on the inter-class distance and the intra-class distance.
[0017] In one embodiment, the step of determining the redundancy score of the current electrical feature based on the current electrical feature and each of the remaining electrical features comprises:
[0018] determining mutual information between the current electrical feature and each remaining electrical feature based on a joint probability density and a marginal probability density of the current electrical feature and each remaining electrical feature;
[0019] determining a redundancy reference score between the current electrical feature and each remaining electrical feature based on the mutual information between the current electrical feature and each remaining electrical feature;
[0020] The maximum redundancy reference score is determined as the redundancy score of the current electrical feature.
[0021] In one embodiment, the step of sorting the electrical features based on the correlation scores to obtain an electrical feature sequence, and generating a preset number of electrical feature subsets based on the electrical feature sequence includes:
[0022] Sort the electrical features from largest to smallest based on the correlation score to obtain an electrical feature sequence;
[0023] Based on the electrical feature sequence, each electrical feature is sequentially added to the electrical feature set until all the electrical features in the electrical feature sequence are added to the electrical feature set, thereby obtaining a preset number of electrical feature subsets.
[0024] In one embodiment, the step of classifying each electrical feature subset based on a preset single-class support vector machine classifier to obtain a classification score for each electrical feature subset includes:
[0025] For each of the electrical feature subsets, classify the current electrical feature subset based on a preset single-class support vector machine classifier to determine normal electrical features and abnormal electrical features in the current electrical feature subset;
[0026] A classification score of the current electrical feature subset is calculated based on the number of the normal electrical features and the number of the abnormal electrical features.
[0027] In one embodiment, the step of determining a target electrical feature subset based on the classification score comprises:
[0028] Comparing the classification scores of each of the electrical feature subsets to determine the electrical feature subset with the largest classification score;
[0029] The electrical feature subset with the largest classification score is determined as the target electrical feature subset. The present application also provides an electrical appliance monitoring device, the electrical appliance monitoring device comprising:
[0030] a calculation module, configured to calculate a correlation score of each electrical feature of the target electrical appliance during operation of the target electrical appliance;
[0031] a generating module, configured to sort the electrical features based on the correlation scores to obtain an electrical feature sequence, and generate a preset number of electrical feature subsets based on the electrical feature sequence;
[0032] a classification module, configured to classify each of the electrical feature subsets based on a preset single-class support vector machine classifier to obtain a classification score for each of the electrical feature subsets;
[0033] A determination module is used to determine a target electrical feature subset based on the classification score, and to determine a monitoring value of a to-be-monitored indicator of the target electrical appliance based on the target electrical feature subset.
[0034] The present application also provides a computer device, which includes a processor and a memory, wherein the memory stores a computer program, and the processor is configured to execute the computer program to implement the above-mentioned electrical appliance monitoring method.
[0035] The present application also provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is run on a processor, the above-mentioned electrical appliance monitoring method is executed.
[0036] The embodiments of the present application have the following beneficial effects:
[0037] During the operation of a target electrical appliance, an embodiment of the present application calculates a correlation score for each electrical feature of the target electrical appliance; sorts each electrical feature based on the correlation score to obtain an electrical feature sequence, and generates a preset number of electrical feature subsets based on the electrical feature sequence; classifies each electrical feature subset based on a preset single-class support vector machine classifier to obtain a classification score for each electrical feature subset; determines a target electrical feature subset based on the classification score, and determines a monitoring value for a to-be-monitored indicator based on the target electrical feature subset. By performing correlation scoring on the electrical features, determining an electrical feature subset, performing classification scoring on the electrical feature subset, and determining a target electrical feature subset for electrical appliance monitoring, the problem of irrelevant and redundant features is avoided, the accuracy of electrical feature selection is improved, and the accuracy of electrical appliance monitoring is thereby improved. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] To more clearly illustrate the technical solution of this application, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of this application and should not be considered as limiting the scope of protection of this application. Those skilled in the art can also derive other relevant drawings based on these drawings without inventive effort.
[0039] Figure 1 A schematic flow chart of a first embodiment of the electrical appliance monitoring method provided by this application;
[0040] Figure 2 A flowchart of a second embodiment of the electrical appliance monitoring method provided by this application;
[0041] Figure 3 A flowchart of a third embodiment of the electrical appliance monitoring method provided by this application;
[0042] Figure 4 This is a flow chart of a fourth embodiment of the electrical appliance monitoring method provided by the present application;
[0043] Figure 5 This is a flow chart of a fifth embodiment of the electrical appliance monitoring method provided by the present application;
[0044] Figure 6 This is a schematic diagram of the structure of the electrical appliance monitoring device provided in this application. DETAILED DESCRIPTION
[0045] The technical solutions in the embodiments of the present application will be described clearly and completely below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, rather than all the embodiments.
[0046] The components of the embodiments of the present application generally described and illustrated in the drawings herein may be arranged and designed in a variety of different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the claimed application, but rather merely represents selected embodiments of the present application. All other embodiments obtained by those skilled in the art based on the embodiments of the present application without creative effort are within the scope of protection of the present application.
[0047] Hereinafter, the terms "including", "having" and their cognates, which may be used in various embodiments of the present application, are intended only to indicate specific features, numbers, steps, operations, elements, components or combinations of the foregoing items, and should not be understood as first excluding the existence of one or more other features, numbers, steps, operations, elements, components or combinations of the foregoing items or the possibility of adding one or more features, numbers, steps, operations, elements, components or combinations of the foregoing items.
[0048] Furthermore, the terms “first,” “second,” “third,” etc., are merely used for distinguishing descriptions and are not to be understood as indicating or implying relative importance.
[0049] Unless otherwise defined, all terms used herein (including technical and scientific terms) have the same meaning as commonly understood by those skilled in the art to which the various embodiments of the present application belong. The terms (such as those defined in generally used dictionaries) will be interpreted as having the same meaning as in the context of the relevant technical field and will not be interpreted as having an idealized meaning or an overly formal meaning unless clearly defined in the various embodiments of the present application.
[0050] It is understandable that the method of the present application is applied to an electrical appliance monitoring device, which may be a smart terminal, a PC terminal, a mobile terminal, etc., and is not limited here.
[0051] The following describes some embodiments of the present application in detail with reference to the accompanying drawings. In the absence of conflict, the following embodiments and features in the embodiments may be combined with each other.
[0052] Please refer to Figure 1 , Figure 1 This is a flow chart of a first embodiment of the electrical appliance monitoring method provided by this application, the method comprising:
[0053] Step S101 : during the operation of the target electrical appliance, calculating the correlation score of each electrical feature of the target electrical appliance.
[0054] In this embodiment, the appliance monitoring device collects voltage and current cycle data of the target appliance during its operation, determines a preset number of electrical characteristics of the target appliance based on the voltage and current cycle data, and then calculates the correlation score of each electrical characteristic.
[0055] In one embodiment, the appliance monitoring device determines multiple electrical characteristics of the target appliance based on the voltage and current cycle data of the target appliance, including but not limited to: instantaneous delay time, instantaneous current amplitude, instantaneous power peak, current crest factor, current amplitude, current effective value, VI curve area, VI curve shape, VI curve curvature, current distortion rate, current third harmonic, current fifth harmonic, current seventh harmonic, active power, and reactive power. It will be understood that the 15 electrical characteristics listed above are merely examples of options.
[0056] In one embodiment, the electrical appliance monitoring device uses an MDMR (Multivariate Distance Matrix Regression Score) algorithm to calculate a correlation score for each electrical feature.
[0057] Step S102 : sorting the electrical features based on the correlation scores to obtain an electrical feature sequence, and generating a preset number of electrical feature subsets based on the electrical feature sequence.
[0058] In this embodiment, after obtaining the correlation score of each electrical feature, the electrical appliance monitoring device sorts the electrical features based on the correlation score to obtain an electrical feature sequence; the electrical appliance monitoring device generates a preset number of electrical feature subsets based on the electrical feature sequence.
[0059] In one embodiment, the electrical appliance monitoring device sorts the electrical features in descending order of their correlation scores to obtain an electrical feature sequence. A higher correlation score indicates that the electrical feature has a higher correlation with the target appliance's monitored indicator (i.e., the electrical feature has the highest statistical correlation with the monitored indicator, thereby ensuring that the selected feature can effectively explain or predict changes in the monitored indicator), while having the lowest correlation with other electrical features (i.e., the electrical feature has low redundancy with other electrical features).
[0060] In one embodiment, the electrical appliance monitoring device selects electrical features in order of arrangement based on the electrical feature sequence and adds them to the electrical feature set. Each time an electrical feature is added to the electrical feature set, an electrical feature subset can be obtained until a preset number of electrical feature subsets are generated.
[0061] Step S103 : classifying each electrical feature subset based on a preset single-class support vector machine classifier to obtain a classification score for each electrical feature subset.
[0062] In this embodiment, after obtaining a preset number of electrical feature subsets, the appliance monitoring device classifies each electrical feature subset using a preset one-class support vector machine (OCSVM) classifier, obtaining a classification score for each electrical feature subset. The OCSVM classifier, a one-class support vector machine (OCSVM), assesses the classification accuracy of the feature set by constructing a one-class hypersphere. The core process includes data preprocessing, model training, decision threshold determination, and accuracy index calculation to obtain a classification score for the electrical feature subset.
[0063] It can be understood that the single-class support vector machine classifier is obtained by collecting the electrical characteristics of different electrical appliances during operation in advance for training. Different single-class support vector machine classifiers are trained for different indicators to be monitored; each indicator to be monitored has a unique corresponding single-class support vector machine classifier, which can improve the accuracy of classification and scoring of electrical feature subsets.
[0064] Step S104 : determining a target electrical feature subset based on the classification score, and determining a monitoring value of a to-be-monitored indicator of the target electrical appliance based on the target electrical feature subset.
[0065] In this embodiment, after determining the classification score corresponding to each electrical feature subset, the electrical feature subset with the largest classification score among all electrical feature subsets is selected as the target electrical feature subset, and then the monitoring value of the target electrical appliance's monitored indicator is determined based on the electrical features in the target electrical feature subset. For example, the target electrical appliance is an electric bicycle, and the monitored indicator is the electric bicycle's charging status. The target electrical feature subset determined by the electrical feature monitoring device includes: instantaneous current amplitude, instantaneous power peak, current crest factor, current amplitude, current effective value, active power, and reactive power. Based on these electrical features, the electrical feature monitoring device can determine whether the electric bicycle's charging status is normal.
[0066] It is understandable that during the operation of the target electrical appliance, the electrical appliance monitoring device will cyclically execute the above steps to determine in real time whether the monitoring value of the indicator to be monitored during the operation of the target electrical appliance is normal.
[0067] The electrical appliance monitoring device in this embodiment calculates the correlation score of each electrical feature of the target electrical appliance during its operation; sorts the electrical features based on the correlation score to obtain an electrical feature sequence, and generates a preset number of electrical feature subsets based on the electrical feature sequence; classifies each electrical feature subset based on a preset single-class support vector machine classifier to obtain a classification score for each electrical feature subset; determines a target electrical feature subset based on the classification score, and determines the monitoring value of the target electrical appliance's monitored indicator based on the target electrical feature subset. By performing correlation scoring on the electrical features, determining the electrical feature subset, performing classification scoring on the electrical feature subset, and determining the target electrical feature subset for appliance monitoring, the problem of irrelevant and redundant features is avoided, the accuracy of electrical feature selection is improved, and the accuracy of appliance monitoring is thereby improved.
[0068] Please refer to Figure 2 , Figure 2 This is a flow chart of a second embodiment of the electrical appliance monitoring method provided by the present application. The difference between the second embodiment and the first embodiment is that the step of calculating the correlation score of each electrical feature of the target electrical appliance includes:
[0069] Step S201 : for each electrical feature, determine the discriminative score of the current electrical feature based on the feature mean and feature variance of the current electrical feature.
[0070] In this embodiment, for each electrical feature, the appliance monitoring device determines a discriminative score of the current electrical feature based on the feature mean and feature variance of the current electrical feature.
[0071] It should be noted that the electrical appliance monitoring equipment will collect multiple characteristic values for each electrical characteristic, and then calculate the characteristic mean and characteristic variance of each electrical characteristic.
[0072] It's important to note that the electrical monitoring device has a pre-configured discriminative scoring model. The device inputs the feature mean and feature variance of the current electrical characteristic into the discriminative scoring model to obtain a discriminative score for the current electrical characteristic. The discriminative scoring model is pre-trained, with different discriminative scoring models trained for different monitored indicators. Each monitored indicator has a unique discriminative scoring model, which improves the accuracy of the discriminative scoring of electrical characteristics.
[0073] Step S202 : determining a redundancy score of the current electrical feature based on the current electrical feature and each of the remaining electrical features.
[0074] In this embodiment, for each electrical feature, the electrical appliance monitoring device pairs the current electrical feature with each other electrical feature, inputs a pre-trained redundancy scoring model, obtains the redundancy score between the current electrical feature and each other electrical feature, and then selects the largest redundancy score from all the redundancy scores to determine it as the redundancy score of the current electrical feature.
[0075] Step S203 : determining the relevance score of the current electrical feature based on the discriminability score and the redundancy score.
[0076] In this embodiment, for each electrical feature, the appliance monitoring device determines the discriminability score and redundancy score corresponding to the current electrical feature, and then determines the relevance score of the electrical feature based on the discriminability score and redundancy score. The formula for calculating the relevance score of the electrical feature is:
[0077]
[0078] Among them, S MDMR (i) is the correlation score of the i-th electrical feature, S SFS (i) is the discriminative score of the i-th electrical feature, S MIC (i, j) is the redundancy reference score between the i-th electrical feature and the j-th remaining electrical feature, G is the electrical feature set of the target appliance, and the discriminability score is divided by the maximum redundancy score among all the redundant reference scores to obtain the correlation score of the electrical feature.
[0079] In one embodiment, the step of determining the discriminative score of the current electrical feature based on the feature mean and feature variance of the current electrical feature includes:
[0080] Step S2011 : calculating the inter-class distance of the current electrical feature based on the feature mean of the current electrical feature and a preset first model.
[0081] In this embodiment, after determining the feature mean of the current electrical feature, the appliance monitoring device inputs the feature mean of the current electrical feature into a preset first model, and uses the first model to calculate the inter-class distance of the current electrical feature. It should be noted that the discriminative scoring model pre-set in the appliance monitoring device includes the first model, which is used to calculate the inter-class distance of the electrical feature.
[0082] Specifically, the formula for calculating the inter-class distance of electrical features is:
[0083]
[0084] Among them, D b (i) is the inter-class distance of the i-th electrical feature, K is the number of electrical appliance types used in the process of training the first model, and lk is the number of target appliance samples used in training the first model, is the characteristic mean of the i-th electrical characteristic of the target appliance, μ i is the mean value of the ith electrical characteristics of all appliances used in the process of training the first model, δ is the control parameter, V i is the variance of the i-th electrical feature of all appliances used in the process of training the first model.
[0085] Step S2012: Calculate the intra-class distance of the current electrical feature based on the feature variance of the current electrical feature and a preset second model.
[0086] In this embodiment, after determining the feature variance of the current electrical feature, the appliance monitoring device inputs the feature variance of the current electrical feature into a preset second model, and uses the second model to calculate the intra-class distance of the current electrical feature. It should be noted that the discriminative scoring model pre-set in the appliance monitoring device includes the second model, which is used to calculate the intra-class distance of the electrical feature.
[0087] Specifically, the formula for calculating the intra-class distance of electrical features is:
[0088]
[0089] Among them, D w (i) is the intra-class distance of the i-th electrical feature, K is the number of electrical appliance types used in the process of training the first model, and l k is the number of target appliance samples used in training the first model, is the characteristic variance of the i-th electrical characteristic of the target appliance, λ is the control parameter, J(f i )=2f i T Lf i , where L represents the Laplace matrix, T represents the matrix transpose, and f i is the i-th electrical characteristic matrix of the target appliance, which is formed by all eigenvalues of the i-th electrical characteristic. i =(f i 1 ,f i 2 ,...,f i K ).
[0090] Step S2013 : determining the discriminative score of the current electrical feature based on the inter-class distance and the intra-class distance.
[0091] In this embodiment, after determining the inter-class distance and the intra-class distance of the current electrical feature, the electrical appliance monitoring device determines a discriminative score of the current electrical feature based on the inter-class distance and the intra-class distance.
[0092] Specifically, the formula for calculating the discriminative score of the electrical feature is:
[0093]
[0094] Among them, S SFS (i) is the discriminative score of the i-th electrical feature, D b (i) is the inter-class distance of the i-th electrical feature, D w (i) is the intra-class distance of the i-th electrical feature.
[0095] In one embodiment, the step of determining a redundancy score of the current electrical feature based on the current electrical feature and each of the remaining electrical features includes:
[0096] Step S2021 : determining the mutual information between the current electrical feature and each remaining electrical feature based on the joint probability density and the marginal probability density of the current electrical feature and each remaining electrical feature.
[0097] In this embodiment, the electrical appliance monitoring device calculates the joint probability density and marginal probability density of the current electrical feature and each other electrical feature, and determines the mutual information between the current electrical feature and each other electrical feature based on the joint probability density and marginal probability density of the current electrical feature and each other electrical feature.
[0098] Specifically, the formula for calculating the mutual information between the current electrical feature and each of the remaining electrical features is:
[0099]
[0100] Among them, I(f i ,f j ) is the mutual information, which indicates the degree of dependence between two electrical features, Γ={f i k} N,K The feature data matrix representing all electrical features of all electrical appliances used in the training process, G is the electrical feature set of the target appliance. p(f i ,f j )=p(f i )×p(f j ), where p(f i ,f j ) is the joint probability density, p(f i ) is the marginal probability density of the i-th electrical characteristic matrix of the target appliance, p(fj ) is the marginal probability density of the jth remaining electrical characteristic matrix of the target appliance, f i is the i-th electrical characteristic matrix of the target appliance, which is formed by all eigenvalues of the i-th electrical characteristic. i =(f i 1 ,f i 2 ,...,f i K ), f j is the jth remaining electrical characteristic matrix of the target appliance, and the jth remaining electrical characteristic matrix is formed by all eigenvalues of the jth remaining electrical characteristic.
[0101] Step S2022 : determining a redundancy reference score between the current electrical feature and each of the remaining electrical features based on the mutual information between the current electrical feature and each of the remaining electrical features.
[0102] In this embodiment, the appliance monitoring device determines a redundancy reference score between the current electrical feature and each remaining electrical feature based on mutual information between the current electrical feature and each remaining electrical feature.
[0103] Specifically, the formula for calculating the redundancy reference score between the current electrical feature and each of the remaining electrical features is:
[0104]
[0105] Among them, s MIC (i, j) is the redundancy reference score between the i-th electrical feature and the j-th remaining electrical features, I(f i ,f j ) is the mutual information between the i-th electrical feature and the j-th remaining electrical feature.
[0106] Step S2023 : determining the maximum redundancy reference score as the redundancy score of the current electrical feature.
[0107] In this embodiment, after determining the redundancy reference score between the current electrical feature and each of the other electrical features, the electrical appliance monitoring device selects the largest redundancy reference score to be determined as the redundancy score of the current electrical feature. The specific formula is:
[0108] S MIC (i,j)=max(s MIC (i,j))
[0109] Among them, S MIC (i, j) is the redundancy score between the i-th electrical feature and the j-th remaining electrical features, sMIC (i, j) is the redundancy reference score between the i-th electrical feature and the j-th remaining electrical feature.
[0110] The electrical appliance monitoring device in this embodiment determines, for each electrical feature, a discriminative score of the current electrical feature based on the feature mean and feature variance of the current electrical feature; determines a redundancy score of the current electrical feature based on the current electrical feature and each of the remaining electrical features; and determines a correlation score of the current electrical feature based on the discriminative score and the redundancy score, thereby performing a correlation score on the current electrical feature. By calculating the discriminative score and the redundancy score of each electrical feature, determining the correlation between the electrical feature and the monitored indicator of the target electrical appliance, and the redundancy between the electrical feature and other electrical features, not only does this reduce the feature dimension and computing resources, but it also improves the accuracy of the correlation score for the electrical features. It also helps to avoid the problem of irrelevant and redundant features in the subsequent electrical feature selection, thereby improving the accuracy of the electrical feature selection.
[0111] Please refer to Figure 3 , Figure 3 This is a flow chart of the third embodiment of the electrical appliance monitoring method provided by the present application. The difference between the third embodiment and the first to second embodiments is that the steps of sorting electrical features based on correlation scores to obtain an electrical feature sequence, and generating a preset number of electrical feature subsets based on the electrical feature sequence include:
[0112] Step S301 : sorting the electrical features from large to small based on the correlation scores to obtain an electrical feature sequence.
[0113] In this embodiment, after determining the correlation scores of the various electrical features of the target electrical appliance, the electrical appliance monitoring device sorts the electrical features from large to small based on the correlation scores to obtain an electrical feature sequence, that is, electrical features with larger correlation scores are sorted first, and electrical features with smaller correlation scores are sorted last.
[0114] Step S302 : Based on the electrical feature sequence, each electrical feature is sequentially added to the electrical feature set until all electrical features in the electrical feature sequence are added to the electrical feature set, thereby obtaining a preset number of electrical feature subsets.
[0115] In this embodiment, the electrical appliance monitoring device adds each electrical feature to the electrical feature set in sequence based on the electrical feature sequence. Each time an electrical feature is added to the electrical feature set, an electrical feature subset is obtained until all electrical features in the electrical feature sequence are added to the electrical feature set, and a preset number of electrical feature subsets are obtained.
[0116] For example, the electrical feature sequence is: instantaneous current amplitude, instantaneous power peak, current crest factor, current amplitude, current effective value, instantaneous delay time, current distortion rate, current third harmonic, current fifth harmonic, current seventh harmonic, active power, reactive power, VI curve area, VI curve shape, VI curve curvature; the electrical monitoring device first adds the instantaneous current amplitude to the empty set according to the arrangement order to obtain the first electrical feature subset, which only contains the instantaneous current amplitude electrical feature; then, the electrical monitoring device adds the instantaneous current amplitude to the empty set according to the arrangement order to obtain the first electrical feature subset, which only contains the instantaneous current amplitude electrical feature; then, the electrical monitoring device adds the instantaneous current amplitude to the empty set according to the arrangement order to obtain the first electrical feature subset, which only contains the instantaneous current amplitude electrical feature; The instantaneous power peak value is then added to the set including the instantaneous current amplitude in the order of arrangement to obtain a second electrical feature subset, which includes two electrical features: the instantaneous current amplitude and the instantaneous power peak value; the electrical monitoring equipment then adds the current crest factor to the set including the instantaneous current amplitude and the instantaneous power peak value in the order of arrangement to obtain a third electrical feature subset, which includes three electrical features: the instantaneous current amplitude, the instantaneous power peak value and the current crest factor; and so on, ultimately obtaining 15 electrical feature subsets.
[0117] The electrical appliance monitoring device of this embodiment sorts the electrical features from largest to smallest based on the correlation score to obtain an electrical feature sequence. Based on the electrical feature sequence, each electrical feature is sequentially added to the electrical feature set until all electrical features in the electrical feature sequence are added to the electrical feature set, thereby obtaining a preset number of electrical feature subsets. By sorting the electrical features to obtain the electrical feature sequence and then determining the preset number of electrical feature subsets based on the electrical feature sequence, the correlation between the determined electrical feature subsets and the indicator to be monitored can be improved, thereby helping to improve the accuracy of electrical feature selection.
[0118] Please refer to Figure 4 , Figure 4 This is a flow chart of the fourth embodiment of the electrical appliance monitoring method provided by the present application. The fourth embodiment differs from the first to third embodiments in that the steps of classifying each electrical feature subset based on a preset single-class support vector machine classifier and obtaining a classification score for each electrical feature subset include:
[0119] Step S401 : for each electrical feature subset, classify the current electrical feature subset based on a preset single-class support vector machine classifier to determine normal electrical features and abnormal electrical features in the current electrical feature subset.
[0120] In this embodiment, after obtaining a preset number of electrical feature subsets, the electrical appliance monitoring device classifies the current electrical feature subset based on a preset single-class support vector machine classifier for each electrical feature subset, and determines the normal electrical features and abnormal electrical features in the current electrical feature subset.
[0121] It should be noted that the optimization goal of the single-class support vector machine classifier is:
[0122]
[0123] st(ω T φ(x i ))>ρ-ζ i ,i=1,...n
[0124] Where ω is the hyperplane learned by the single-class support vector machine classifier during training; ρ is the distance from the hyperplane to the origin; ζ i is a slack variable that allows some electrical feature errors; v is a regularization parameter, v∈(0,1), which is used to control the proportion of abnormal points and the volume of the hypersphere allowed in the training sample; the constraint condition is that for any electrical feature x i , if st(ω T φ(x i ))>ρ-ζ i If it is a normal electrical characteristic, it is an abnormal electrical characteristic.
[0125] It can be understood that the single-class support vector machine classifier minimizes the norm of the weight vector ω To control the complexity of the classifier and prevent overfitting; introduce the slack variable ζ i Dealing with electrical noise or potential abnormal electrical characteristics, optimizing the objective through penalty terms Balance the tolerance of abnormal electrical characteristics. By maximizing the distance from the hyperplane to the origin (i.e., the optimization term - ρ), ensuring that the normal electrical characteristics are as far away from the origin as possible. The constraint condition requires that most data points satisfy ω T φ(x i )>ρ-ζ i , thus forming a compact boundary that encloses normal electrical features in the feature space. The electrical features within the compact boundary are normal electrical features, and the electrical features outside the compact boundary are abnormal electrical features. i ) refers to the electrical characteristics x i The representation after mapping to high-dimensional feature space through the kernel function.
[0126] Step S402 : Calculate a classification score of the current electrical feature subset based on the number of normal electrical features and the number of abnormal electrical features.
[0127] In this embodiment, after determining the normal electrical features and abnormal electrical features in each electrical feature subset, the electrical appliance monitoring device calculates the classification score of the current electrical feature subset based on the number of normal electrical features and the number of abnormal electrical features in the current electrical feature subset.
[0128] Specifically, the formula for calculating the classification score is:
[0129]
[0130] Where S is the classification score of the electrical feature subset, N1 is the number of normal electrical features, and N2 is the number of abnormal electrical features.
[0131] The electrical appliance monitoring device of this embodiment classifies each electrical feature subset using a preset single-class support vector machine classifier, determines normal and abnormal electrical features within the subset, and calculates a classification score for the subset based on the number of normal and abnormal electrical features. Classifying electrical feature subsets using a single-class support vector machine classifier improves the accuracy of calculating the correlation between the electrical feature subset and the indicator being monitored, thereby improving the accuracy of electrical feature selection.
[0132] Please refer to Figure 5 , Figure 5 This is a flow chart of the fifth embodiment of the electrical appliance monitoring method provided by the present application. The fifth embodiment differs from the first to fourth embodiments in that the step of determining the target electrical feature subset based on the classification score includes:
[0133] Step S501 : comparing the classification scores of each electrical feature subset to determine the electrical feature subset with the largest classification score.
[0134] In this embodiment, after obtaining the classification score of each electrical feature subset, the electrical appliance monitoring device compares the classification scores of each electrical feature subset to determine the electrical feature subset with the largest classification score.
[0135] Step S502 : determining the electrical feature subset with the largest classification score as the target electrical feature subset.
[0136] In this embodiment, the electrical appliance monitoring device determines the electrical feature subset with the highest classification score as the target electrical feature subset, and then determines the monitoring value of the indicator to be monitored based on the electrical features in the target electrical feature subset. It will be understood that the higher the classification score of the electrical feature subset, the greater the proportion of normal electrical features contained in the electrical feature subset used to determine the monitoring value of the indicator to be monitored. In other words, the accuracy of determining the monitoring value of the indicator to be monitored based on the electrical features of the electrical feature subset with the highest classification score is higher.
[0137] The electrical appliance monitoring device in this embodiment compares the classification scores of each electrical feature subset to determine the electrical feature subset with the highest classification score, and then determines the monitoring value of the indicator to be monitored based on the electrical features in the target electrical feature subset. Selecting the electrical feature subset with the highest classification score, which contains the largest proportion of normal electrical features used to determine the monitoring value of the indicator to be monitored, helps improve the accuracy of determining the monitoring value of the indicator to be monitored.
[0138] refer to Figure 6 , Figure 6 : is a schematic diagram of the structure of the electrical appliance monitoring device provided in this application. The electrical appliance monitoring device includes:
[0139] A calculation module 10 is configured to calculate a correlation score of each electrical feature of the target electrical appliance during operation of the target electrical appliance;
[0140] A generating module 20 is configured to sort the electrical features based on the correlation scores to obtain an electrical feature sequence, and generate a preset number of electrical feature subsets based on the electrical feature sequence;
[0141] a classification module 30, configured to classify each of the electrical feature subsets based on a preset single-class support vector machine classifier to obtain a classification score for each of the electrical feature subsets;
[0142] The determination module 40 is configured to determine a target electrical feature subset based on the classification score, and determine a monitoring value of a to-be-monitored indicator of the target electrical appliance based on the target electrical feature subset.
[0143] It can be understood that the electrical appliance monitoring device of this embodiment corresponds to the electrical appliance monitoring method of the above embodiment, and the options in the above embodiment are also applicable to this embodiment, so they will not be described again here.
[0144] The present application also provides a computer device. Exemplarily, the computer device includes a processor and a memory, wherein the memory stores a computer program, and the processor runs the computer program to enable the computer device to execute the functions of the various modules in the above-mentioned electrical appliance monitoring method or the above-mentioned electrical appliance monitoring device.
[0145] Among them, the processor can be an integrated circuit chip with signal processing capabilities. The processor can be a general-purpose processor, including a central processing unit (CPU), a graphics processing unit (GPU) and a network processor (NP), a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or at least one of other programmable logic devices, discrete gate or transistor logic devices, and discrete hardware components. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc., which can implement or execute the disclosed methods, steps and logic block diagrams in the embodiments of the present application.
[0146] The memory may be, but is not limited to, a random access memory (RAM), a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), etc. The memory is used to store a computer program, and the processor may execute the computer program accordingly after receiving an execution instruction.
[0147] The present application also provides a computer storage medium for storing the computer program used in the above-mentioned computer device. The computer storage medium may be a readable storage medium, a non-volatile storage medium, or a volatile storage medium. For example, the computer storage medium may include, but is not limited to, various media that can store program code, such as a USB flash drive, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a magnetic disk, or an optical disk.
[0148] In the several embodiments provided in this application, it should be understood that the disclosed devices and methods can also be implemented in other ways. The device embodiments described above are merely schematic. For example, the flowcharts and structure diagrams in the accompanying drawings show the possible architectures, functions and operations of the devices, methods and computer program products according to the multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of the code, and the module, program segment or a part of the code contains one or more executable instructions for implementing the specified logical functions. It should also be noted that in an alternative implementation, the functions marked in the box can also occur in an order different from that marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the structure diagram and / or flowchart, and the combination of boxes in the structure diagram and / or flowchart, can be implemented using a dedicated hardware-based system that performs the specified function or action, or can be implemented using a combination of dedicated hardware and computer instructions.
[0149] In addition, the functional modules or units in the various embodiments of the present application can be integrated together to form an independent part, or each module can exist independently, or two or more modules can be integrated to form an independent part.
[0150] If the functions are implemented in the form of software function modules and sold or used as independent products, they can be stored in a readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or part of the technical solution, can be embodied in the form of a software product. The computer software product is stored in a storage medium and includes several instructions for enabling a computer device (which can be a smart phone, personal computer, server, or network device, etc.) to execute all or part of the steps of the method described in each embodiment of the present application.
[0151] The above is only a specific implementation method of the present application, but the scope of protection of the present application is not limited thereto. Any technician familiar with this technical field can easily think of changes or replacements within the technical scope disclosed in this application, which should be covered by the scope of protection of the present application.
Claims
1. An electrical appliance monitoring method, characterized in that: The method comprises: During the operation of the target electrical appliance, calculating a correlation score of each electrical feature of the target electrical appliance; Sorting the electrical features based on the correlation scores to obtain an electrical feature sequence, and generating a preset number of electrical feature subsets based on the electrical feature sequence; Classifying each of the electrical feature subsets based on a preset single-class support vector machine classifier to obtain a classification score for each of the electrical feature subsets; A target electrical feature subset is determined based on the classification score, and a monitoring value of a to-be-monitored indicator of the target electrical appliance is determined based on the target electrical feature subset.
2. The electrical appliance monitoring method according to claim 1, characterized in that: The step of calculating the relevance score of each electrical feature of the target electrical appliance comprises: For each electrical feature, determining a discriminative score of the current electrical feature based on a feature mean and a feature variance of the current electrical feature; determining a redundancy score for the current electrical feature based on the current electrical feature and each remaining electrical feature; A relevance score of the current electrical signature is determined based on the discriminability score and the redundancy score.
3. The electrical appliance monitoring method according to claim 2, characterized in that: The step of determining the discriminative score of the current electrical feature based on the feature mean and feature variance of the current electrical feature includes: Calculating an inter-class distance of the current electrical feature based on a feature mean of the current electrical feature and a preset first model; Calculating the intra-class distance of the current electrical feature based on the feature variance of the current electrical feature and a preset second model; A discriminability score of the current electrical feature is determined based on the inter-class distance and the intra-class distance.
4. The electrical appliance monitoring method according to claim 2, characterized in that: The step of determining a redundancy score of the current electrical feature based on the current electrical feature and each remaining electrical feature comprises: determining mutual information between the current electrical feature and each remaining electrical feature based on a joint probability density and a marginal probability density of the current electrical feature and each remaining electrical feature; determining a redundancy reference score between the current electrical feature and each remaining electrical feature based on the mutual information between the current electrical feature and each remaining electrical feature; The maximum redundancy reference score is determined as the redundancy score of the current electrical feature.
5. The electrical appliance monitoring method according to claim 1, characterized in that: The step of sorting the electrical features based on the correlation scores to obtain an electrical feature sequence, and generating a preset number of electrical feature subsets based on the electrical feature sequence includes: Sort the electrical features from largest to smallest based on the correlation score to obtain an electrical feature sequence; Based on the electrical feature sequence, each electrical feature is sequentially added to the electrical feature set until all the electrical features in the electrical feature sequence are added to the electrical feature set, thereby obtaining a preset number of electrical feature subsets.
6. The electrical appliance monitoring method according to claim 1, characterized in that: The step of classifying each electrical feature subset based on a preset single-class support vector machine classifier to obtain a classification score for each electrical feature subset includes: For each of the electrical feature subsets, classify the current electrical feature subset based on a preset single-class support vector machine classifier to determine normal electrical features and abnormal electrical features in the current electrical feature subset; A classification score of the current electrical feature subset is calculated based on the number of the normal electrical features and the number of the abnormal electrical features.
7. The electrical appliance monitoring method according to claim 1, characterized in that: The step of determining a target electrical feature subset based on the classification score comprises: Comparing the classification scores of each of the electrical feature subsets to determine the electrical feature subset with the largest classification score; The electrical feature subset with the largest classification score is determined as the target electrical feature subset.
8. An electrical appliance monitoring device, characterized in that: The electrical appliance monitoring device comprises: a calculation module, configured to calculate a correlation score of each electrical feature of the target electrical appliance during operation of the target electrical appliance; a generating module, configured to sort the electrical features based on the correlation scores to obtain an electrical feature sequence, and generate a preset number of electrical feature subsets based on the electrical feature sequence; a classification module, configured to classify each of the electrical feature subsets based on a preset single-class support vector machine classifier to obtain a classification score for each of the electrical feature subsets; A determination module is used to determine a target electrical feature subset based on the classification score, and to determine a monitoring value of a to-be-monitored indicator of the target electrical appliance based on the target electrical feature subset.
9. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores a computer program, and the processor is configured to execute the computer program to implement the electrical appliance monitoring method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that The computer-readable storage medium stores a computer program, and when the computer program is run on a processor, the electrical appliance monitoring method according to any one of claims 1 to 7 is executed.