Short-term wind power prediction method of Bi-MGLSTM model based on VMD decomposition and Bayesian optimization
Through VMD decomposition and Bayesian optimization Bi-MGLSTM model, the problems of low accuracy and poor timeliness in traditional wind power power prediction methods are solved, and higher prediction accuracy and stability are achieved, through variational modal decomposition and bidirectional The combination of LSTM models processes nonlinear signals and optimizes hyperparameters, reducing prediction errors.
Patent Information
- Application Number
- CN202411065399.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-05
- Publication Date
- 2024-12-27
- Estimated Expiration
- Not applicable · inactive patent
AI Technical Summary
Traditional wind power power prediction methods have problems such as low accuracy, poor timeliness, and model overfitting, which are difficult to effectively solve the uncertainty and nonlinear characteristics of wind power power.
Using the Bi-MGLSTM model based on VMD decomposition and Bayesian optimization, a Bi-MGLSTM model can significantly reduce the prediction error of wind power through data preprocessing, variational modal decomposition, bidirectional LSTM model expansion, hyperparameter optimization and error correction. Short-term prediction method.
Improve the accuracy and robustness of short-term wind power power prediction, extract stationary modal components through VMD decomposition, Bi-MGLSTM model enhances information screening ability, Bayesian optimization adjusts hyperparameters, error correction model reduces noise sensitivity, and achieves more High prediction accuracy and stability.
Smart Images

