A multi-scale wind power time series prediction method

Through the multi-scale wind power prediction method based on Transformer and convolutional neural network, the problem of wind power data in the existing technology that cannot be considered at the same time is solved, and the accurate prediction of multi-scale wind power is achieved, which improves the scheduling and operation stability of the power system.

CN115600501BActive Publication Date: 2025-08-15POWER ECONOMIC RESEARCH INSTITUTE OF JILIN ELECTRIC POWER CO LTD +2
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202211366938.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-11-01
Publication Date
2025-08-15
Estimated Expiration
2042-11-01

AI Technical Summary

Technical Problem

The existing wind power prediction model cannot effectively consider wind power data at different time scales at the same time, resulting in difficulty in scheduling and operating power systems, making it difficult to achieve accurate multi-scale wind power prediction.

Method used

The multi-scale wind power prediction method based on the Transformer model and convolutional neural network is adopted to process the data through mean and variance normalization, and the neural network is trained using the multi-head attention mechanism and loss function, and the convolutional neural network is combined with the normalization reduction of multi-scale output to control error transmission.

Benefits of technology

It effectively weakens the error superposition effect, improves the accuracy and stability of multi-scale wind power prediction, and enhances the scheduling and operation capabilities of the power system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115600501B_ABST
    Figure CN115600501B_ABST
Patent Text Reader

Abstract

This invention discloses a multi-scale wind power time series prediction method belonging to the field of power engineering technology. The method comprises step S1: normalizing the mean and variance of each characteristic dimension of wind power and rotor speed data; step S2: inputting the processed data from step S1 into a neural network prediction model; step S3: training the neural network prediction model using a loss function; and step S4: normalizing the multi-scale outputs of the neural network prediction model. This method can control error propagation between multiple scales, reducing the effect of error superposition, and ensuring that the positive effects of multi-scale superposition on prediction error outweigh the negative effects.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of electric power engineering, and in particular to a multi-scale wind power time series prediction method. Background Art

[0002] Driven by resource scarcity and environmental degradation, renewable energy is attracting increasing attention due to its pollution-free, low-cost nature. To accelerate the development of renewable energy, China has proposed building a new power system based primarily on renewable energy. As a key component of renewable energy, wind power generation continues to expand, and its impact on the power grid is becoming increasingly significant.

[0003] Due to the volatility of wind power output, integrating large-scale wind power into the grid significantly increases the difficulty of power system generation planning. This poses significant challenges to power system scheduling and operation. Accurately forecasting wind power can effectively alleviate the pressure on power system peak and frequency regulation and improve wind power absorption capacity.

[0004] Currently, to more accurately predict the wind power of a specific wind farm and thereby improve the safety and stability of economically dispatchable power systems, neural network methods, such as convolutional neural networks and Transformer neural network models, are commonly used to construct wind power prediction models. While these models can effectively predict wind power, they are relatively simple and primarily focus on long-term or short-term wind power forecasts, failing to fully utilize wind power data. Therefore, incorporating both long-term and short-term wind power data into prediction models to achieve more accurate and effective forecasts has become a hot topic and a key research focus.

[0005] Wind power prediction techniques for specific wind farms are typically tailored to either short-term or long-term power forecasting. For example, short-term wind power forecasts for the next 5 or 15 minutes, or long-term wind power forecasts for the next 12 or 24 hours, typically require consistent data intervals. Such techniques do not simultaneously consider wind power predictions at different time scales. Therefore, a Transformer-based wind power prediction model and corresponding data processing pipeline are urgently needed. Summary of the Invention

[0006] The present invention aims to provide a multi-scale wind power time series prediction method, characterized in that the method comprises the following steps:

[0007] Step S1: performing mean and variance normalization processing on each feature dimension of wind power and wind rotor speed data;

[0008] Step S2: input the data processed in step S1 into the neural network prediction model;

[0009] Step S3: using the loss function to train the neural network prediction model;

[0010] Step S4: Normalize and restore the multi-scale output of the neural network prediction model.

[0011] The formula for normalizing the mean and variance of each characteristic dimension of the wind power and rotor speed data in step S1 is as follows:

[0012]

[0013] Among them, μ is the mean of all sample data, σ is the standard deviation of all sample data, x is the original wind power historical data, x * The data are normalized.

[0014] The neural network prediction model in step S2 is based on the Transformer model and the convolutional neural network model, as follows:

[0015] Model Input First pass through the Transformer model to get the micro-scale output The mesoscale input is composed of the microscale output y1 and noise, and then passes through the convolutional neural network model to obtain the mesoscale output The large-scale input is composed of the medium-scale output y2 and noise, and then passes through the convolutional neural network model to obtain the large-scale output

[0016] The structure of the Transformer model includes multiple encoders and decoders, and each encoder and decoder adopts a self-attention mechanism and a multi-head attention mechanism.

[0017] The calculation process of each layer in the multi-head attention mechanism is as follows:

[0018] The model input X is matrix multiplied with different linear transformation matrices to obtain the Q, K, and V values according to the following formula:

[0019] Q i =X*W i Q

[0020] K i =X*W i K

[0021] V i =X*W i V

[0022] W iQ , W i K , W i V is a weight matrix, and each self-attention head has a corresponding set of weight matrices;

[0023] The Q value is dot-producted with the K value, then passed through a Softmax activation layer, and then multiplied by V for weighting to produce an attention score. The formula is as follows:

[0024] S i =Softmax(Q i ,K i )V i

[0025]

[0026] where k j is the output value of the kth node, N is the number of nodes, and e is the base of the natural logarithm;

[0027] Finally, each attention score is stacked.

[0028] The formula for stacking each attention score is as follows:

[0029] MH=Concat(S1,S2,…,S n )*W

[0030] Among them, n represents the number of heads representing multi-head self-attention, Concat represents concatenating S1, S2, ..., S n Splicing is performed in dimension, and W is a parameter in the training process.

[0031] The loss function in step S3 is:

[0032]

[0033] in, is the predicted value of wind power, y n is the actual value of wind power, n = 1, 2 or 3 represents the output results of microscale, mesoscale or macroscale respectively, N b is the batch size during training, which is a constant.

[0034] The formula for normalizing and restoring the multi-scale output of the neural network prediction model in step S4 is as follows:

[0035]

[0036]

[0037]

[0038] Among them, P1, P2, and P3 represent the predicted values of wind power at microscale, mesoscale, and macroscale, respectively. are the multi-scale output results of the prediction model, μ1, μ2, μ3 are the means of microscale, mesoscale and large scale respectively, σ1, σ2, σ3 are the standard deviations of microscale, mesoscale and large scale respectively.

[0039] The beneficial effects of the present invention are:

[0040] The present invention can control the error transmission between multiple scales, weaken the effect of error superposition, and make the positive effect of multiple scale superposition on the prediction error outweigh the negative effect. BRIEF DESCRIPTION OF THE DRAWINGS

[0041] Figure 1 This is a flow chart of the multi-scale wind power time series prediction method of the present invention;

[0042] Figure 2 (a)(b)(c) are divided into microscale, mesoscale and large-scale wind power prediction result diagrams;

[0043] Figure 3 This is the structural diagram of the multi-scale wind power prediction model. DETAILED DESCRIPTION

[0044] The present invention proposes a multi-scale wind power time series prediction method, which is further described below with reference to the accompanying drawings and specific embodiments.

[0045] Figure 3 This is the structure diagram of the multi-scale wind power prediction model, based on the Transformer model and Convolutional Neural Network (CNN). Model input First, through the Transformer model, we get the micro-scale output In order to adapt to the multi-scale output and alleviate the impact of the prediction bias of the previous scale being transmitted downward, the mesoscale input includes the microscale output y1 and the noise sampled from the standard normal distribution, and passes through the convolutional neural network model to obtain the mesoscale output result Similarly, the large-scale input is also composed of the medium-scale output y2 and noise. After the convolutional neural network, the large-scale output result is obtained. Among them, the Transformer model structure can be simplified into a series of encoders and decoders, each of which adopts an attention mechanism, including a self-attention mechanism and a multi-head attention mechanism composed of multiple self-attention mechanisms.

[0046] The calculation of each layer in the multi-head attention mechanism can be briefly described as: matrix multiplication of input X with different linear transformation matrices to obtain Q, K, and V values.

[0047] Q i =X*W i Q

[0048] K i =X*W i K

[0049] V i =X*W i V

[0050] Among them, W i Q , W i K , W i V For the weight matrix, each self-attention head has a corresponding set of weight matrices, which are randomly initialized and need to be optimized and trained as the model is performed.

[0051] The Q value is dot-producted with the K value, and the attention score is obtained by a Softmax activation layer, which is then multiplied by V for weighting to generate the attention score.

