SDP-BiLSTM-based short-term day-ahead load prediction model and prediction method

By introducing the SDP-BiLSTM model in short-term load prediction, using the double-layer BiLSTM and the scaling dot-product attention mechanism to analyze meteorological and load information, the problems of low accuracy and poor stability of traditional prediction methods are solved, and the power load prediction is significantly improved Accuracy and stability.

CN119202667AActive Publication Date: 2024-12-27国网黑龙江省电力有限公司鹤岗供电公司 +2
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202411350502.7
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-09-26
Publication Date
2024-12-27
Estimated Expiration
2044-09-26

AI Technical Summary

Technical Problem

Traditional short-term pre-date load prediction methods have low prediction accuracy and poor stability, which cannot meet the needs of complex power grid environments.

Method used

Using a short-term pre-date load prediction model based on SDP-BiLSTM, the NWP sequence of predicted dates and the power load sequence of historical dates are featured through the feature extraction layer and the SDP attention layer, and the two-layer BiLSTM and scaling dot product attention are used. The mechanism analyzes the correlation between meteorological and load information to improve prediction accuracy.

Benefits of technology

The accuracy and stability of short-term power load prediction are significantly improved, and important features are extracted by dynamically analyzing the correlation between meteorological and historical load information, and the prediction results are optimized.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119202667A_ABST
    Figure CN119202667A_ABST
Patent Text Reader

Abstract

The invention discloses a short-term day-ahead load prediction model and prediction method based on SDP-BiLSTM, and belongs to the field of power system load prediction. The problems that a traditional short-term day-ahead load prediction method is low in prediction precision and poor in stability are solved. A feature extraction layer comprises two double-layer BiLSTMs, feature extraction is carried out on an NWP sequence and a power load sequence respectively, and feature vectors Hnwp and Hload are obtained; the SDP attention layer performs linear transformation on the Hnwp and the Hload to convert the Hnwp and the Hload into a query vector Q, a key vector K and a value vector V; carrying out dot product on Q and K to obtain a dot product score matrix, carrying out softmax function scaling to obtain a vector omega, carrying out dot product on the vector omega and V to obtain an intermediate vector C, and carrying out feature fusion on C and Hnwp by adopting a splicing mode to obtain HSDP; and the output layer is used for sequentially carrying out feature extraction and full connection operation on the HSDP to realize load sequence prediction. The method is mainly used for power load prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of power system load forecasting, and in particular relates to a short-term day-ahead load forecasting model based on SDP-BiLSTM. Background Art

[0002] Short-term day-ahead load forecasting is a classic and important requirement of the power system to ensure the balance of power supply and demand, guarantee power supply security, and optimize power dispatch. It plays a key role in ensuring the safe and economical operation of regional power grids and improving the utilization efficiency of new energy. Accurate day-ahead load forecasting is of great significance to the safe, stable and economical operation of the power system.

[0003] Traditional forecasting methods can no longer match the actual situation of the increasingly complex power system, and more accurate and stable methods are urgently needed to meet the short-term forecasting needs in complex power grid environments. With the development of artificial intelligence, the combination of power load forecasting and machine learning has become a hot academic topic, and the use of machine learning to study short-term power load forecasting has become a new idea. Summary of the invention

[0004] The purpose of the present invention is to solve the problems of low prediction accuracy and poor stability of traditional short-term day-ahead load forecasting methods; the present invention provides a short-term day-ahead load forecasting model and a forecasting method based on SDP-BiLSTM.

[0005] The short-term day-ahead load forecasting model based on SDP-BiLSTM includes:

[0006] The feature extraction layer includes two double-layer BiLSTMs, which are used to extract features from the forecast date NWP sequence and the historical date power load sequence, respectively, and the corresponding feature vector H is obtained. nwp and the eigenvector H load ;

[0007] The SDP attention layer is used to transform the feature vector H nwp Transform it into query vector Q through linear transformation, and also use it to transform feature vector H load Perform two linear transformations of different scales to transform them into key vector K and value vector V respectively; calculate the dot product score matrix by dot product of query vector Q and key vector K, and scale them by softmax function to get vector ω. The dot product of vector ω and value vector V is calculated to get intermediate vector C, which is then combined with feature vector H nwp The feature fusion is performed by splicing to obtain the feature vector H SDP ;