Figure CN119204714A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of short-term wind power prediction, and in particular, relates to a short-term wind power prediction method based on a Bi-MGLSTM model of VMD decomposition and Bayesian optimization. Background Art
[0002] The intermittent and variable characteristics of wind power bring great challenges to wind power forecasting. For the research on short-term wind power forecasting, scholars at home and abroad have proposed many forecasting methods. Traditional wind power forecasting methods can be roughly divided into three categories: statistical methods, physical modeling methods and hybrid methods. Statistical methods are based on historical data and statistical models for prediction. Common statistical methods include regression analysis, time series analysis and machine learning algorithms. Such as support vector machines, random forests, gated cyclic unit networks, etc.; physical modeling methods are based on modeling based on physical principles such as wind farms and wind turbines. However, it usually requires accurate meteorological data and wind turbine parameters, which is relatively complex; hybrid methods are a combination of statistical methods and physical modeling methods to improve the accuracy and reliability of predictions. These traditional methods have certain applications in wind power forecasting, but there are also some limitations and challenges. Due to the uncertainty and nonlinearity of wind power, these methods may have problems such as low accuracy, poor timeliness, and model overfitting when used for prediction. Summary of the invention
[0003] The technical problem to be solved by the present invention is to provide a short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization, which can significantly reduce the wind power prediction error and improve the accuracy of short-term wind power prediction.
[0004] In order to solve the above technical problems, the technical solution adopted by the present invention is: a short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization, comprising the following steps: S1. Data preprocessing, including obtaining a short-term wind power data set and filling in missing data, and normalizing the filled wind power data; S2. Perform variational modal decomposition on the completed wind power data and determine the number of decomposition layers L, and finally obtain M relatively stable subsequence modal components; S3, adding one more forget gate and one more input gate to the forward and backward LSTM of the BiLSTM model, constructing a Bi-MGLSTM model, and inputting the M modal components decomposed in step S2 into the Bi-MGLSTM model for power prediction; S4. Use the Bayesian algorithm to optimize the hyperparameters of the Bi-MGLSTM model, including the initial learning rate, the number of training batches, and the number of hidden units, to obtain an optimized Bi-MGLSTM model. S5. The prediction results of each modal component are obtained through the optimized Bi-MGLSTM model, and then the preliminary power prediction results are obtained by superposition reconstruction; S6, error correction model: the initial power prediction value is subtracted from the true value, and the error sequence is trained and predicted using the optimized Bi-MGLSTM model to obtain the error prediction result; S7. Add the power prediction value and the error prediction value to obtain the final prediction result.
[0005] In a preferred solution, in step S1, the missing data is supplemented using the front and back mean method.
[0006] In the preferred solution, the front and back mean method takes the average value of the five data before and after the missing data to complete the missing data, and the expression is: (1); In the formula, is the power missing value; After missing values Power value; Before the missing value A power value.
[0007] In a preferred solution, in step S2, variational modal decomposition is performed on the completed wind power data, and the operation is as follows: Variational mode decomposition is to construct and solve the variational problem so that the sum of the decomposition bandwidths of each mode is minimized. The expression is as follows: (2); (3); Where: is the total number of decomposed modal components; is the unit of the imaginary part of a complex number; is the unit pulse function; is the convolution operator; is the number of decomposed modes; and are the mode set and the mode center frequency set respectively; is the original time series data signal.
[0008] In the preferred solution, in step S3, the constructed Bi-MGLSTM model adds one more forget gate and one more input gate in the forward and backward LSTM of the BiLSTM model. The functions of the two additional gates are the same as the original gate functions. The total forget gate and input gate of a single MGLSTM are calculated as follows: (4); In the formula, , are forget gate 1 and forget gate 2, , are input gate 1 and input gate 2, for t The output of the input layer at time t, for t The output of the hidden layer at time -1, is the weight matrix corresponding to different forget gates and input gates, is the training bias corresponding to each gate, are sigmoid and relu activation functions.
[0009] Final hidden layer output The calculation formula is: (5); In the formula, are the weights and biases corresponding to the output gate and unit cells, for t The cell state at the moment and the temporary state of the cell, is the hyperbolic tangent function.
[0010] In a preferred solution, in step S4, the hyperparameters of the Bi-MGLSTM model are optimized using a Bayesian algorithm, including the following method: Determine the value range of the hyperparameter combination Z, select the hyperparameter value, and input it into the Bi-MGLSTM model while performing hyperparameter optimization. The formula is: (6); In the formula, The optimal hyperparameters of the model are obtained through continuous iteration; It’s about hyperparameters z The minimum objective function, Z is the sample collection area, , Indicates l Hyperparameters.
[0011] In the preferred solution, in step S5, the final prediction result of the Bi-MGLSTM model is The expression is: (7); in, It is the forward and backward calculation process of the MGLSTM network. for t The forward hidden layer state at time, is the backward hidden layer state, , are the weight matrix and bias term respectively.
[0012] In the preferred solution, in step S6, the error correction model is operated as follows: The prediction results of each subsequence are summed and reconstructed to obtain the preliminary prediction results of wind power. ,Depend on Get the error time series , as shown in formula (9): (8); (9); In the formula, n is the number of wind power error sequences, is the actual power value of wind power, For the n The prediction error value, For the i Training results of secondary wind power modal components.
[0013] The optimized Bi-MGLSTM model is used to train and predict the error sequence, and the wind power error prediction result is obtained as follows: .
[0014] In the preferred solution, in step S7, the wind power preliminary prediction sequence Wind power error series Reconstruct and obtain the final predicted value of wind power .
[0015] In a preferred solution, in step S7, the performance of the prediction model is evaluated by calculating the root mean square error and mean absolute error of wind power: (10); (11); In the formula, They are represented as actual power value and predicted power value respectively.
[0016] The present invention provides a short-term wind power forecasting method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization, which has the following beneficial effects: 1. Using the forward and backward mean method to fill in the missing data can provide a continuous and complete data basis for VMD decomposition and power prediction. The normalization process scales the numerical range of the data to the range of 0-1, thereby reducing the storage requirements of the original data and the complexity of the calculation.
[0017] 2. VMD decomposition has strong adaptability and the ability to process nonlinear and non-stationary signals. Using this method to decompose wind power can not only fully extract the characteristic information of the original data, but also reduce the mutual influence between different characteristic information.
[0018] 3. The Bi-MGLSTM model is an effective combination of double forget gates and double input gates, which makes each MGLSTM model have stronger information screening ability and better generalization ability, thereby improving the overall prediction ability of short-term wind power. The forward and backward MGLSTM model input helps to deeply explore the intrinsic connection between past and future information, thereby improving the utilization of feature data.
[0019] 4. Since neural network models are prone to underfitting and overfitting, the Bayesian algorithm is used to optimize the hyperparameters of the Bi-MGLSTM model. By using the Bayesian theorem to make full use of the evaluation information of the previous function, the next most potential sampling point is selected according to the posterior distribution of the target function. The global optimal solution of the function is found with fewer evaluations, thereby obtaining the optimal hyperparameter combination of the Bi-MGLSTM model.
[0020] 5. In the error correction model, by learning the prediction error of the original prediction model, the sensitivity of the model to outliers and noise is reduced, and the generalization ability of the model is further enhanced. By analyzing the characteristics of the error sequence, the prediction error sequence is superimposed on the preliminary prediction results, which effectively enhances the robustness of the prediction model, thereby providing a more accurate prediction result.
[0021] 6. The performance of the prediction model is evaluated using the root mean square error and mean absolute error, where It is possible to quantify the magnitude of the prediction error, The closer the value is to 0, the closer the model's prediction is to the actual value. Describes the average absolute difference between the predicted value and the actual value. The smaller the value, the higher the accuracy of the model prediction. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] The present invention will be further described below in conjunction with the accompanying drawings and embodiments: Figure 1 It is a schematic diagram of the process of the present invention; Figure 2 This is the Bi-MGLSTM model structure diagram; Figure 3 This is the VMD decomposition result diagram; Figure 4 The following is a comparison chart of the prediction results of different models. DETAILED DESCRIPTION
[0023] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not used to limit the present invention.
[0024] Combination Figure 1~Figure 4 The specific embodiments of the present invention are described in further detail.
[0025] A short-term wind power forecasting method based on VMD decomposition and Bayesian optimization Bi-MGLSTM model, such as Figure 1 As shown, the following steps are included: S1. Data preprocessing, including obtaining a short-term wind power data set and filling in missing data, and normalizing the filled wind power data.
[0026] For missing data, the front and back mean method is used to fill in the missing data, specifically taking the average of the five data before and after to fill in the missing data. The details are as follows: (1); In the formula is the power missing value; After missing values Power value; Before the missing value A power value.
[0027] S2. Perform variational modal decomposition on the completed wind power data and determine the number of decomposition layers L, and finally obtain M relatively stable subsequence modal components.
[0028] The variational mode decomposition (VMD) is performed on the completed wind power data as follows: VMD decomposition is to construct and solve the variational problem so that the sum of the decomposition bandwidths of each mode is minimized. The expression is as follows: (2); (3); Where: is the total number of decomposed modes; is the unit of the imaginary part of a complex number; is the unit pulse function; is the convolution operator; is the number of decomposed modes; and are the mode set and the mode center frequency set respectively; is the original time series data signal.
[0029] S3. Add one more forget gate and one more input gate to the forward and backward LSTM of the BiLSTM (Bi-directional Long Short-Term Memory) model to build a Bi-MGLSTM (Bidirectional MultiGated long short term memory) model, such as Figure 2 As shown. The M modal components decomposed in step S2 are input into the Bi-MGLSTM model for power prediction.
[0030] The constructed Bi-MGLSTM model adds one more forget gate and one input gate in the forward and backward LSTM of the BiLSTM model. The functions of the two additional gates are the same as the original gates. The total forget gate and input gate of a single MGLSTM are calculated as follows: (4); In the formula, , are forget gate 1 and forget gate 2, , are input gate 1 and input gate 2, for t The output of the input layer at time t, for t The output of the hidden layer at time -1, is the weight matrix corresponding to different forget gates and input gates, is the training bias corresponding to each gate, are sigmoid and relu activation functions.
[0031] Final hidden layer output The calculation formula is: (5); In the formula, are the weights and biases corresponding to the output gate and unit cells, for t The cell state at the moment and the temporary state of the cell, is the hyperbolic tangent function.
[0032] S4. Use the Bayesian algorithm to optimize the hyperparameters of the Bi-MGLSTM model, including the initial learning rate, the number of training batches, and the number of hidden units, to obtain the optimized Bi-MGLSTM model.
[0033] The Bayesian algorithm is used to optimize the hyperparameters of the Bi-MGLSTM model, including the following methods: Determine the value range of the hyperparameter combination Z, select the hyperparameter value, and input it into the Bi-MGLSTM model while performing hyperparameter optimization. The formula is: (6); In the formula, The optimal hyperparameters of the model are obtained through continuous iteration; is the minimum objective function with respect to the hyperparameter z, Z The sample collection area, , Indicates l Hyperparameters.
[0034] S5. The prediction results of each modal component are obtained through the optimized Bi-MGLSTM model, and then the preliminary power prediction results are obtained by superposition and reconstruction.
[0035] Final prediction results for the Bi-MGLSTM model The expression is: (7); Formula (5) is the process of obtaining the final output of Bi-MGLSTM by updating the hidden layer state of the forward and backward MGLSTM. It is the forward and backward calculation process of the MGLSTM network. for t The forward hidden layer state at time, is the backward hidden layer state, , are the weight matrix and bias term respectively.
[0036] S6, error correction model: the initial power prediction value is subtracted from the true value, and the error sequence is trained and predicted using the optimized Bi-MGLSTM model to obtain the error prediction result; Error correction model, the operation method is as follows: The prediction results of each subsequence are summed and reconstructed to obtain the preliminary prediction results of wind power. ,Depend on Get the error time series , as shown in formula (9): (8); (9); In the formula, n is the number of wind power error sequences, is the actual power value of wind power, For the n The prediction error value, For the iTraining results of secondary wind power modal components.
[0037] The optimized Bi-MGLSTM model is used to train and predict the error sequence, and the wind power error prediction result is obtained as follows: .
[0038] S7, add the power prediction value and the error prediction value to obtain the final prediction result, and evaluate the performance of the prediction model through the root mean square error and the mean absolute error.
[0039] The wind power preliminary forecast sequence Wind power error series Reconstruct and obtain the final predicted value of wind power .
[0040] The performance of the prediction model is evaluated by calculating the root mean square error (RMSE) and mean absolute error (MAE) of wind power: (10); (11); In the formula, They are represented as actual power value and predicted power value respectively.
[0041] Example The real wind power generation data of a certain region in China in December 2022 is used. The data set has a total of 2976 records, which record the actual power generation data of the region every 15 minutes. The present invention selects the data of the first 26 days as the training set and the last 5 days as the test set. That is, the wind power generation of the next 5 days can be predicted based on the historical data of the past 26 days.
[0042] In this embodiment, VMD decomposition is used to stabilize the wind power data, thereby obtaining several subsequence modal components with stronger correlation and smoother stability. The selection of the modal number M value of VMD directly affects the decomposition effect. When the M value is small, it will be in an under-decomposition state, and the power data cannot be decomposed into IMF components. When the k value is large, an over-decomposition state will occur, which is mainly because multiple IMF components have the same center frequency. After multiple simulation verifications, the modal number, penalty parameter, center frequency and convergence tolerance are set to M=8, α=2000, = 1 and τ = 10-7. In this way, the decomposed subsequences will not have modal aliasing and the fidelity of the decomposed sequence can be guaranteed. Figure 3 This is the VMD decomposition of wind power, and the decomposition results can be used for prediction models.
[0043] In this embodiment, BO-BiLSTM (Bayesian optimization-Bidirectional Long Short-Term Memory), BO-Bi-MGLSTM (Bayesian optimization-Bidirectional Multi Gated long short term memory), VMD-BO-BiLSTM (Variational modal decomposition-Bayesian optimization-Bidirectional Long Short-Term Memory), and VMD-BO-Bi-MGLSTM (Variational modal decomposition-Bayesian optimization-Bidirectional Long Short-Term Memory) are set as comparison models for power error analysis, and the error evaluation index results of each model are shown in Table 1.
[0044]
[0045] From Table 1 and Figure 4 It can be seen that the prediction accuracy of the BO-BiLSTM model and the BO-Bi-MGLSTM model is lower than that of the VMD-BO-BiLSTM model and the VMD-BO-Bi-MGLSTM model. This shows that the original power is decomposed by VMD, the redundant noise in the modal component is removed, and the volatility of the power is reduced to a certain extent. The prediction model can better extract feature information, thereby improving the prediction accuracy. Secondly, the RMSE and MAE of the VMD-BO-Bi-MGLSTM model in the wind power prediction results are 1.5931 and 1.1954. Compared with the VMD-BO-BiLSTM model, the RMSE is reduced by 0.3492MW and the MAE is reduced by 0.6546M. This is mainly because the Bi-MGLSTM prediction model adds one input gate and one forget gate to each LSTM in the BiLSTM prediction model, has stronger information processing capabilities, and can more flexibly handle the retention and forgetting of time series data. Therefore, the proposed model is more accurate and stable than other models.
[0046] In summary, the VMD decomposition algorithm's ability to efficiently process non-stationary signals is combined with the Bi-MGLSTM model's stronger information screening and generalization capabilities for long time series to construct a high-precision wind power prediction combined model with better prediction performance.
Claims
1. A short-term wind power forecasting method based on VMD decomposition and Bayesian optimization Bi-MGLSTM model, characterized in that: The following steps are involved: S1. Data preprocessing, including obtaining a short-term wind power data set and filling in missing data, and normalizing the filled wind power data; S2. Perform variational modal decomposition on the completed wind power data and determine the number of decomposition layers L, and finally obtain M relatively stable subsequence modal components; S3, adding one more forget gate and one more input gate to the forward and backward LSTM of the BiLSTM model, constructing a Bi-MGLSTM model, and inputting the M modal components decomposed in step S2 into the Bi-MGLSTM model for power prediction; S4. Use the Bayesian algorithm to optimize the hyperparameters of the Bi-MGLSTM model, including the initial learning rate, the number of training batches, and the number of hidden units, to obtain an optimized Bi-MGLSTM model. S5. The prediction results of each modal component are obtained through the optimized Bi-MGLSTM model, and then the preliminary power prediction results are obtained by superposition reconstruction; S6, error correction model: the initial power prediction value is subtracted from the true value, and the error sequence is trained and predicted using the optimized Bi-MGLSTM model to obtain the error prediction result; S7. Add the power prediction value and the error prediction value to obtain the final prediction result.
2. According to claim 1, a short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization is characterized in that: In step S1, the missing data is supplemented using the front and back mean method.
3. The short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 2 is characterized in that: The front and back mean method takes the average value of the five data before and after the missing data to complete the missing data. The expression is: (1); In the formula, is the power missing value; After missing values Power value; Before the missing value A power value.
4. The short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 1 is characterized in that: In step S2, variational modal decomposition is performed on the completed wind power data, and the operation is as follows: Variational mode decomposition is to construct and solve the variational problem so that the sum of the decomposition bandwidths of each mode is minimized. The expression is as follows: (2); (3); Where: is the total number of decomposed modal components; is the unit of the imaginary part of a complex number; is the unit pulse function; is the convolution operator; is the number of decomposed modes; and are the mode set and the mode center frequency set respectively; is the original time series data signal.
5. The short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 1 is characterized in that: In step S3, the constructed Bi-MGLSTM model adds one more forget gate and one more input gate in the forward and backward LSTM of the BiLSTM model. The functions of the two additional gates are the same as the original gate functions. The total forget gate and input gate of a single MGLSTM are calculated as follows: (4); In the formula, , are forget gate 1 and forget gate 2, , are input gate 1 and input gate 2, for t The output of the input layer at time t, for t The output of the hidden layer at time -1, is the weight matrix corresponding to different forget gates and input gates, is the training bias corresponding to each gate, are sigmoid and relu activation functions. Final hidden layer output The calculation formula is: (5); In the formula, are the weights and biases corresponding to the output gate and unit cells, for t The cell state at the moment and the temporary state of the cell, is the hyperbolic tangent function.
6. The short-term wind power prediction method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 5 is characterized in that: In step S4, the hyperparameters of the Bi-MGLSTM model are optimized using the Bayesian algorithm, including the following method: Determine the value range of the hyperparameter combination Z, select the hyperparameter value, and input it into the Bi-MGLSTM model while performing hyperparameter optimization. The formula is: (6); In the formula, The optimal hyperparameters of the model are obtained through continuous iteration; It’s about hyperparameters z The minimum objective function, Z is the sample collection area, , Indicates l Hyperparameters.
7. The short-term wind power forecasting method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 5 is characterized in that: In step S5, the final prediction result of the Bi-MGLSTM model is The expression is: (7); in, It is the forward and backward calculation process of the MGLSTM network. for t The forward hidden layer state at time, is the backward hidden layer state, , are the weight matrix and bias term respectively.
8. The short-term wind power forecasting method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 1 is characterized in that: In step S6, the error correction model is operated as follows: The prediction results of each subsequence are summed and reconstructed to obtain the preliminary prediction results of wind power. ,Depend on Get the error time series , as shown in formula (9): (8); (9); In the formula, n is the number of wind power error sequences, is the actual power value of wind power, For the n The prediction error value, For the i Training results of secondary wind power modal components. The optimized Bi-MGLSTM model is used to train and predict the error sequence, and the wind power error prediction result is obtained as follows: .
9. The short-term wind power forecasting method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 8 is characterized in that: In step S7, the wind power preliminary prediction sequence Wind power error series Reconstruct and obtain the final predicted value of wind power .
10. The short-term wind power forecasting method based on the Bi-MGLSTM model of VMD decomposition and Bayesian optimization according to claim 1 is characterized in that: In step S7, the performance of the prediction model is evaluated by calculating the root mean square error and mean absolute error of wind power: (10); (11); In the formula, They are represented as actual power value and predicted power value respectively.
Citation Information
Cited By
New energy station power interval prediction method
CN120879569A
New energy station power interval prediction method
CN120879569B
Virtual power plant scale transaction method oriented to electricity-carbon-green certificate market
CN122243643A