[0052] S i =Softmax(Q i ,K i )V i

[0053]

[0054] where k j is the output value of the kth node, and N is the number of nodes. The Softmax function can be used to represent the result as a probability between 0 and 1.

[0055] Finally, each attention score is stacked.

[0056] MH=Concat(S1,S2,…,S n )*W

[0057] Among them, n represents the number of heads representing multi-head self-attention, Concat represents concatenating S1, S2, ..., S n Splicing is performed in dimension, W is randomly initialized and needs to be trained together with the model.

[0058] The purpose of using the attention mechanism is to enable the neural network to selectively acquire knowledge, filter out a small amount of important information from a large amount of information, increase the weight to the important information, and ignore most of the unimportant information.

[0059] After the Transformer model, the micro-scale output result is obtained And with the noise sampled from the normal distribution input into the convolutional neural network model, the mid-scale output is obtained This example uses a three-layer sub-network. Each sub-network layer consists of a convolution kernel of size n×m, an activation function ReLU, and a linear layer. The results of the remaining convolution layers are similar. The specific form is as follows:

[0060]

[0061] ReLU=max(0,x)

[0062]

[0063] Among them, N i is the size of the training batch, n is the number of input channels, a unique constant. * is the cross-correlation, λ is a constant, P r (x) is the standard normal distribution function for sampling sample x. j ,b,W,W n×m These are parameters in the training process and are optimized along with the model.

[0064] The large-scale output results have a similar structure to the medium-scale ones, and also require the input of the medium-scale output and the addition of noise to alleviate the impact of the deviation caused by the previous scale prediction.

[0065] Figure 1 The flowchart of the multi-scale wind power time series prediction method of the present invention is as follows:

[0066] S1: Processing sample data. To improve the model's prediction accuracy, the data is first normalized. The data includes monitoring data for different dimensions of the wind farm, such as wind power and rotor speed, at various time periods. Normalizing the data's mean and variance is not done for the sample alone, but for each feature dimension. Standard deviation normalization ensures that the processed data conforms to a standard normal distribution, with a mean of 0 and a standard deviation of 1. Data processing is as follows:

[0067]

[0068] Where μ is the mean of all sample data, σ is the standard deviation of all sample data. x is the original wind power historical data, x *The normalized data is used as the input of the model.

[0069] Processing data in this way can not only speed up the fitting of the neural network when using the model for prediction, but also reduce the occurrence of non-convergence during training due to extremely unbalanced data.

[0070] S2: The processed data is input into the prediction model. Input into the designed neural network prediction model and train it through the loss function in the next step.

[0071] S3: Use the loss function to train the prediction model. The Transformer model is improved to adapt to multi-scale output. In order to compare the effectiveness of this model improvement and whether it can effectively learn between multiple scales, a standard is needed to verify it. This embodiment uses the mean square error (MSE) between the predicted value and the true value as an indicator to train the model and find the optimal parameters. That is:

[0072]

[0073] in, is the predicted value of wind power, y n is the actual value of wind power. n = 1 represents the micro-scale output result. Similarly, n = 2 or 3 represent the meso-scale and macro-scale output results respectively. N b is the batch size during training, which is a constant.

[0074] By minimizing the loss function, the output of the prediction model can be made close to the actual result. When the loss function converges or is sufficiently small and does not fluctuate much, the neural network model has been trained. At this point, the internal parameters of the model have been optimized, such as the linear transformation weight matrix in the self-attention mechanism.

[0075] S4: Multi-scale output normalization and restoration. In order to make the prediction model converge as quickly as possible and speed up the training, the original data is normalized before outputting the prediction model. Therefore, in order to obtain the actual wind power prediction value, the model output needs to be restored. As shown below:

[0076]

[0077]

[0078]

[0079] Among them, P1, P2, and P3 represent the wind power prediction values at microscale, mesoscale, and macroscale, respectively. are the multi-scale output results of the prediction model, μ1, μ2, μ3 are the means of microscale, mesoscale and large scale, respectively, σ1, σ2, σ3 are the standard deviations of microscale, mesoscale and large scale, respectively.

[0080] The test data for this example comes from RTS-GMLC wind power data, which contains wind power data for 365 days a year at 5-minute intervals. This dataset includes four wind turbines. 288 points per 24-hour period are used as input, and rolling training is performed on the data over time.

