Non-intrusive load decomposition method based on gating circulation unit
By adopting a non-invasive load decomposition method based on gated cyclic units in the power system, combining the generation of adversarial network and gated cyclic unit network, the problem of insufficient decomposition accuracy of the difference method is solved, and more efficient and accurate load decomposition is achieved.
Patent Information
- Application Number
- CN202411853862.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-16
- Publication Date
- 2025-03-25
AI Technical Summary
When the existing difference method is used for load decomposition in power systems, there is a problem of insufficient current waveform decomposition accuracy.
The non-invasive load decomposition method based on gated cyclic units is adopted to convert the load decomposition problem into a denoising problem. By combining the generative adversarial network (GAN) and the gated cyclic unit network (GRU), a GRU-GAN load decomposition model is constructed to achieve efficient decomposition of the target load current.
It improves the accuracy and efficiency of load decomposition, and can more accurately decompose individual load currents in the total current, improving the effectiveness of power system management and optimization.
Smart Images

Figure CN119691360A_ABST
Abstract
Description
Technical Field
[0001] The invention relates to the technical field of power system planning and analysis, in particular to a non-intrusive load decomposition method based on a gated cycle unit. Background Art
[0002] With the development of smart grids, the widespread use of advanced measurement systems and smart meters has improved the efficiency of power management, and the transformation of power grid regulation has become particularly important. Real-time and more detailed user power consumption information can help energy suppliers accurately predict power demand and better provide flexible resources.
[0003] The difference method is usually used to decompose the current waveform of the target load from the total current, but the difference method has the problem of insufficient accuracy in decomposing the current waveform. The non-invasive load decomposition method is a technology that analyzes the total load curve of the entire power system and decomposes it into the power consumption of a single device or load. This method does not require individual monitoring or measurement of each load, but relies on mathematical models and algorithms to infer the energy consumption of each device. This method can provide high decomposition accuracy and efficiency, which is of great significance for the management and optimization of power systems. Summary of the invention
[0004] The present invention provides a non-intrusive load decomposition method based on a gated cyclic unit, which converts the load decomposition problem into a denoising problem, that is, removing non-target load current from the total current, thereby completing the decomposition of the target load current, and is used to solve the problem of insufficient decomposition accuracy of the difference method.
[0005] The technical solution adopted by the present invention to solve the technical problem is: a non-intrusive load decomposition method based on a gated cycle unit, comprising the following steps:
[0006] S1. Load decomposition
[0007] When N loads are in operation at the same time, the total current at time t is expressed as:
[0008]
[0009] Where i(t) is the total current at time t, i k (t) is the current of the kth load, i δ (t) is noise interference;
[0010] S2. Building a Generative Adversarial Network (GAN)
[0011] In order to decompose the target load current i η(t), denoise the total current i(t) and obtain a reconstructed current The generator G receives the total current i(t) and generates the reconstructed current The discriminator D receives the target load current i η (t) and generate reconstruction current Output target load current i η The probability D(i) of the truth of (t) η (t)) and reconstruction current The probability of authenticity Its structure is as Figure 1 As shown;
[0012] S3. Build a Gated Recurrent Unit (GRU) network
[0013] The gated recurrent unit is an improved recurrent neural network. Its basic structure includes two gates: update gate z t and reset gate r t ;
[0014] Reset Gate t The formula is:
[0015]
[0016] Where W r is the weight matrix, x t Enter information for the current moment, h t-1 is the hidden state at time t-1, σ is the sigmoid function;
[0017] r t Substitute the value of into the candidate hidden state In the formula, the candidate hidden state The formula is:
[0018]
[0019] Where tanh is the tanh function, W h is the weight matrix, which converts the current data into a value ranging from -1 to 1 through the tanh function;
[0020] Update gate z t The formula is:
[0021] z t =σ(W z ·[h t-1 ,x t ]) (4)
[0022] Where W z is the weight matrix;
[0023] Update the memory expression to:
[0024]
[0025] In the formula, h t is the hidden state passed to time t; S4, constructing the GRU-GAN network decomposition model
[0026] In the GAN network, the gated recurrent unit module is used to replace the traditional encoding layer and decoding layer to obtain the GRU-GAN load decomposition network model.
[0027] The formula in step S1 can only express the various current relationships in the total current, and cannot decompose the target current. Steps S2 and S3 introduce the introduction and function of the basic model. Step S4 combines the two models S2 and S3 to build the model of the present invention, treating the current other than the target load current as interference current, analyzing the characteristics of the target current through encoding and decoding of the model, extracting the implicit time information in the sequence, generating the target current, and separating the results obtained through the model.
[0028] i η (t) is the target load current, and the total current is the sum of the target load current and other currents. Formula (1) can be written as:
[0029] i(t)=i η (t)+i β (t)(6)
[0030]
[0031] In the formula, i η (t) is the current of the target load; i β (t) is the interference current, which is the superposition of the current of other loads other than the target load current and the noise interference.
[0032] The loss function of GAN consists of two parts: the loss of the generator G and the loss of the discriminator D.
[0033] (1) The loss function of the discriminator D represents its ability to distinguish the target current from the reconstructed current. The goal of the discriminator D is to maximize the following formula:
[0034]
[0035] (2) The loss function of generator G represents its ability to generate reconstructed current. The goal of generator G is to maximize
[0036]
[0037] The GRU-GAN load decomposition model consists of a GRU encoder and a GAN to achieve efficient reconstruction of the target current and deep feature extraction. The encoder of the model consists of two layers of GRU and one layer of Dropout. The first layer of GRU processes one-dimensional feature input, extracts time-dependent information, and enhances the generalization ability of the model. The second layer of GRU generates the final hidden state as the input of the generator to generate a reconstructed current similar to the target current. The discriminator continuously improves its discrimination ability by judging the difference between the true target current and the generated reconstructed current, prompting the generator to generate a more realistic reconstructed current. The output activation function uses the Sigmoid function. The GRU-GAN model effectively integrates the advantages of time series analysis and adversarial learning, and improves the accuracy and reliability of load decomposition.
[0038] In order to improve the efficiency of the model, we use a sliding window to select data, take the data of 5 consecutive current cycles as input, and the corresponding reconstructed current as output, forming a sequence-to-sequence Seq2Seq GRU-GAN structure. This method improves data utilization efficiency, enhances the model's understanding of time series patterns, and can accurately capture the dynamic changes of current data. Through the sliding window, we generate rich reconstructed currents and improve the diversity and generalization ability of the model. The two-layer GRU encoding model maps the input sequence to a vector space of smaller dimensions and extracts important features, including changing trends and potential laws. The generator generates a reconstructed current similar to the target current from the low-dimensional vector output by the encoder, while the discriminator evaluates the similarity between the generated result and the true target load current, and continuously optimizes the generated output through the adversarial learning mechanism.
[0039] In the GRU-GAN model training process, the mean square error loss MSE is used as the loss function, and its formula is:
[0040]
[0041] In the formula, i t represents the target load current, Represents the reconstructed current of the target load.
[0042] During the model training phase, different load decompositions need to be trained separately. The total current is used as the input of the entire model, and the output is the desired target load current. Therefore, different load decompositions require different models to be constructed. A series of load decomposition models are obtained according to the number of loads that need to be decomposed. Through this process, the current of each load corresponding to the total current can be obtained.
[0043] The beneficial effect of the present invention is that the present invention uses the generative adversarial network (GAN) framework to reconstruct the load decomposition problem and defines it as a denoising problem. Since GAN cannot extract the time dimension characteristics of the current series, GRU has the advantage of being suitable for processing long sequence data and can effectively preserve and utilize the historical information and time series characteristics in the time series data. Therefore, by combining GAN and GRU, that is, the input of the generator G of GAN is used as the output of GRU, the original GAN network is improved, and the GRU-GAN load decomposition model is obtained. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 This is the structure diagram of the adversarial network;
[0045] Figure 2 Schematic diagram of the unit structure of GRU;
[0046] Figure 3 This is the GRU-GAN network model diagram;
[0047] Figure 4 It is a decomposition diagram based on GRU-GAN;
[0048] Figure 5 This is the total current waveform during the appliance startup process. DETAILED DESCRIPTION
[0049] The present invention performs denoising on each load current based on the idea of generative adversarial networks, thereby achieving load decomposition. First, a single load current is regarded as a clean current, and the total current is regarded as a current with noise interference. The time dimension characteristics of the target current are obtained using a gated recurrent unit network, and the input and output data are synchronously processed through a sliding window method to construct a model with a sequence-to-sequence Seq2Seq structure to achieve efficient and accurate mapping of the total current to a single load current. Based on the determination of the time when the switching event occurs, the total current waveform before and after the event is decomposed into individual load current waveforms. The specific implementation methods of the present invention are described in detail below:
[0050] A non-intrusive load decomposition method based on gated recurrent units comprises the following steps:
[0051] S1. Load decomposition
[0052] Load decomposition is to decompose the total current into the independent current of each load. According to the current superposition principle, the total current in the main circuit is composed of the current of each load in the circuit. When N loads are in operation at the same time, the total current at time t is expressed as:
[0053]
[0054] Where i(t) is the total current at the current moment, i k (t) is the current of the kth load, i δ (t) is noise interference. The present invention transforms this process into a denoising problem to obtain accurate information about each load current. The target load current is regarded as a clean current, and the total current is regarded as the superposition of the target load current and the interference current, then equation (1) is written as:
[0055] i(t)=i η (t)+i β (t) (2)
[0056]
[0057] In the formula, i η (t) is the current of the target load; i β (t) is the interference current, which is the superposition of the current of other loads except the target load current and the noise interference.
[0058] S2. Generative Adversarial Network
[0059] like Figure 1 As shown in Figure 1, GAN is a deep learning model for unsupervised learning, which consists of a generator G and a discriminator D. The generator G receives random noise as input, which is usually a vector sampled from a standard normal distribution, and tries to generate samples similar to the distribution of training data. The discriminator D receives the target current and the reconstructed current as input and tries to distinguish them. The purpose of GAN is to restore the original, undamaged target current i by training the total current i(t). η (t), separate the interference current from the data and reconstruct a reconstructed current without the interference current
[0060] The present invention is to decompose the target load current i η (t), denoise the total current i(t) and obtain a reconstructed target current The generator G receives the total current i(t) and generates the reconstructed current The discriminator D receives the target load current i η (t) and reconstruction current Output target load current i η The probability D(i) of the truth of (t) η (t)) and reconstruction current The probability of authenticity
[0061] The goal of GAN is to make the data samples generated by generator G as realistic as possible through adversarial training between generator G and discriminator D, making it difficult for discriminator D to distinguish between real data and generated data. The loss function of GAN consists of two parts: the loss of generator G and the loss of discriminator D.
[0062] (1) The loss function of the discriminator D represents its ability to distinguish between real samples and generated samples. The goal of the discriminator D is to maximize the following formula:
[0063]
[0064] (2) The loss function of the generator G represents its ability to generate realistic samples. The goal of the generator G is to maximize
[0065]
[0066] The workflow of GAN is:
[0067] (1) Initialize the parameters θ of the generator G and the discriminator D G and θ D θ G Refers to the initial weight parameters and bias parameters of the generator G, θ D Refers to the initial weight parameters and bias parameters of the discriminator D;
[0068] (2) Training the discriminator D: According to the target load i η (t), the total current i(t) and the generated reconstruction current Update the discriminator D to maximize the log-likelihood:
[0069]
[0070] (3) Training generator G: Based on the total current i(t), update generator G to maximize the log-likelihood:
[0071]
[0072] (4) Through adversarial training, the generator G continuously improves the fidelity of the reconstructed current, and the discriminator D continuously improves its ability to distinguish between the reconstructed current and the target current. Finally, the generator G generates a highly realistic reconstructed current.
[0073] S3. Introducing the Gated Recurrent Unit Network
[0074] The gated recurrent unit (GRU) network is a variant of the recurrent neural network. It performs well in processing long time series while avoiding the gradient vanishing or gradient exploding problems in the training process of ordinary recurrent neural networks. In the load decomposition task, since a large amount of current data and corresponding labels need to be processed for model training, the GRU model is more suitable for handling load decomposition problems. This model solves the long-term dependency problem by introducing gated units in the cell structure. These gated units include update gates and reset gates.
[0075] like Figure 2 As shown, x t Enter information for the current moment, h t-1 is the hidden state at time t-1, h t is the hidden state passed to time t, is the candidate hidden state, r t is the reset gate, z t is the update gate, σ is the sigmoid function, which converts the data into a value in the range of 0 to 1; tanh is the tanh function, which converts the data into a value in the range of -1 to 1.
[0076] The gated recurrent unit (GRU) is an improved recurrent neural network (RNN) with fewer parameters and better performance. Its basic structure consists of two gates: update gate z t (update gate) and reset gate r t (reset gate).
[0077] Reset Gate t : Determines how to combine new input information with previous memory. Reset gate r t The formula is:
[0078] r t =σ(W r ·[h t-1 ,x t ]) (8)
[0079] Where W r is the weight matrix. Reset gate r t The calculation is based on the weight matrix W r x t and h t-1 The concatenated matrix is linearly transformed, the above two matrices are multiplied, and the multiplied value is input into the sigmoid function to obtain r t The value of r t The value of needs to be substituted into the candidate hidden state formula. The candidate hidden state formula is:
[0080]
[0081] Update gate z t : It is used to control the extent to which the state information at time t-1 is brought into the current state, that is, to update the gate z t Helps the model decide whether to pass the information at time t-1 to time t for updating memory. Update gate z t The formula is:
[0082] z t =σ(W z ·[h t-1 ,x t ]) (10)
[0083] Update the memory expression to:
[0084]
[0085] S4. Constructing GRU-GAN decomposition model
[0086] The present invention uses the GRU-GAN model to solve the load decomposition problem. Because GAN cannot learn the characteristics of the current sequence, the GAN model is improved. Load decomposition requires that the sampling frequency of the current is usually high and the amount of current data is large, while GRU can effectively capture the long-term and short-term dependencies in the time series data and adapt to different load modes. It can also adaptively adjust the input and hidden states, which helps to extract key features from the load data. Therefore, GAN and GRU are combined, and an encoder is constructed through the GRU model as the input of GAN, thereby improving the generation ability of the GAN model and obtaining a GRU-GAN load decomposition model, such as Figure 3 shown.
[0087] The GRU-GAN load decomposition model consists of a GRU encoder and a GAN to achieve efficient reconstruction of the target current and deep feature extraction. The encoder of the model consists of two layers of GRU and one layer of Dropout. The first layer of GRU processes one-dimensional feature input, extracts time-dependent information, and enhances the generalization ability of the model. The second layer of GRU generates the final hidden state as the input of the generator to generate a reconstructed current similar to the target current. The discriminator continuously improves its discrimination ability by judging the difference between the true target current and the generated reconstructed current, prompting the generator to generate a more realistic reconstructed current. The output activation function uses the Sigmoid function. The GRU-GAN model effectively integrates the advantages of time series analysis and adversarial learning, and improves the accuracy and reliability of load decomposition.
[0088] In order to improve the efficiency of the model, we use a sliding window to select data, take the data of 5 consecutive current cycles as input, and the corresponding reconstructed current as output, forming a sequence-to-sequence Seq2Seq GRU-GAN structure. This method improves data utilization efficiency, enhances the model's understanding of time series patterns, and can accurately capture the dynamic changes of current data. Through the sliding window, we generate rich training samples and improve the diversity and generalization ability of the model. The two-layer GRU encoding model maps the input sequence to a vector space of smaller dimensions and extracts important features, including change trends and potential laws. The generator generates a reconstructed sequence similar to the target current from the low-dimensional vector output by the encoder, while the discriminator evaluates the similarity between the generated result and the true target load current, and continuously optimizes the generated output through the adversarial learning mechanism.
[0089] In the GRU-GAN model training process, the mean square error loss MSE is used as the loss function, and its formula is:
[0090]
[0091] In the formula, i t represents the target load current, represents the reconstructed current of the target load; n is the number of current data in the sliding window.
[0092] During the model training phase, different load decompositions need to be trained separately. The total current is used as the input of the entire model, and the output is the desired target load current. Therefore, different load decompositions require different models to be constructed. A series of load decomposition models are obtained according to the number of loads that need to be decomposed. Figure 4 As shown, through this process, the current of each load corresponding to the total current can be obtained.
[0093] like Figure 5 As shown, taking this total current as an example, the current at the position marked "on" changes. By analyzing the current before and after the change, we can decompose which load currents are included in the total current. The total current before and after the change is selected based on the current change. Assume that the change is at t n The transient process of the load is relatively long, so t n The current does not reach a steady state in the 10 cycles before and after the current cycle, so the current from t n-20 to n-10 The 10-cycle current data, and the n+10 to n+20 This selection method can effectively improve the accuracy of current decomposition and reduce the interference caused by load transient processes.
Claims
1. A non-intrusive load decomposition method based on gated cyclic units, characterized in that: The following steps are involved: S1. Load decomposition When N loads are in operation at the same time, the total current at time t is expressed as: Where i(t) is the total current at time t, i k (t) is the current of the kth load, i δ (t) is noise interference; S2. Build Generative Adversarial Network GAN To decompose the target load current i η (t), denoise the total current i(t), and the generator G receives the total current i(t) and generates a reconstructed current The discriminator D receives the target load current i η (t) and generate reconstruction current Output target load current i η The probability D(i) of the truth of (t) η (t)) and reconstruction current The probability of authenticity S3. Constructing the Gated Recurrent Unit Network GRU will reset the gate r t The formula is defined as: r t =σ(W r ·[h t-1 ,x t ]) (2) Where W r is the weight matrix, x t Enter information for the current moment, h t-1 is the hidden state at time t-1, σ is the sigmoid function; r t Substitute the value of into the candidate hidden state In the formula, the candidate hidden state The formula is: Where tanh is the tanh function, W h is the weight matrix, which converts the current data into a value ranging from -1 to 1 through the tanh function; Will update gate z t The formula is defined as: z t =σ(W z ·[h t-1 ,x t ]) (4) Where W z is the weight matrix; Update the memory expression to: In the formula, h t is the hidden state passed to time t; S4. Construct GRU-GAN network decomposition model In the GAN network, the gated recurrent unit module is used to replace the traditional encoding layer and decoding layer to obtain the GRU-GAN load decomposition network model; i η (t) is the target load current, and the total current is the sum of the target load current and other currents. Formula (1) can be written as: i(t)=i η (t)+i β (t) (6) In the formula, i η (t) is the current of the target load; i β (t) is the interference current, which is the superposition of the current of other loads other than the target load current and the noise interference.
2. A non-intrusive load decomposition method based on gated cyclic units according to claim 1, characterized in that: The loss function of GAN consists of two parts: the loss of the generator G and the loss of the discriminator D; (1) The loss function of the discriminator D represents its ability to distinguish the target current from the reconstructed current. The goal of the discriminator D is to maximize the following formula: (2) The loss function of generator G represents its ability to generate reconstructed current. The goal of generator G is to maximize 3. A non-intrusive load decomposition method based on gated cyclic units according to claim 2, characterized in that: The GRU-GAN load decomposition model consists of a GRU encoder and a GAN to achieve efficient reconstruction and deep feature extraction of the target current.
4. The non-intrusive load decomposition method based on gated cyclic units according to claim 3, characterized in that: The GRU encoder consists of two layers of GRU and one layer of Dropout. The first layer of GRU processes one-dimensional feature input, extracts time-dependent information, and enhances the generalization ability of the model. The second layer of GRU generates the final hidden state as the input of the generator to generate a reconstructed current similar to the target current.
5. The non-intrusive load decomposition method based on gated cyclic units according to claim 4, characterized in that: The discriminator continuously improves its discrimination ability by judging the difference between the real target current and the generated reconstructed current, prompting the generator to generate a more realistic reconstructed current. The output activation function adopts the Sigmoid function.
6. The non-intrusive load decomposition method based on gated cyclic units according to claim 5, characterized in that: A sliding window is used to select data, and the data of 5 consecutive current cycles are taken as input, and the corresponding reconstructed current is taken as output, forming a sequence-to-sequence Seq2Seq GRU-GAN structure.
7. The non-intrusive load decomposition method based on gated cyclic units according to claim 6, characterized in that: In the GRU-GAN model training process, the mean square error loss MSE is used as the loss function, and its formula is: In the formula, i t represents the target load current, Represents the reconstructed current of the target load.