[0008] The output layer is used to transform the feature vector H SDPFeature extraction and full connection operations are performed in sequence to obtain the power load sequence corresponding to the forecast date.

[0009] Preferably,

[0010] Q=MLP1(H nwp )=H nwp ·W Q ;

[0011] K=MLP 2a (H load )=H load ·W K ;

[0012] V=MLP 2b (H load )=H load ·W V ;

[0013] Among them, MLP1(·), MLP 2a (·) and MLP 2b (·) are the linear transformations performed on the first to third perceptron layers, respectively. Q , W K , W V The scale-matched weight matrices obtained by back-propagating the first to third perceptron layers respectively.

[0014] Preferably,

[0015]

[0016] in, s is the scaling factor, d K is the dimension of the key vector K, (·) T is transposed.

[0017] Preferably, for the feature vector H SDP LSTM is used to extract features.

[0018] Preferably, the forecast date NWP sequence is a sequence consisting of all-day meteorological data on the forecast date, and the historical date power load sequence is a sequence consisting of power load data corresponding to consecutive historical dates.

[0019] The power load forecasting method implemented by the short-term day-ahead load forecasting model based on SDP-BiLSTM comprises the following steps:

[0020] S1. Obtain a load-meteorological characteristic data set, wherein the input data of each sample in the load-meteorological characteristic data set is a power load sequence of consecutive historical dates and a NWP sequence of a forecast date, and the output data is a power load sequence corresponding to the forecast date;

[0021] S2, using the load-meteorological characteristic data set to train the load forecasting model;

[0022] S3. Use the trained load-meteorological characteristic data set to predict the power load on the predicted date.

[0023] Preferably, step S1, obtaining the load-meteorological characteristic data set is implemented as follows:

[0024] S11. Obtain historical load data set and NWP data set;

[0025] S12, preprocessing the historical load data set;

[0026] S13. Decompose the historical load data set by discrete Fourier method to determine the length of the sampling time window, analyze the historical load data set and NWP data set by Pearson correlation coefficient analysis method, screen out the NWP data set that is strongly correlated with the load, and merge it with the preprocessed historical load data set to obtain the load-meteorological characteristic data set.

[0027] Preferably, the data set is preprocessed by correcting outliers, filling missing values, and performing normalization.

[0028] A power load forecasting device includes a memory, a processor, and a computer program stored in the memory and executable on the processor. The processor executes the computer program to implement a power load forecasting method using a short-term day-ahead load forecasting model based on SDP-BiLSTM.

[0029] A computer-readable storage medium stores a computer program, and when the computer program is executed, a power load forecasting method implemented by using a short-term day-ahead load forecasting model based on SDP-BiLSTM is implemented.

[0030] The beneficial effects brought by the present invention are:

[0031] The present invention provides a short-term day-ahead load forecasting model and forecasting method based on SDP-BiLSTM. The model introduces a scaled dot product attention mechanism into BiLSTM, so that the model can not only use the ability of LSTM to capture the time dependency in sequence data, but also dynamically analyze the correlation between NWP information and historical load information through the attention mechanism, extract important features, and effectively improve the accuracy of short-term power load forecasting. BRIEF DESCRIPTION OF THE DRAWINGS

[0032] Figure 1It is a schematic diagram of the principle of the short-term day-ahead load forecasting model based on SDP-BiLSTM described in the present invention;

[0033] Figure 2 It is a line chart comparing the prediction results of the prediction model of the present invention (ie, the SDP-BiLSTM model) and the actual load value. DETAILED DESCRIPTION

[0034] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0035] It should be noted that, in the absence of conflict, the embodiments of the present invention and the features in the embodiments may be combined with each other.

[0036] See also Figure 1 This embodiment describes the short-term day-ahead load forecasting model based on SDP-BiLSTM described in this embodiment. The load forecasting model includes:

[0037] The feature extraction layer includes two double-layer BiLSTMs, which are used to extract features from the forecast date NWP sequence and the historical date power load sequence, respectively, and the corresponding feature vector H is obtained. nwp and the eigenvector H load ;

