Non-intrusive Load Monitoring Method Based on LSTM-GRU Ensemble Learning

Through the combination of LSTM-GRU integrated learning and time convolutional neural network, the problem of limiting load monitoring accuracy of a single model is solved, and high-precision non-invasive load monitoring is achieved, reducing hardware cost and installation complexity.

CN116430148BActive Publication Date: 2025-08-01SOUTHEAST UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310422211.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-19
Publication Date
2025-08-01
Estimated Expiration
2043-04-19

AI Technical Summary

Technical Problem

Existing non-invasive load monitoring systems are usually based on a single model, limiting the accuracy of load monitoring. How to improve monitoring effect through the combined effect of multiple models is the key.

Method used

The method based on LSTM-GRU integrated learning is adopted, combined with time convolutional neural network, and the regression sub-model and classification sub-model are constructed. The preliminary decomposition results of LSTM and GRU basic models are combined, and the BiTCN-Attention model is used for deep processing to improve the load monitoring accuracy.

Benefits of technology

Through the integrated learning method, the decomposition accuracy of non-invasive load monitoring is improved, the hardware cost and installation complexity are reduced, and it is suitable for home load monitoring.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116430148B_ABST
    Figure CN116430148B_ABST
Patent Text Reader

Abstract

Non-intrusive load monitoring method based on LSTM-GRU integrated learning, comprising the steps of: 1. Obtain the active power values of the user bus and the load; 2. Preprocess the collected data and pair them to form a data set; 3. Construct base models based on LSTM and GRU respectively, and train these two base models; 4. Use the two trained base models to respectively perform preliminary decomposition on the bus active power to obtain the preliminary decomposition values of the target load and combine them; 5. Construct an integrated model based on LSTM-GRU integrated learning, use the result of the previous step as the input of the model, and the active power of the target load as the output, and train the constructed meta-model based on LSTM-GRU integrated learning; 6. Obtain the data of the active power of the current target load according to the active power of the current bus. This method combines the advantageous performances of two based on LSTM and GRU, and forms a meta-model by integrating the BiTCN-Attention model and the classification sub-model, so as to improve the decomposition accuracy of the non-intrusive load monitoring model.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of non-intrusive electrical load monitoring, and specifically relates to a non-intrusive load monitoring method based on LSTM-GRU integrated learning. Background Art

[0002] In order to better assist residents in carrying out intelligent power consumption two-way interaction services, domestic technology companies and the government have invested in some important projects to continuously develop and promote the household power consumption monitoring system. However, initially when measuring and obtaining data on household appliances, many were monitored in an intrusive manner, that is, sensors with advanced communication functions were installed between each appliance and the distribution box. Although this method has high measurement accuracy, the installation or transformation of hardware will bring inconvenience to residents' lives, and the structure is often complex, the cost is high, and the later maintenance is also relatively cumbersome. Therefore, a non-intrusive load monitoring structure was proposed to fill this defect, which is equivalent to a one-to-many relationship. Take a single household as an example. If an intelligent electricity meter is installed at the entrance of the household, the electricity consumption information of the user can be collected, and the electricity consumption situation of each device can be obtained, thereby greatly reducing the hardware cost, facilitating installation, and being suitable for household load monitoring.

[0003] Regarding the non-intrusive load identification algorithm, the current non-intrusive power load intelligent identification system generally aggregates based on a single model, such as common deep learning models. This limits the accuracy of the load monitoring model. In other words, how to use multiple models to jointly act in the process of load monitoring to improve the load monitoring effect of the device is the current key issue. The present invention aims to achieve comprehensive optimization, and through the action of multiple models and the use of a temporal convolutional neural network, the load monitoring effect is improved. Summary of the Invention

[0004] To solve the above problems, the present invention proposes a non-intrusive load monitoring method based on LSTM-GRU integrated learning. On the basis of integrating the performance of the LSTM and GRU models, the performance of the regression sub-model and the classification sub-model is combined with the feature extraction ability of temporal convolution to improve the load monitoring effect.

[0005] To achieve the above object, the technical solution adopted by the present invention is:

[0006] A non-intrusive load monitoring method based on LSTM-GRU integrated learning, characterized by including the following steps:

[0007] Including:

[0008] 1) Obtain the measured values of the active power of the user's main bus and each load;

[0009] 2) Preprocess the active power of the user bus and the active power of each load in combination with the data situation, and pair them to form a data set;

[0010] 3) Construct a base model based on LSTM and a base model based on GRU. Respectively use the active power of the bus as the input of the model and the active power of the target load as the target output, and train the constructed base models based on LSTM and GRU respectively;

[0011] 4) Use the two trained base models to preliminarily decompose the active power of the bus respectively to obtain the preliminary decomposition values of the target load, and combine the preliminary decomposition results of the target load obtained by the two base models;

[0012] 5) Construct an integrated model based on LSTM-GRU integrated learning. Use the combined result of the preliminary decomposition results of the target load obtained by the two base models as the input of the model and the active power of the target load as the output, and train the constructed meta-model based on LSTM-GRU integrated learning;

[0013] 6) Decompose the active power of the current bus to obtain the data of the active power of the current target load.

[0014] As a further improvement of the present invention, in step 1) to obtain the active power of the user bus and each load, wherein the active power of the target load only needs to be measured during training, including: using an active power monitoring device to extract the active power data of each load and load cluster of the user at a frequency of times / minute, and arranging them in chronological order to obtain the active power of the user bus [p1, p2,..., p N and the active power of the i-th load

[0015] As a further improvement of the present invention, in step 2) preprocess the collected data, process the missing values in the time series data, and preprocess the previously obtained [p1, p2,..., p N and using the linear interpolation method. Assume that the missing point is at the t-th moment. Since the abscissa of the time series data is continuous, directly calculate the missing value as the average of the adjacent values on the left and right. Denoise the time series data using the rolling average method, p t = (a t-1 + a t-2 +... + a t-n ) / n, where p t represents the denoised value at the t-th moment, n represents the number of periods of the moving average, and a t-1 , a t-2 ,..., a t-nrespectively represent the actual values at the previous moment, the moment before the previous moment, and up to the previous n moments.

[0016] As a further improvement of the present invention, the dataset in step 2) includes:

[0017] Obtaining active power data of a specified length by a sliding window, including: setting the length of the time series data intercepted by the sliding window to be T, sorting the active power of the user bus and the active power of each load obtained by time in steps of 1 for sliding interception to form a training dataset, and the total length of the data is N.

[0018] Then the data for obtaining the active power of the user bus is:

[0019] The data for the active power of the i-th load is: The data of the working condition of the i-th load trained by the data of the classification sub-network is combined with the data of the active power of the i-th load and used in the formula α is a threshold value. If it exceeds the threshold value, it is determined that the i-th load is in the working state, otherwise it is in the non-working state. p represents the value of the active power. Substituting into the formula, we get

[0020] Pairing the active power of the user bus and the active power of each load to form a dataset, including:

[0021] Let the data of the active power of the user bus where x n is a vector of T, n = 1, 2,..., N - T + 1.

[0022] The data of the active power of the i-th load where is a vector of T, n = 1, 2,..., N - T + 1;

[0023] The data of the active power of the i-th load where is a vector of T, n = 1, 2,..., N - T + 1;

[0024] Then (x n , ) is the dataset of the active power of the user bus and the active power of each load paired, used for training the regression sub-network; (x n , ) is the dataset of the active power of the user bus and the working state of each load paired, used for training the classification sub-network, and the data is divided into a training set: a test set: a validation set in a ratio of 6:2:2.

[0025] As a further improvement of the present invention, in step 5), an integrated model based on LSTM-GRU integrated learning is constructed and trained, and the trained base models are respectively used to preliminarily decompose the bus active power, and the output results of the two base models are combined, including:

[0026] (5-1) Build a base model based on LSTM: The first and second layers use a convolutional neural network for preliminary feature extraction; the third layer network uses a bidirectional long short-term memory neural network. This neural network filters and screens data through selective memory and forgetting, and uses a bidirectional structure to combine the "past" and "future" information of the input data for feature extraction; the next two fully connected layers are used for regression data prediction to obtain the prediction result of the base model based on LSTM.

[0027]

[0028] (5-2) Build a base model based on GRU: The network structure of the base model based on GRU is the same as that of the base model based on LSTM except that the LSTM layer is replaced by a GRU layer, and the final decomposition result is

