CN112180152A - Load switch event detection method and system by means of mean shift clustering - Google Patents
Load switch event detection method and system by means of mean shift clustering Download PDFInfo
- Publication number
- CN112180152A CN112180152A CN202011068018.7A CN202011068018A CN112180152A CN 112180152 A CN112180152 A CN 112180152A CN 202011068018 A CN202011068018 A CN 202011068018A CN 112180152 A CN112180152 A CN 112180152A
- Authority
- CN
- China
- Prior art keywords
- signal sequence
- value
- window
- load switch
- switch event
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Withdrawn
Links
Images
Classifications
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01R—MEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
- G01R21/00—Arrangements for measuring electric power or power factor
-
- G—PHYSICS
- G01—MEASURING; TESTING
- G01R—MEASURING ELECTRIC VARIABLES; MEASURING MAGNETIC VARIABLES
- G01R31/00—Arrangements for testing electric properties; Arrangements for locating electric faults; Arrangements for electrical testing characterised by what is being tested not provided for elsewhere
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Power Engineering (AREA)
- Complex Calculations (AREA)
Abstract
The embodiment of the invention discloses a load switch event detection method and a system by using mean shift clustering, wherein the method comprises the following steps: step 101, acquiring a signal sequence S acquired according to a time sequence; step 102, generating N window signal sequences; step 103, performing iterative initialization; step 104, iterative updating; step 105, ending the iteration; step 106 of obtaining the mean shift grouping value HK(ii) a Step 107 for obtaining a threshold for determining a load switch event0(ii) a Step 108 detects a load switch event.
Description
Technical Field
The invention relates to the field of electric power, in particular to a load switch event detection method and system.
Background
With the development of smart grids, the analysis of household electrical loads becomes more and more important. Through the analysis of the power load, a family user can obtain the power consumption information of each electric appliance and a refined list of the power charge in time; the power department can obtain more detailed user power utilization information, can improve the accuracy of power utilization load prediction, and provides a basis for overall planning for the power department. Meanwhile, the power utilization behavior of the user can be obtained by utilizing the power utilization information of each electric appliance, so that the method has guiding significance for the study of household energy consumption evaluation and energy-saving strategies.
The current electric load decomposition is mainly divided into an invasive load decomposition method and a non-invasive load decomposition method. The non-invasive load decomposition method does not need to install monitoring equipment on internal electric equipment of the load, and can obtain the load information of each electric equipment only according to the total information of the electric load. The non-invasive load decomposition method has the characteristics of less investment, convenience in use and the like, so that the method is suitable for decomposing household load electricity.
In the non-invasive load decomposition algorithm, the detection of the switching event of the electrical equipment is the most important link. The initial event detection takes the change value of the active power P as the judgment basis of the event detection, and is convenient and intuitive. This is because the power consumed by any one of the electric devices changes, and the change is reflected in the total power consumed by all the electric devices. Besides the need to set a reasonable threshold for the power variation value, this method also needs to solve the problem of the event detection method in practical application: a large peak (for example, a motor starting current is much larger than a rated current) appears in an instantaneous power value at the starting time of some electric appliances, so that an electric appliance steady-state power change value is inaccurate, and the judgment of a switching event is influenced, and the peak is actually pulse noise; moreover, the transient process of different household appliances is long or short (the duration and the occurrence frequency of impulse noise are different greatly), so that the determination of the power change value becomes difficult; due to the fact that the active power changes suddenly when the quality of the electric energy changes (such as voltage drop), misjudgment is likely to happen. The intensity of (impulse) noise is large and background noise has a large impact on the correct detection of switching events.
Load switching events that are now commonly used are often determined using changes in power data: when the power change value exceeds a preset threshold value, a load switch event is considered to occur. This approach, while simple and easy to implement, results in a significant drop in the accuracy of the switching event detection due to the impulse noise and the common use of non-linear loads.
Therefore, in the switching event detection process, how to improve the switching event detection accuracy is very important. Load switch event detection is the most important step in energy decomposition, and can detect the occurrence of an event and determine the occurrence time of the event. However, the accuracy of the detection of the switching event is greatly affected by noise in the power signal (power sequence), and particularly, impulse noise generally exists in the power signal, which further affects the detection accuracy. Therefore, it is currently a very important task to effectively improve the detection accuracy of the load switch event.
Disclosure of Invention
Load switching events that are now commonly used are often determined using changes in power data: when the power change value exceeds a preset threshold value, a load switch event is considered to occur. This approach, while simple and easy to implement, results in a significant drop in the accuracy of the switching event detection due to the impulse noise and the common use of non-linear loads.
The invention aims to provide a load switch event detection method and system by means of mean shift grouping. The method has good switching event detection performance and is simple in calculation.
In order to achieve the purpose, the invention provides the following scheme:
a method of load switch event detection using mean shift clustering, comprising:
step 101, acquiring a signal sequence S acquired according to a time sequence;
step 102 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nmeans taking K-M + N modulo NThe remainder;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
step 103, performing iterative initialization, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
step 104, iterative updating, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is the mean of the signal sequence S;
xkthe k step value of the offset value;
and step 105, ending iteration, specifically: adding 1 to the value of the iteration control parameter k, and returning to the step 104 and the step 105 for iterative updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Step 106 of obtaining the mean shift grouping value HKThe method specifically comprises the following steps:
step 107 for obtaining a threshold for determining a load switch event0The method specifically comprises the following steps:
step 108, detecting a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
A load switch event detection system using mean shift clustering, comprising:
the module 201 acquires a signal sequence S acquired in time sequence;
the module 202 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nthe remainder is obtained by taking N as a modulus to K-M + N;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
module 203 iteratively initializes, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
module 204 iteratively updates, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is the mean of the signal sequence S;
xkthe k step value of the offset value;
the module 205 ends the iteration, specifically: adding 1 to the value of the iteration control parameter k, and returning to the module 204 and the module 205 for iteration updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Module 206 evaluates the mean shift clustering value HKThe method specifically comprises the following steps:
module 207 finds the load switch event decision threshold0The method specifically comprises the following steps:
the module 208 detects a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
According to the specific embodiment provided by the invention, the invention discloses the following technical effects:
load switching events that are now commonly used are often determined using changes in power data: when the power change value exceeds a preset threshold value, a load switch event is considered to occur. This approach, while simple and easy to implement, results in a significant drop in the accuracy of the switching event detection due to the impulse noise and the common use of non-linear loads.
The invention aims to provide a load switch event detection method and system by means of mean shift grouping. The method has good switching event detection performance and is simple in calculation.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the embodiments will be briefly described below. It is obvious that the drawings in the following description are only some embodiments of the invention, and that for a person skilled in the art, other drawings can be derived from them without inventive effort.
FIG. 1 is a schematic flow diagram of the process of the present invention;
FIG. 2 is a schematic flow chart of the system of the present invention;
FIG. 3 is a flow chart illustrating an embodiment of the present invention.
Detailed Description
The technical solution in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention. It is to be understood that the described embodiments are merely exemplary of the invention, and not restrictive of the full scope of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
FIG. 1 is a flow diagram of a method for load switch event detection using mean-shift clustering
Fig. 1 is a flow chart illustrating a load switch event detection method using mean shift clustering according to the present invention. As shown in fig. 1, the method for detecting a load switch event by mean shift clustering specifically includes the following steps:
step 101, acquiring a signal sequence S acquired according to a time sequence;
step 102 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nthe remainder is obtained by taking N as a modulus to K-M + N;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
step 103, performing iterative initialization, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
step 104, iterative updating, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is the mean of the signal sequence S;
xkthe k step value of the offset value;
and step 105, ending iteration, specifically: adding 1 to the value of the iteration control parameter k, and returning to the step 104 and the step 105 for iterative updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Step 106 of obtaining the mean shift grouping value HKThe method specifically comprises the following steps:
step 107 for obtaining a threshold for determining a load switch event0The method specifically comprises the following steps:
step 108, detecting a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
FIG. 2 structural intent of a load switch event detection system using mean shift clustering
FIG. 2 is a block diagram of a system for load switch event detection using mean shift clustering in accordance with the present invention. As shown in fig. 2, the load switch event detection system using mean shift clustering includes the following structure:
the module 201 acquires a signal sequence S acquired in time sequence;
the module 202 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nthe remainder is obtained by taking N as a modulus to K-M + N;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
module 203 iteratively initializes, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
module 204 iteratively updates, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is the mean of the signal sequence S;
xkthe k step value of the offset value;
the module 205 ends the iteration, specifically: adding 1 to the value of the iteration control parameter k, and returning to the module 204 and the module 205 for iteration updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Module 206 evaluates the mean shift clustering value HKThe method specifically comprises the following steps:
module 207 finds the load switch event decision threshold0The method specifically comprises the following steps:
the module 208 detects a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
The following provides an embodiment for further illustrating the invention
FIG. 3 is a flow chart illustrating an embodiment of the present invention. As shown in fig. 3, the method specifically includes the following steps:
step 301, acquiring a signal sequence S acquired according to a time sequence;
step 302 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nthe remainder is obtained by taking N as a modulus to K-M + N;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
step 303, performing iterative initialization, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
step 304, iterative updating, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is the mean of the signal sequence S;
xkthe k step value of the offset value;
ending the iteration of step 305, specifically: the value of the iteration control parameter k is added by 1, and the steps are returned to the step 304 and the step 305Iteratively updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Step 306 of obtaining the mean shift grouping value HKThe method specifically comprises the following steps:
step 307 for obtaining a threshold for determining a load switch event0The method specifically comprises the following steps:
step 308, detecting a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
The embodiments in the present description are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other. For the system disclosed by the embodiment, the description is simple because the system corresponds to the method disclosed by the embodiment, and the relevant part can be referred to the method part for description.
The principles and embodiments of the present invention have been described herein using specific examples, which are provided only to help understand the method and the core concept of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, the specific embodiments and the application range may be changed. In view of the above, the present disclosure should not be construed as limiting the invention.
Claims (2)
1. A method for load switch event detection using mean shift clustering, comprising:
step 101, acquiring a signal sequence S acquired according to a time sequence;
step 102 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nthe remainder is obtained by taking N as a modulus to K-M + N;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
step 103, performing iterative initialization, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
step 104, iterative updating, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is the mean of the signal sequence S;
xkthe k step value of the offset value;
and step 105, ending iteration, specifically: adding 1 to the value of the iteration control parameter k, and returning to the step 104 and the step 105 for iterative updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Step 106 of obtaining the mean shift grouping value HKThe method specifically comprises the following steps:
step 107 for obtaining a threshold for determining a load switch event0The method specifically comprises the following steps:
step 108, detecting a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
2. A load switch event detection system using mean shift clustering, comprising:
the module 201 acquires a signal sequence S acquired in time sequence;
the module 202 generates N window signal sequences, specifically: the Kth window signal sequence is BKThe nth element is marked asThe formula is obtained as
Wherein:
k is 1,2, N is a window serial number;
n is 1,2, and N is the element number;
n is the length of the signal sequence S;
|K-M+n|Nthe remainder is obtained by taking N as a modulus to K-M + N;
*: represents any independent variable;
σ0: the mean square error of the signal sequence S;
SNR: the signal-to-noise ratio of the signal sequence S;
module 203 iteratively initializes, specifically:
k is an iteration control parameter with an initialization value of 1
q is the window element number, and is randomly selected from 1, 2. cndot., 2M
module 204 iteratively updates, specifically:
wherein: i is 1, 2M is the sequence number of the updating element;
z is 1, 2M is an intermediate parameter;
mKfor the Kth window signal sequence BKThe mean value of (a);
m0is a stand forThe mean value of the signal sequence S;
xkthe k step value of the offset value;
the module 205 ends the iteration, specifically: adding 1 to the value of the iteration control parameter k, and returning to the module 204 and the module 205 for iteration updating until the difference between the results of two adjacent iterations satisfies | xk-xk-1If | ≦ 0.001, then the iterative control parameter K ═ K is determinedOObtaining the relative offset value of the window
Module 206 evaluates the mean shift clustering value HKThe method specifically comprises the following steps:
module 207 finds the load switch event decision threshold0The method specifically comprises the following steps:
the module 208 detects a load switch event, specifically:
if the mean shift clustering value H of the Kth windowK≥0Detecting a load switch event at the Kth point of the signal sequence S; otherwise, no load switch event is detected.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011068018.7A CN112180152A (en) | 2020-10-08 | 2020-10-08 | Load switch event detection method and system by means of mean shift clustering |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202011068018.7A CN112180152A (en) | 2020-10-08 | 2020-10-08 | Load switch event detection method and system by means of mean shift clustering |
Publications (1)
Publication Number | Publication Date |
---|---|
CN112180152A true CN112180152A (en) | 2021-01-05 |
Family
ID=73949182
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202011068018.7A Withdrawn CN112180152A (en) | 2020-10-08 | 2020-10-08 | Load switch event detection method and system by means of mean shift clustering |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN112180152A (en) |
-
2020
- 2020-10-08 CN CN202011068018.7A patent/CN112180152A/en not_active Withdrawn
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109145825B (en) | Coherent noise filtering method and system | |
CN111680590A (en) | Power signal filtering method and system by using contraction gradient | |
CN111666870A (en) | Power signal reconstruction method and system by utilizing quadratic constraint | |
CN108918929B (en) | Power signal self-adaptive filtering method in load decomposition | |
CN110221119B (en) | Load switch event detection method and system based on power and akie fusion information | |
CN112434567B (en) | Power signal filtering method and system by using noise jitter property | |
CN109241874A (en) | Power signal filtering method in Energy Decomposition | |
CN110244115B (en) | Load switch event detection method and system based on signal connectivity | |
CN112180152A (en) | Load switch event detection method and system by means of mean shift clustering | |
CN111830405A (en) | Load switch event detection method and system by using frequency difference | |
CN110196354B (en) | Method and device for detecting switching event of load | |
CN110702981A (en) | Load switch event detection method and system using classification tree | |
CN110749841A (en) | Load switch event detection method and system by utilizing conversion space factor | |
CN112257576B (en) | Load switch event detection method and system using Maha distance measure | |
CN112307986B (en) | Load switch event detection method and system by utilizing Gaussian gradient | |
CN112329637B (en) | Load switch event detection method and system by using mode characteristics | |
CN111737645A (en) | Power signal reconstruction method and system by using prediction matrix | |
CN111832474A (en) | Power signal filtering method and system by using energy scale | |
CN112180153A (en) | Load switch event detection method and system by using KULLBACK-Leibler distance | |
CN112180155A (en) | Load switch event detection method and system using tight support set | |
CN112270282B (en) | Power signal filtering method and system by utilizing matrix spectral mode | |
CN112347922B (en) | Power signal filtering method and system by using Hankerl matrix | |
CN112180154A (en) | Load switch event detection method and system optimized by using confidence coefficient | |
CN110726870A (en) | Load switch event detection method and system based on data purity | |
CN112287786A (en) | Load switch event detection method and system by using random factor |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
WW01 | Invention patent application withdrawn after publication | ||
WW01 | Invention patent application withdrawn after publication |
Application publication date: 20210105 |