[0038] The SDP attention layer is used to transform the feature vector H nwp Transform it into query vector Q through linear transformation, and also use it to transform feature vector H load Perform two linear transformations of different scales to transform them into key vector K and value vector V respectively; calculate the dot product score matrix by dot product of query vector Q and key vector K, and scale them by softmax function to get vector ω. The dot product of vector ω and value vector V is calculated to get intermediate vector C, which is then combined with feature vector H nwp The feature fusion is performed by splicing to obtain the feature vector H SDP ;

[0039] The output layer is used to transform the feature vector H SDP Feature extraction and full connection operations are performed in sequence to obtain the power load sequence corresponding to the forecast date.

[0040] Specifically, the forecast date NWP sequence is a sequence composed of all-day meteorological data on the forecast date, and the historical date power load sequence is a sequence composed of power load data corresponding to consecutive historical dates. The meteorological data contained in the NWP sequence include 36 meteorological elements such as temperature, relative humidity, snowfall, precipitation, ground pressure, cloud coverage, wind speed, and wind direction; the time resolution of NWP information is 1 hour.

[0041] In this implementation, the scaled dot product attention mechanism is introduced into BiLSTM, so that the model can not only use the ability of LSTM to capture the time dependency in the sequence data, but also dynamically analyze the correlation between NWP information and historical load information through the attention mechanism, extract important features, and effectively improve the accuracy of short-term power load forecasting. NWP is the full name of Numerical Weather Forecast in English, and its Chinese translation is numerical weather forecast.

[0042] Specifically, the present invention uses a double-layer BiLSTM in the prior art, and the double-layer BiLSTM includes two BiLSTMs connected in series, and each BiLSTM includes a forward LSTM layer and a backward LSTM layer. The forward LSTM layer processes the sequence from the first time step, and updates its hidden state and unit state time by time step. At each time step, the LSTM layer updates the state through its internal gating mechanism (input gate, forget gate, output gate) and generates an output; the backward LSTM layer reversely processes from the last time step of the sequence, and also updates its hidden state and unit state time by time step. The update process of the backward LSTM layer is similar to that of the forward LSTM, but it processes the reverse order of the sequence; at each time step, the outputs of the forward and backward LSTM layers are merged, usually by splicing the output vectors in two directions; after passing through the LSTM layer, the merged state can be sent to one or more fully connected layers to perform the final prediction task, and the parameters of the output layer will also be updated during the training process;

[0043] The LSTM layer updates the state through its internal gating mechanism (input gate, forget gate, output gate) and generates the output expression as follows:

[0044]

[0045] Among them, C t is the forget gate, σ is the sigmoid function, W f , W i , W c , W o is the weight coefficient, b f is the bias parameter, [h t-1 ,x t] is the output h at the previous moment t-1 and the current time x t A new vector connected; i t is the input gate, is the current input unit state, b i , b c , b o is the bias parameter, tanh is the hyperbolic function, C t is the unit state at the current moment, C t-1 is the unit state at the previous moment, t is the output gate, h t is the output.

[0046] Compared with the original LSTM network, the Bi-LSTM network adds a hidden layer that can transfer information backward, transforming the unidirectional LSTM layer into a bidirectional LSTM layer, and more effectively learns the load-meteorological factor characteristics in a bidirectional manner, which is conducive to improving the accuracy of short-term power load forecasting. The formula of the Bi-LSTM output gate is:

[0047] output:h (f&b)t =g(W f h ft +W b h bt + b);

[0048] Among them, h ft and h bt Represent the load forecasting results of the forward and backward LSTM layers at time t respectively; W f and W b are the weight coefficients of the forward and backward LSTM layers, b is the output bias matrix, and h (f&b)t The final output of Bi-LSTM is weighted and merged through the activation function g.

[0049] Furthermore, for the eigenvector H SDP LSTM is used to extract features.

[0050] Furthermore, Q = MLP1 (H nwp )=H nwp ·W Q ;

[0051] K=MLP 2a (H load )=H load ·W K ;

[0052] V=MLP 2b (H load )=H load ·WV ;

[0053] Among them, MLP1(·), MLP 2a (·) and MLP 2b (·) are the linear transformations performed on the first to third perceptron layers, respectively. Q , W K , W V The scale-matched weight matrices obtained by back-propagating the first to third perceptron layers respectively.