[0029]

[0030] (5-3) Train the model, use the Adma optimization algorithm to update the model parameters, and make the model reach the best convergence state;

[0031] (5-4) Use the trained base models based on LSTM and GRU to decompose the bus active power, and combine the decomposition results of the two base models, that is, superimpose them according to the corresponding positions, to obtain

[0032]

[0033] As a further improvement of the present invention, in step 5), the constructed integrated learning model integrates a regression sub-model and a classification sub-model to deeply process the results of the base model to obtain the final decomposition result, including:

[0034] (6-1) Build a regression sub-model:

[0035] The first layer network uses a bidirectional temporal convolutional neural network to perform overall extraction of the input time series data. This layer network is composed of multiple layers of networks superimposed. The main limitation of the temporal convolutional neural network is causal. When predicting the output at time t≤T, only the input from the same point and earlier times can be used, and dilated convolution is used to overcome the limitation that convolution can only look back at consecutive time steps, and the input is obtained from every d steps away from t, that is, x t-(k-1)d ,...,x t-2d ,x t-d ,x t, where d is the time step and k is the kernel size; at the same time, residual connections are used to ensure the long-term effectiveness of the data. The input is superimposed with the output of the previous layer of a certain layer below as the input of this layer, o = Activation(X + F(X)), where X represents the input, F(X) represents the input after passing through the above network layer, and Activation represents the activation function. Due to its causality, a bidirectional structure is used to make up for this problem; the second layer of the network uses a bidirectional long short-term memory neural network, and this neural network filters and screens the data through selective memory and forgetting; the third layer of the network uses an attention mechanism network, α t = softmax(e t ), where V a , W a and b a are attention parameters, and c is the input of the subsequence; the next two fully connected layers perform regression data prediction

[0036] (6-2) Build a classification sub-model: Use a three-layer convolutional neural network for feature extraction; the fourth layer uses bidirectional LSTM to extract front and back information; then two fully connected neural networks output classification predictions

[0037]

[0038] (6-3) Train the regression sub-model and the classification sub-model respectively;

[0039] (6-4) Combine the output results of the regression sub-model and the classification sub-model, ⊙ means multiplying the corresponding values at each time point to obtain the final result

[0040] This application has the following beneficial effects:

[0041] The present invention discloses a non-intrusive load monitoring method based on LSTM-GRU integrated learning. The method includes the steps of: obtaining the measured values of the active power of the user bus and each load; preprocessing the active power of the user bus and each load according to the data situation and pairing them to form a data set; constructing a base model based on LSTM and a base model based on GRU, respectively using the active power of the bus as the input of the model and the active power of the target load as the target output, and training the constructed base models based on LSTM and GRU respectively; using the two trained base models to respectively perform preliminary decomposition on the active power of the bus to obtain the preliminary decomposition values of the target load, and combining the preliminary decomposition results of the target load obtained by the two base models; constructing an integrated model based on LSTM-GRU integrated learning, using the result after combining the preliminary decomposition results of the target load obtained by the two base models as the input of the model and the active power of the target load as the output, and training the constructed meta-model based on LSTM-GRU integrated learning; obtaining the data of the active power of the current target load according to the active power of the current bus. This method improves the decomposition accuracy of the non-intrusive load monitoring model by combining the decomposition capabilities of two base models based on LSTM and GRU for different features and electrical loads, and applying the BiTCN-Attention model and the integrated action method of the regression sub-model and the classification sub-model to the integrated meta-model. Description of the Drawings

[0042] Figure 1 FIG. is a flowchart of a non-intrusive load monitoring model aggregation method provided in Embodiment 1 of the present invention;

[0043] Figure 2 FIG. is a framework of a preset base model based on LSTM and a base model based on GRU in a non-intrusive load monitoring model aggregation method provided in Embodiment 1 of the present invention;

[0044] Figure 3 FIG. is the overall model framework in a non-intrusive load monitoring method provided in Embodiment 1 of the present invention. Detailed Embodiment

[0045] The present invention will be further described in detail below in conjunction with the drawings and the specific embodiments:

[0046] The present invention discloses a non-intrusive load monitoring method based on LSTM-GRU integrated learning, where the flowchart is as Figure 1 shown, the framework of the preset base model based on LSTM and the base model based on GRU is as Figure 2 shown, and the overall model framework is as Figure 3 shown. Specifically, it includes the following steps:

[0047] Step 1: Obtain the active power of the user bus and each load. The active power of the target load only needs to be measured during training, including: using the active power monitoring device to extract the active power data of each load and load cluster of the user at a frequency of times per minute, arranging them in chronological order to obtain the active power of the user bus [p1, p2, …, p N and the active power of the i-th load

[0048] Step 2: Preprocess the collected data, process the missing values in the time series data, and preprocess the previously obtained [p1, p2, …, p N and using the linear interpolation method. Assume that the missing point is at the t-th moment. Since the abscissa of the time series data is continuous, directly calculate the missing value as the average of the adjacent values on the left and right. Denoise the time series data using the rolling average method. p t =(a t-1 +a t-2 +…+a t-n ) / n, where p t represents the denoised value at the t-th moment, n represents the number of periods of the moving average, and a t-1 , a t-2 , …, a t-n represent the actual values at the previous moment, the second previous moment, and so on until the n-th previous moment respectively.

[0049] Step 3: Compose the dataset, including:

[0050] Obtain the active power data of a specified length using a sliding window, including: setting the length of the time series data intercepted by the sliding window to be T, and gradually sliding and intercepting the active power of the user bus and each load obtained in chronological order with a step of 1 to form the training dataset. The total length of the data is N,

[0051] then the data for obtaining the active power of the user bus is:

[0052] The data for the active power of the i-th load is: The data on the working condition of the i-th load (trained with the data of the classification sub-network) combined with the data of the active power of the i-th load uses the formula where α is the threshold. If it exceeds the threshold, it is determined that the i-th load is in the working state, otherwise it is in the non-working state. p represents the value of the active power. Substitute into the formula to obtain

[0053] Pair the active power of the user bus and the active power of each load to form the dataset, including:

[0054] Data of the active power of the user bus where x n is a vector of T, n = 1, 2, …, N - T + 1,

[0055] Data of the active power of the i-th load where is a vector of T, n = 1, 2, …, N - T + 1;

[0056] Data of the operating state of the i-th load where is a vector of T, n = 1, 2, …, N - T + 1;

[0057] Then (x n , ) is a dataset of the pairing of the active power of the user bus and the active powers of each load, which is used for the training of the regression sub-network; (x n , ) is a dataset of the pairing of the active power of the user bus and the working states of each load, which is used for the training of the classification sub-network. The data is divided into a training set: a test set: a validation set in a ratio of 6:2:2.

[0058] Step 4: Build and train the base models based on LSTM and GRU, and respectively use the trained base models to preliminarily decompose the active power of the bus and combine the output results of the two base models, including:

[0059] (4-1) Build the base model based on LSTM: The first and second layers use a convolutional neural network for preliminary feature extraction; the third layer network uses a bidirectional long short-term memory neural network. This neural network filters and screens the data through selective memory and forgetting, and uses the bidirectional structure to combine the information of the input data "past" and "future" for feature extraction; the next two fully connected layers are used for regression data prediction to obtain the prediction result of the base model based on LSTM

[0060] (4-2) Build the base model based on GRU: The network structure of the base model based on GRU is the same as that of the base model based on LSTM except that the LSTM layer is replaced by a GRU layer, and the final decomposition result is

[0061] (4-3) Train the model, use the Adma optimization algorithm to update the model parameters to make the model reach the best convergence state.

[0062] (4-4) Use the trained base models based on LSTM and GRU to decompose the active power of the bus, and combine the decomposition results of the two base models, that is, stack them according to the corresponding positions to obtain

[0063] Step 5. Build an integrated learning model: Integrate the regression sub-model and the classification sub-model to deeply process the results of the base model to obtain the final decomposition result, including:

[0064] (5-1) Build the regression sub-model: The first-layer network uses a bidirectional temporal convolutional neural network to perform overall extraction of the input time-series data. This layer of network is composed of multiple layers of networks stacked. The main limitation of the temporal convolutional neural network's causality is that when predicting the output at time t ≤ T, only the inputs from the same point and earlier times can be used, and dilated convolution is used to overcome the limitation that convolution can only look back at consecutive time steps, obtaining inputs from every d steps away from t, that is, x t-(k-1)d ,...,x t-2d ,x t-d ,x t , where d is the time step and k is the kernel size; at the same time, residual connections are used to ensure the long-term effectiveness of the data. The input is superimposed with the output of the previous layer of a certain layer below as the input of this layer, o = Activation(X + F(X)), X represents the input, F(X) represents the input after passing through the above network layer, and Activation represents the activation function. Because of its causality, a bidirectional structure is used to make up for this problem; the second-layer network uses a bidirectional long short-term memory neural network to filter and screen the data through selective memory and forgetting; the third-layer network uses an attention mechanism network, α t = softmax(e t ), where V a , W a and b a are attention parameters, and c is the input of the subsequence; the next two fully connected layers are used to predict the regression data

[0065] (5-2) Build the classification sub-model: Use a three-layer convolutional neural network for feature extraction; the fourth layer uses a bidirectional LSTM for extracting front and back information; the next two fully connected neural networks output the classification prediction

[0066] (5-3) Train the regression sub-model and the classification sub-model respectively;

[0067] (5-4) Combine the output results of the regression sub-model and the classification sub-model, ⊙ represents multiplying the corresponding values at each time point to obtain the final result

[0068] The above are only the preferred embodiments of the present invention, and are not any other form of limitation to the present invention. Any modification or equivalent change made according to the technical essence of the present invention still belongs to the scope protected by the present invention.

Claims

1. A non-intrusive load monitoring method based on LSTM-GRU integrated learning, characterized in that It includes the following steps: It includes: 1) Obtain the measured values of the active power of the user bus and each load; 2) Preprocess the active power of the user bus and each load according to the data situation and pair them to form a data set; 3) Construct a base model based on LSTM and a base model based on GRU. Respectively use the active power of the bus as the input of the model and the active power of the target load as the target output, and train the constructed base models based on LSTM and GRU respectively; 4) Use the two trained base models to preliminarily decompose the active power of the bus to obtain the preliminary decomposition values of the target load, and combine the preliminary decomposition results of the target load obtained by the two base models; 5) Construct an integrated model based on LSTM-GRU integrated learning. Use the combined result of the preliminary decomposition results of the target load obtained by the two base models as the input of the model and the active power of the target load as the output, and train the constructed meta-model based on LSTM-GRU integrated learning; Build a regression sub-model: The first layer network uses a bidirectional temporal convolutional neural network to extract the overall input time series data. The second layer network uses a bidirectional long short-term memory neural network to filter and screen the data through selective memory and forgetting. The third layer network uses an attention mechanism network, and then two fully connected layers are used for regression data prediction; Build a classification sub-model: Use a three-layer convolutional neural network for feature extraction. The fourth layer uses a bidirectional LSTM to extract front and back information. Next, two fully connected neural networks output classification predictions; 6) Decompose according to the active power of the current bus to obtain the data of the active power of the current target load.