[0081] Build different models, observe the mean square error (MSE) index of the experimental results and conduct comparative analysis. Figure 2 (a)(b)(c) are divided into microscale, mesoscale and large-scale wind power prediction result diagrams. The results of different models at different scales under given indicators are compared. The wind power data are randomly sampled for testing. The results at different scales are shown in the following table.

[0082] Table 1 Comparison of MSE at multiple scales for different models

[0083]

[0084] From the results in the table, it can be seen that after the model is modified, although the results of the mesoscale and large-scale are not the most effective among several methods, the MSE at the microscale is the smallest, which is nearly 18% lower than the Transformer model. This also verifies the effectiveness of the model. As can be seen from the figure below, the microscale results can always obtain a higher fitting effect. Although the fitting effects of the mesoscale and large-scale are not as good as those of the microscale, they can still predict the wind power well. This embodiment controls the error transmission between multiple scales by designing a reasonable neural network structure and training method, weakens the effect of error superposition, and can make the positive effect of the superposition of multiple scales on the prediction error exceed the negative effect.

Claims

1. A multi-scale wind power time series prediction method, characterized in that: The method comprises the following steps: Step S1: performing mean and variance normalization processing on each feature dimension of wind power and wind rotor speed data; Step S2: input the data processed in step S1 into the neural network prediction model; The neural network prediction model in step S2 is based on the Transformer model and the convolutional neural network model, as follows: Model Input First pass through the Transformer model to get the micro-scale output The mesoscale input is composed of the microscale output y1 and noise, and then passes through the convolutional neural network model to obtain the mesoscale output The large-scale input is composed of the medium-scale output y2 and noise, and then passes through the convolutional neural network model to obtain the large-scale output The structure of the Transformer model includes multiple encoders and decoders, and each encoder and decoder adopts a self-attention mechanism and a multi-head attention mechanism; Step S3: using the loss function to train the neural network prediction model; Step S4: Normalize and restore the multi-scale output of the neural network prediction model.

2. The multi-scale wind power time series prediction method according to claim 1, characterized in that: The formula for normalizing the mean and variance of each characteristic dimension of the wind power and wind rotor speed data in step S1 is as follows: Among them, μ is the mean of all sample data, σ is the standard deviation of all sample data, x is the original wind power historical data, x * The data are normalized.

3. The multi-scale wind power time series prediction method according to claim 1, characterized in that: The calculation process of each layer in the multi-head attention mechanism is as follows: The model input X is matrix multiplied with different linear transformation matrices to obtain the Q, K, and V values according to the following formula: Q i =X*W i Q K i =X*W i K V i =X*W i V W i Q , W i K , W i V is a weight matrix, and each self-attention head has a corresponding set of weight matrices; The Q value is dot-producted with the K value, then passed through a Softmax activation layer, and then multiplied by V for weighting to produce an attention score. The formula is as follows: S i =Softmax(Q i ,K i )V i where k j is the output value of the kth node, N is the number of nodes, and e is the base of the natural logarithm; Finally, each attention score is stacked.

4. The multi-scale wind power time series prediction method according to claim 3, characterized in that: The formula for stacking each attention score is as follows: MH=Concat(S1,S2,…,S m )*W Among them, m represents the number of heads representing multi-head self-attention, Concat represents concatenating S1, S2, ..., S m Splicing is performed in dimension, and W is a parameter in the training process.

5. The multi-scale wind power time series prediction method according to claim 1, characterized in that: The loss function in step S3 is: in, is the predicted value of wind power, y q is the actual value of wind power, q = 1, 2 or 3 represents the output results of microscale, mesoscale or macroscale respectively, N b is the batch size during training, which is a constant.

6. The multi-scale wind power time series prediction method according to claim 1, characterized in that: The formula for normalizing and restoring the multi-scale output of the neural network prediction model in step S4 is as follows: Among them, P1, P2, and P3 represent the predicted values of wind power at microscale, mesoscale, and macroscale, respectively. are the multi-scale output results of the prediction model, μ1, μ2, μ3 are the means of microscale, mesoscale and large scale respectively, σ1, σ2, σ3 are the standard deviations of microscale, mesoscale and large scale respectively.

Citation Information

Patent Citations

  • The invention discloses an uUltra-short-time wind power prediction method based on deep learning

    CN109615146A

  • Time sequence prediction method based on interactive multi-scale recurrent neural network

    CN111027672A