[0054] Furthermore, in order to stabilize the gradient and avoid entering the gradient vanishing region when the softmax function is scaled and normalized, the expression of the vector ω is:

[0055]

[0056] in, s is the scaling factor, d K is the dimension of the key vector K, (·) T is transposed.

[0057] Specific implementation method II, see Figure 1 This embodiment describes the power load forecasting method implemented by the short-term day-ahead load forecasting model based on SDP-BiLSTM described in the specific embodiment 1. The method includes the following steps:

[0058] S1. Obtain a load-meteorological characteristic data set, wherein the input data of each sample in the load-meteorological characteristic data set is a power load sequence of consecutive historical dates and a NWP sequence of a forecast date, and the output data is a power load sequence corresponding to the forecast date;

[0059] S2, using the load-meteorological characteristic data set to train the load forecasting model;

[0060] S3. Use the trained load-meteorological characteristic data set to predict the power load on the predicted date.

[0061] The forecast date NWP sequence is a sequence composed of all-day meteorological data on the forecast date, and the historical date power load sequence is a sequence composed of power load data corresponding to consecutive historical dates. Specifically, the optimal number of consecutive historical dates is 7 days.

[0062] Furthermore, the implementation method of step S1, obtaining the load-meteorological characteristic data set is as follows:

[0063] S11. Obtain historical load data set and NWP data set;

[0064] S12, preprocessing the historical load data set; specifically, the preprocessing method of the data set is: correcting outliers, filling missing values, and performing normalization processing;

[0065] S13. Decompose the historical load data set by discrete Fourier method to determine the sampling time window length, analyze the historical load data set and NWP data set by Pearson correlation coefficient analysis method, screen out the NWP data set that is strongly correlated with the load, and merge it with the pre-processed historical load data set to obtain the load-meteorological characteristic data set. Among them, the sampling time window length is 7 days for the continuous historical date time length.

[0066] Specific implementation method three: An electric power load forecasting device described in this implementation method includes a memory, a processor, and a computer program stored in the memory and executable on the processor. The processor executes the computer program to implement the electric power load forecasting method using the short-term day-ahead load forecasting model based on SDP-BiLSTM as described in specific implementation method two.

[0067] Specific implementation method 4: This implementation method describes a computer-readable storage medium, in which a computer program is stored. When the computer program is executed, the power load forecasting method implemented by using the short-term day-ahead load forecasting model based on SDP-BiLSTM as described in specific implementation method 2 is implemented.

[0068] Verification test:

[0069] Three evaluation indicators commonly used to evaluate the performance of short-term power load forecasting models are adopted: Root Mean Squared Error (RMSE), Mean Absolute Error (MAE) and Mean Absolute Percentage Error (MAPE) to evaluate the performance of the prediction model of the present invention (i.e., the SDP-BiLSTM model); the historical load-NWP data test set is input into the SDP-BiLSTM model and other 12 control group models, and the generalization performance of the prediction model and the multi-angle analysis of the prediction results are completed to verify the effectiveness of the present invention.

[0070] The performance evaluation index results of the prediction model of the present invention (ie, SDP-BiLSTM model) and the 12 models are shown in Table 1:

[0071] Table 1 Performance comparison of different models on various indicators

[0072]

[0073]

[0074] From the analysis of Table 1, it can be seen that the performance of the SDP-BiLSTM model proposed in the present invention in time series modeling of various evaluation indicators exceeds that of other comparative models. Specifically, it shows a significant positive improvement of 9.36% to 53.49% in the RMSE indicator and 9.43% to 55.77% in the MAE indicator. The RMSE, MAE and 1-MAPE values ​​predicted by the SDP-BiLSTM model of the present invention are 23.05, 18.05 and 94.49% respectively. The three indicators are significantly better than other comparative models, which verifies the feasibility and effectiveness of the prediction model of the present invention in short-term load forecasting.

[0075] Figure 2 The historical load data comes from a prefecture-level city in Heilongjiang Province located in the buffer zone between Lesser Khingan Mountains and Sanjiang Plain. The power load data from January to October 2023 is

[0076] Depend on Figure 2 It can be seen that the load forecasting result of the load forecasting model described in this embodiment has a trend of tracking the original data and has high forecasting accuracy.