2. The non-intrusive load monitoring method based on LSTM-GRU integrated learning according to claim 1, wherein: Step 1) Obtain the active power of the user bus and each load, where the active power of the target load only needs to be measured during training, including: using the active power monitoring device to extract the active power data of each load and load cluster of the user at a frequency of times per minute, arranging them in chronological order to obtain the active power of the user bus and the active power of the i-th load .

3. The non-intrusive load monitoring method based on LSTM-GRU integrated learning according to claim 1, wherein: In step 2), the collected data is preprocessed to handle the missing values in the time series data. The previously obtained and are preprocessed. The linear interpolation method is adopted. Assuming that the missing point occurs at the t-th moment, since the abscissa of the time series data is continuous, the missing value is directly calculated as the average of the adjacent values on the left and right. The time series data is denoised by using the rolling average method. , represents the denoised value at the t-th moment, n represents the number of periods for the moving average, respectively represent the actual values at the previous moment, the second previous moment, and up to the n-th previous moment.

4. The non-intrusive load monitoring method based on LSTM-GRU integrated learning according to claim 1, wherein: The data set in step 2) includes: Obtain active power data of a specified length using a sliding window, including: setting the length of the time series data intercepted by the sliding window to be T, and slidingly intercepting the active power of the user bus and the active power of each load obtained in time order step by step with a step size of 1 to form a training data set, and the total data length is N, Then the data of the user's bus active power obtained is as follows: , The data of the active power of the i-th load is as follows: , the data of the working condition of the i-th load trained by the data of the classification sub-network is combined with the data of the active power of the i-th load and used in the formula , is the threshold value. If it exceeds the threshold value, it is determined that the i-th load is in the working state, otherwise it is in the non-working state. represents the value of the active power, and substituting it into the formula obtains ; Pair the active power of the user bus and the active power of each load to form a data set, including: The data of the active power of the user bus , where x n is a vector with T, and n = 1, 2, …, N - T + 1 Data of the active power of the i-th load , where is a vector of T, and n = 1, 2, …, N - T + 1; Data of the active power of the i-th load , where is a vector T, and n = 1, 2, …, N - T + 1; Then (x n , ) is a dataset in which the active power of the user bus is paired with the active power of each load, and is used for the training of the regression sub-network; (x n , ) is a dataset in which the active power of the user bus is paired with the working status of each load, and is used for the training of the classification sub-network. The data is divided into a training set: a test set: a validation set in a ratio of 6:2:

2.

5. The non-intrusive load monitoring method based on LSTM-GRU integrated learning according to claim 1, wherein: In step 5), construct an integrated model based on LSTM-GRU integrated learning and train it, and respectively use the trained base models to preliminarily decompose the active power of the bus and combine the output results of the two base models, including: (5-1) Build a basic model based on LSTM: The first and second layers use convolutional neural networks for preliminary feature extraction; the third layer uses a bidirectional long short-term memory neural network. This neural network filters and screens data through selective memory and forgetting, and uses a bidirectional structure to combine the "past" and "future" information of the input data for feature extraction; the next two fully connected layers are used for regression data prediction to obtain the prediction results of the basic model based on LSTM. ; (5-2) Build a GRU-based base model: The network structure of the GRU-based base model is the same as that of the LSTM-based base model except that the LSTM layer is replaced by the GRU layer, and the final decomposition result is ; (5-3) Train the model, use the Adma optimization algorithm to update the model parameters, and make the model reach the best convergence state; (5-4) Decompose the bus active power using the trained base models based on LSTM and GRU, and combine the decomposition results of the two base models, that is, superimpose them according to the corresponding positions, to obtain 。 6. The non-intrusive load monitoring method based on LSTM-GRU integrated learning according to claim 1, characterized in that: The step 5) constructs an integrated model based on LSTM-GRU integrated learning, including: Build a regression sub-model: The first - layer network uses a bidirectional temporal convolutional neural network for the overall extraction of input time - series data. This layer of network is composed of multiple layers stacked. The main limitation of the causal nature of the temporal convolutional neural network is that when predicting the output at time only the inputs from the same point and earlier times can be used, and dilated convolutions are used to overcome the limitation that convolutions can only look back at consecutive time steps, obtaining inputs at every d steps from a distance t, that is , where d is the time step and k is the kernel size; at the same time, residual connections are used to ensure the long - term validity of the data, adding the input and the output of the layer above the previous layer below as the input of this layer, , represents the input, represents the input after passing through the above network layer, represents the activation function. Due to its causal nature, a bidirectional structure is used to compensate for this problem; the second - layer network uses a bidirectional long short - term memory neural network to filter and screen data through selective memory and forgetting; the third - layer network uses an attention mechanism network, , , , where , and are attention parameters, is the input of the subsequence; the next two fully - connected layers are used for regression data prediction ; Build a classification sub-model: Use a three-layer convolutional neural network for feature extraction; Use a bidirectional LSTM for the extraction of front and back information in the fourth layer; Next are two fully connected neural networks to output the prediction of classification ; Train the regression sub-model and the classification sub-model respectively; The regression sub-model and the classification sub-model are combined for the output results, , indicating that the values corresponding to each time point are multiplied to obtain the final result .

Citation Information

Patent Citations

  • Non-intrusive load monitoring using machine learning and processed training data

    CN113557537A

  • Non-intrusive load decomposition method based on clustering and CNN-BiGRU algorithm

    CN115828126A