[0077] Although the present invention is described herein with reference to specific embodiments, it should be understood that these embodiments are merely examples of the principles and applications of the present invention. It should therefore be understood that many modifications may be made to the exemplary embodiments and that other arrangements may be devised without departing from the spirit and scope of the present invention as defined by the appended claims. It should be understood that the various dependent claims and features described herein may be combined in a manner different from that described in the original claims. It should also be understood that features described in conjunction with individual embodiments may be used in other described embodiments.

Claims

1. The short-term day-ahead load forecasting model based on SDP-BiLSTM is characterized by: The load forecasting model includes: The feature extraction layer includes two double-layer BiLSTMs, which are used to extract features from the forecast date NWP sequence and the historical date power load sequence, respectively, and the corresponding feature vector H is obtained. nwp and the eigenvector H load ; The SDP attention layer is used to transform the feature vector H nwp Transform it into query vector Q through linear transformation, and also use it to transform feature vector H load Perform two linear transformations of different scales to transform them into key vector K and value vector V respectively; calculate the dot product score matrix by dot product of query vector Q and key vector K, and scale them by softmax function to get vector ω. The dot product of vector ω and value vector V is calculated to get intermediate vector C, which is then combined with feature vector H nwp The feature fusion is performed by splicing to obtain the feature vector H SDP ; The output layer is used to transform the feature vector H SDP Feature extraction and full connection operations are performed in sequence to obtain the power load sequence corresponding to the forecast date.

2. The short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 1 is characterized in that: Q=MLP1(H nwp )=H nwp ·W Q ; K=MLP 2a (H load )=H load ·W K ; V=MLP 2b (H load )=H load ·W V ; Among them, MLP1(·), MLP 2a (·) and MLP 2b (·) are the linear transformations performed on the first to third perceptron layers, respectively. Q , W K , W V The scale-matched weight matrices obtained by back-propagating the first to third perceptron layers respectively.

3. The short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 1 is characterized in that: in, s is the scaling factor, d K is the dimension of the key vector K, (·) T is transposed.

4. The short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 1 is characterized in that: For the eigenvector H SDP LSTM is used to extract features.

5. The short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 1 is characterized in that: The forecast date NWP sequence is a sequence composed of all-day meteorological data on the forecast date, and the historical date power load sequence is a sequence composed of power load data corresponding to consecutive historical dates.

6. The power load forecasting method implemented by the short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 1 is characterized in that: The method comprises the following steps: S1. Obtain a load-meteorological characteristic data set, wherein the input data of each sample in the load-meteorological characteristic data set is a power load sequence of consecutive historical dates and a NWP sequence of a forecast date, and the output data is a power load sequence corresponding to the forecast date; S2, using the load-meteorological characteristic data set to train the load forecasting model; S3. Use the trained load-meteorological characteristic data set to predict the power load on the predicted date.

7. The power load forecasting method implemented by using the short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 6 is characterized in that: Step S1, obtaining the load-meteorological characteristic data set is implemented as follows: S11. Obtain historical load data set and NWP data set; S12, preprocessing the historical load data set; S13. Decompose the historical load data set by discrete Fourier method to determine the length of the sampling time window, analyze the historical load data set and NWP data set by Pearson correlation coefficient analysis method, screen out the NWP data set that is strongly correlated with the load, and merge it with the preprocessed historical load data set to obtain the load-meteorological characteristic data set.

8. The power load forecasting method implemented by the short-term day-ahead load forecasting model based on SDP-BiLSTM according to claim 7 is characterized in that: The data set is preprocessed by correcting outliers, filling missing values, and normalizing them.

9. A power load forecasting device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: The processor executes the computer program to implement the power load forecasting method implemented by using the short-term day-ahead load forecasting model based on SDP-BiLSTM as described in any one of claims 6 to 8.

10. A computer-readable storage medium, characterized in that: The storage medium stores a computer program, which, when executed, implements a power load forecasting method implemented by using a short-term day-ahead load forecasting model based on SDP-BiLSTM as described in any one of claims 6 to 8.

Citation Information

Patent Citations

  • Short-term power load and carbon emission prediction method and system based on DCNN-LSTM-AE-AM

    CN115936185A

  • Lithium ion battery degradation track and residual life prediction method, medium and equipment

    CN118294840A

  • Household electricity short-term load prediction method and system

    CN118586559A