TCN-lstm wind power generation prediction method combining time-frequency analysis and attention mechanism

By combining time-frequency analysis with the TCN-LSTM model of the multi-head self-attention mechanism, the problems of multimodal information fusion and long- and short-term dependency feature processing in wind power generation forecasting are solved, the forecast accuracy and grid stability are improved, and it is suitable for power generation forecasting and optimized scheduling of complex power systems.

CN119382103BActive Publication Date: 2025-10-10NORTHEAST GASOLINEEUM UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202411504827.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-10-27
Publication Date
2025-10-10
Estimated Expiration
2044-10-27

AI Technical Summary

Technical Problem

Existing technologies cannot effectively integrate multimodal information in wind power generation forecasting, have difficulty in simultaneously processing long-term and short-term dependency features, and have low computational efficiency, resulting in insufficient forecast accuracy and affecting grid stability and scheduling optimization.

Method used

A TCN-LSTM wind power generation prediction method combining time-frequency analysis and multi-head self-attention mechanism is adopted. Frequency domain features and time domain features are extracted through wavelet transform and adaptive weighted fusion is performed. A time-frequency joint analysis module is constructed, combining the temporal convolutional network (TCN) and the long short-term memory (LSTM) network, introducing the multi-head self-attention mechanism, capturing global dependencies, and optimizing hyperparameters to improve model performance.

Benefits of technology

It significantly improves the accuracy and computational efficiency of wind power generation forecasts, enhances the modeling capabilities of complex time series characteristics, improves the grid's dispatch optimization capabilities and renewable energy absorption capabilities, and reduces the impact of power generation fluctuations on the grid.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119382103B_ABST
    Figure CN119382103B_ABST
Patent Text Reader

Abstract

The application relates to a TCN-LSTM wind power generation capacity prediction method combining time-frequency joint analysis and a multi-head self-attention mechanism, which comprises the following steps: preprocessing original wind power generation data; extracting frequency domain features of the wind power generation data through wavelet transform, adaptively weighting and fusing the frequency domain features with time domain features, and constructing a time-frequency joint analysis module; constructing a TCN-LSTM combined network of a time convolution network (TCN) and a long short-term memory network (LSTM); introducing a multi-head self-attention mechanism into the TCN-LSTM combined network to generate a TCN-LSTM wind power generation capacity prediction model combining time-frequency analysis and the attention mechanism; training the model by using a wind power generation data set; evaluating the prediction performance of the trained model; and predicting the wind power generation capacity by using the final wind power generation capacity prediction model. The application significantly improves the accuracy of wind power generation prediction and the calculation efficiency of the model, and improves the precision of wind power prediction.
Need to check novelty before this filing date? Find Prior Art

Description

Technical field:

[0001] The present invention relates to the accurate prediction of wind and solar power generation and power system scheduling optimization in the fields of power systems, smart grids, and new energy prediction technologies. Specifically, it provides a TCN-LSTM wind power generation prediction method that combines time-frequency joint analysis with a multi-head self-attention mechanism. Background technology:

[0002] With the continued growth of global energy demand and increasing environmental protection requirements, renewable energy sources such as wind and solar power are becoming increasingly important components of electricity generation. Wind power generation, influenced by various external factors such as weather and seasons, exhibits significant volatility and intermittency. This uncertainty poses significant challenges to the stable operation of power systems, especially as the proportion of wind power connected to the grid increases. The accuracy of wind power generation forecasts directly impacts grid security and scheduling optimization. Therefore, the development of high-precision wind power generation forecasting models is of great practical significance.

[0003] Currently, wind power generation forecasting is primarily based on time series prediction methods, with commonly used statistical approaches including ARIMA models and support vector regression (SVR). However, traditional statistical methods have significant limitations when dealing with complex, nonlinear and nonstationary time series data. In particular, they exhibit low forecasting accuracy and adaptability in multimodal information processing and modeling long- and short-term dependencies. Furthermore, effectively integrating the time and frequency domain features of wind power generation data to improve the accuracy of forecasting models remains a major challenge in existing research.

[0004] Therefore, existing technologies have many shortcomings in dealing with the complexity of wind power generation forecasting, such as the inability to effectively integrate multimodal information, difficulty in simultaneously processing long-term and short-term dependency features, and low computational efficiency. Summary of the invention:

[0005] The purpose of the present invention is to provide a TCN-LSTM wind power generation prediction method that combines time-frequency analysis with an attention mechanism. This TCN-LSTM wind power generation prediction method that combines time-frequency analysis with an attention mechanism is used to solve the problem in the prior art that traditional models cannot fully capture multimodal features and long-term dependencies.

[0006] The technical solution adopted by the present invention to solve the technical problem is: the TCN-LSTM wind power generation prediction method combining time-frequency analysis and attention mechanism includes the following steps:

[0007] Step 1: Obtaining the original data of wind power generation and preprocessing the original data of wind power generation;

[0008] Step 2: After data preprocessing, the frequency domain features of the wind power generation data are extracted through wavelet transform, which is then adaptively weighted and fused with the time domain features to construct a time-frequency joint analysis module (TFAA). This module performs time-frequency joint feature analysis, extracts multimodal information, and obtains the wind power generation data set.

[0009] Step 3: Build a TCN-LSTM combined network consisting of a temporal convolutional network (TCN) and a long short-term memory (LSTM) network. This improves the ability to perceive complex temporal features by processing both long-term and short-term dependency features.

[0010] Step 4: Introduce the multi-head self-attention mechanism into the TCN-LSTM combined network to obtain a TCN-LSTM wind power generation prediction model that combines time-frequency analysis and the attention mechanism. By using multiple parallel attention heads to capture global dependencies, the model can perceive the contextual information of wind power generation data.

[0011] Step 5: Use the wind power generation dataset generated in step 2 to train the model and optimize key parameters through hyperparameter optimization;

[0012] Step 6: Evaluate the prediction performance of the trained TCN-LSTM wind power generation prediction model that combines time-frequency analysis and attention mechanism, and obtain the final TCN-LSTM wind power generation prediction model that combines time-frequency analysis and attention mechanism;

[0013] Step 7: Use the final TCN-LSTM wind power generation prediction model that combines time-frequency analysis and attention mechanism to predict wind power generation.

[0014] Step 1 of the above scheme is specifically as follows:

[0015] 1.1. Data cleaning: Eliminate unreasonable records from the original data of wind power generation, which includes air density, wind speed, and temperature;

[0016] 1.2. Data interpolation: cubic spline interpolation is used to fill in missing data to ensure data continuity;

[0017] 1.3. Normalization: Use maximum and minimum normalization on all data to scale the data range to [0,1].

[0018] The method for constructing the time-frequency joint analysis module in step 2 of the above solution is specifically as follows:

[0019] 2.1. Use wavelet transform to extract frequency domain feature information of pre-processed wind power generation data;

[0020] 2.2. Construct the time domain feature F for the data after wavelet transformation time (t) and frequency domain features Ffreq (f);

[0021] 2.3、The time domain feature F time (t) and frequency domain features F freq (f) Feature fusion, calculation of fusion weight W time ;

[0022] W time =σ(Conv1D(GAP(F time (t)+F freq (f))))

[0023] Where W time is the adaptive weight, which represents the relative importance of time domain and frequency domain features. The weight is automatically learned through the global average pooling GAP and the one-dimensional convolution Conv1D layer. σ is the Sigmoid activation function, and the output value is between [0, 1].

[0024] 2.4. Obtain the fused feature representation F fusion :

[0025] F fusion =W time F time (t)+(1-W time )F freq (f).

[0026] The TCN-LSTM combined network model in the steps of the above scheme is as follows:

[0027]

[0028] Where, is the combined feature vector, which represents the final feature output after fusion; is the output feature of the LSTM model at time step t; is the output feature of the TCN model at time step t; β(t) is the time-varying adaptive adjustment function; W β is the trainable weight matrix; b β is the bias term.

[0029] Beneficial effects:

[0030] 1. The wind power generation prediction model proposed in this invention, based on time-frequency joint analysis, TCN-LSTM combined network and multi-head self-attention mechanism, extracts and fuses time-frequency features through wavelet transform, combines TCN and LSTM networks to model complex time series features, and introduces multi-head self-attention mechanism to enhance the ability to capture global dependencies. It significantly improves the accuracy of wind power generation prediction and the computational efficiency of the model, can improve the accuracy of wind energy prediction, solves the problem that traditional models cannot fully capture multimodal features and long-term dependencies, and is suitable for power generation prediction and optimal scheduling in complex power systems.

[0031] 2. The present invention solves the problem in the existing technology that it is difficult to effectively extract and fuse time domain and frequency domain information by introducing the time-frequency joint analysis module (TFAA), fully exploits the multimodal characteristics in wind energy data, and thus greatly improves the accuracy of power generation forecasting; the construction of the TCN-LSTM combined network enhances the model's ability to handle long-term and short-term dependencies, significantly improves the modeling effect of complex time series data, and overcomes the shortcomings of existing deep learning models in modeling long-term and short-term dependencies; the introduction of the multi-head self-attention mechanism (MHSA) further strengthens the model's capture of global time series dependencies, especially in long-term prediction tasks, greatly improving the accuracy of the model and accurately predicting wind power generation.

[0032] 3. The present invention ensures the high stability and generalization ability of the model under different meteorological conditions by optimizing hyperparameters, making it well adaptable in the practical application of wind power generation systems.

[0033] 4. The present invention can effectively reduce the impact of power generation fluctuations on grid operation, improve the grid's dispatching and optimization capabilities and its ability to absorb renewable energy, and reduce the demand for backup capacity.

[0034] 5. This invention plays an important role in improving power generation prediction accuracy, enhancing grid stability, and optimizing resource scheduling. Experimental results have verified its wide applicability in practical applications and its performance significantly superior to existing technologies, and it has good prospects for promotion. Description of the drawings:

[0035] Figure 1 This is the structure diagram of the TCN-LSTM model with joint time-frequency analysis and multi-head self-attention mechanism;

[0036] Figure 2 This is the time series diagram of the original data of the wind farm in different seasons;

[0037] Figure 3 This is the data series diagram after wavelet decomposition of wind energy forecast data;

[0038] Figure 4 This is a sensitivity analysis chart of learning rate and batch size;

[0039] Figure 5 is the mother wavelet of wavelet transform and decomposition scale map;

[0040] Figure 6 The loss change graph for model training;

[0041] Figure 7 This is a comparison chart of wind power generation ablation experiments. Specific implementation method:

[0042] The present invention will be further described below:

[0043] See Figure 1 This TCN-LSTM wind power generation prediction method that combines time-frequency analysis and attention mechanism specifically includes data preprocessing, time-frequency feature extraction and fusion, TCN-LSTM combined network, introduction of attention mechanism, model training and optimization, etc.

[0044] Step 1: Data preprocessing: Clean and preprocess the raw data of wind power generation, remove invalid or abnormal data, fill in missing values, and normalize the data to unify data of different dimensions into the same numerical range. The data preprocessing step can improve the accuracy of subsequent feature extraction and modeling, provide a reliable data foundation for model construction, and ensure data consistency and quality. Preprocessing of wind power generation data includes the following steps:

[0045] Data cleaning: Eliminate unreasonable records in the data set, such as records with wind speed less than 0 or abnormally high.

[0046] Data interpolation: Cubic spline interpolation is used to fill in missing data to ensure data continuity.

[0047] Normalization: Use maximum and minimum normalization on all data to scale the data range to [0,1]. The formula is as follows:

[0048]

[0049] Where x ij is the jth sample value of the i-th physical quantity, Its corresponding normalized value; x i.max is the maximum value of the i-th physical quantity, x i.min is the minimum value of the i-th physical quantity.

[0050] Step two: time-frequency joint feature analysis: after data preprocessing, wavelet transform is used to analyze the time-frequency domain features of wind power generation data. Wavelet transform can extract frequency domain features at multiple scales and reveal the frequency spectrum information in the data. Through wavelet transform, the frequency domain features of wind power generation data are extracted, which are adaptively weighted and fused with time domain features to construct a time-frequency joint analysis module (TFAA). This module can consider the differences between time domain and frequency domain features, effectively extract multi-modal information, solve the problem that traditional models cannot fully consider the differences between time domain and frequency domain information, and solve the problem that traditional methods cannot consider time-frequency information.

[0051] The wind energy data sequence contains nonlinear and non-stationary characteristics. To effectively extract the time domain and frequency domain features, the present application uses wavelet transform (Wavelet Transform, WT) to extract frequency domain information. The formula of wavelet transform is as follows:

[0052]

[0053] Where Ψ(t) is the mother wavelet function, s is the scale parameter, τ is the translation parameter, and * represents the complex conjugate operation;

[0054] For the data after wavelet transform, the time domain feature F time (t) and the frequency domain feature F freq (f) are constructed; next, the feature fusion part is entered, and the fusion weight W time is calculated first.

[0055] W time =σ(Conv1D(GAP(F time (t)+F freq (f)))

[0056] Where W time is the adaptive weight, indicating the relative importance of time domain and frequency domain features. The weight is automatically learned through global average pooling (GAP) and one-dimensional convolution (Conv1D) layer, and σ is the Sigmoid activation function, which ensures that the output value is between [0, 1]. Finally, the fused feature representation F fusion is obtained.

[0057] F fusion =W time F time (t)+(1-W time )F freq (f)

[0058] Step 3: TCN-LSTM Combined Network: Build a combined structure of a temporal convolutional network (TCN) and a long short-term memory network (LSTM). The TCN is used to capture long-term dependencies. Dilated convolutions expand the time window, improving the model's ability to model long-term dependencies. The LSTM further extracts local temporal features and addresses the problem of capturing short-term dependencies. The combination of TCN and LSTM ensures that the model can account for both long-term and short-term dependencies when processing complex temporal features.

[0059] Based on the characteristics of wind power generation data, a combined network structure of a temporal convolutional network (TCN) and a long short-term memory network (LSTM) was constructed. TCN uses dilated convolution to expand the time window, effectively capturing long-term dependencies and enhancing the model's ability to model long-term features. LSTM is used to further extract local short-term dependencies and address short-term fluctuations. By combining TCN and LSTM, the model can simultaneously process long-term and short-term dependencies, improving its ability to perceive complex time series features.

[0060] Temporal Convolutional Network (TCN) handles long-term dependencies through causal convolution and dilated convolution.

[0061] Causal convolution: Causal convolution ensures that each time step in the output sequence depends only on the data before and after the current time step, maintaining the causal order of time. For the fused time-frequency feature input sequence, the calculation formula for causal convolution is:

[0062]

[0063] Where w i is the convolution kernel parameter, and k is the size of the convolution kernel. Causal convolution ensures that the convolution operation does not introduce future information.

[0064] Dilated convolution: In order to expand the receptive field, TCN introduced dilated convolution. Dilated convolution increases the interval between inputs by introducing a dilation factor d on the basis of standard convolution, thereby expanding the receptive field without increasing the number of parameters. The calculation formula of dilated convolution is:

[0065]

[0066] By adjusting the expansion factor d, TCN can gradually expand the time window in the multi-layer network to achieve modeling of long-term dependencies. The multi-layer expansion convolutional network can be expressed as:

[0067]

[0068] Where D represents the number of available dilation factors, is the output feature after multiple layers of causal convolution and dilated convolution, f represents the nonlinear activation function, is the convolution weight of the Lth layer, is the previous time step output from layer L-1;

[0069] LSTM is used to further capture local time series features. Its core formula is as follows:

[0070] The forget gate controls the memory state of the previous moment:

[0071] f t =σ(W f [h t-1 ,z t ]+b f )

[0072] Among them, f t is the activation value of the forget gate, σ is the sigmoid activation function, W f and b f are weight and bias parameters respectively, h t-1 is the hidden state at the previous moment, x t is the input at the current moment;

[0073] The input gate determines the update of the current information:

[0074] i t =o(W i [h t-1 , z t ]+b i )

[0075]

[0076] Among them, i t is the activation value of the input gate, is the candidate memory unit state, tanh is the hyperbolic tangent activation function, W i and W c is the weight matrix, b i and b c is the bias term

[0077] The cell state update combines the results of the forget gate and the input gate:

[0078]

[0079] Among them, ⊙ represents the element-wise product operation;

[0080] The output gate determines the output at the current moment:

[0081] ot =σ(W o [h t-1 ,z t ]+b o )

[0082] h t =o t ⊙tanh(c t )

[0083] Through the above formula, LSTM can capture local temporal features while maintaining the model's long-term memory capacity. Combined with the extensive time-dependent information extracted by TCN, the final output feature is expressed as:

[0084]

[0085] in, is the combined feature vector, which represents the final feature output after fusion; is the output feature of the LSTM model at time step t; is the output feature of the TCN model at time step t; β(t) is the time-varying adaptive adjustment function; W β is the trainable weight matrix; b β is the bias term.

[0086] Step 4: Multi-Head Self-Attention Mechanism: The model incorporates a multi-head self-attention mechanism (MHSA) to capture global dependencies in time series data using multiple parallel attention heads. This mechanism enhances the model's understanding of the contextual information in wind and photovoltaic power generation data, overcoming the limitations of traditional networks in modeling global dependencies. MHSA effectively improves the model's prediction accuracy by capturing global information across different attention dimensions through a multi-head mechanism.

[0087] The self-attention mechanism calculates the dependencies between positions in the sequence and assigns different weights to features at different positions. Given an input sequence H = {h1,h2,...,h T}, where the query matrix Q, key matrix K, and value matrix V are generated by linear transformation of the input:

[0088] Q=HW Q ,K=HW K ,V=HW V

[0089] Among them, W Q ,W K and W V is a learnable weight matrix. The self-attention calculation formula is:

[0090]

[0091] Among them, d k The dimension of the key vector is , and the softmax function ensures that the attention weights are normalized. Through this calculation, the model can focus on the correlation of different positions in the sequence at a global scale, thereby better capturing temporal dependencies;

[0092] The multi-head mechanism calculates the outputs of multiple self-attention heads in parallel and concatenates the results. The formula is as follows:

[0093] MHSA(H)=Concat(head1,head2,...,headn)W o

[0094] Among them, head i =Attention(Q i ,K i ,V i ), W o is the output linear transformation matrix;

[0095] The final prediction is made on the attention-weighted output:

[0096]

[0097] Among them, W out is the weight matrix of the output layer, b out is the bias term of the output layer;

[0098] Step 5: Model training and hyperparameter optimization: Use actual wind and photovoltaic power generation data to train the model and optimize the model's hyperparameters, including learning rate, batch size, and other parameters, to ensure model stability and generalization capabilities.

[0099] Loss function: Use root mean square error (RMSE) as the loss function

[0100]

[0101] Among them, y i is the true value, is the model prediction value;

[0102] Step 6: Model evaluation and prediction: Use root mean square error (RMSE), mean absolute error (MAE) and coefficient of determination (R 2 ) and other indicators to compare and evaluate the prediction performance of different models to ensure the prediction accuracy and robustness of the present invention in practical applications;

[0103]

[0104] Where p i and are the actual and predicted values of the power of the ith prediction point, respectively: is the average value of the observed values, and N is the number of test sample points.

[0105] Step seven: use the final combined time-frequency analysis and attention mechanism TCN-LSTM wind power generation prediction model to predict wind power generation.

[0106] Example 1:

[0107] Taking an actual wind farm in a certain province of China as the research object, the TCN-LSTM wind power generation prediction method combined with time-frequency joint analysis and multi-head self-attention mechanism is described in detail as follows:

[0108] Step one: data preprocessing: clean and preprocess the original data of wind power generation and photovoltaic power generation, eliminate invalid data, fill in missing values, and normalize the data to ensure the consistency and quality of the data;

[0109] The wind power generation prediction data takes air density (AD), wind speed (WS), and temperature (Tem) as the model input, and the power generation (WP) as the output. The sampling frequency is once every 1 h, and more than 8000 records are accumulated, showing a high time resolution. The preprocessed data is shown in Figure 2 ;

[0110] Step two: time-frequency joint feature analysis: extract the frequency domain features of the wind power generation data through wavelet transform, and adaptively weight and fuse them with the time domain features to construct a time-frequency joint analysis module (TFAA). This module can effectively extract multi-modal information and solve the problem that traditional models cannot fully consider the differences between time domain and frequency domain information;

[0111] As shown in Figure 3 , the wavelet decomposition results of the wind power generation prediction data are shown. After wavelet decomposition, the wind power data of each season is divided into approximate components and detail components. However, the length of the frequency domain information obtained by wavelet transform is half the length of the original wind power generation data sequence, so the two interpolation reconstruction method is used to process the frequency domain information to make it consistent with the length of the original wind power sequence information.

[0112] Step three: TCN-LSTM combined network: construct a combination structure of time convolution network (TCN) and long short-term memory network (LSTM), in which: the TCN network is used to capture long-term dependencies by expanding the time window through dilated convolution to improve the modeling ability of the model for long-term dependencies. The LSTM network is used to further extract local time sequence features to solve the problem of capturing short-term dependency information; through the combination of TCN and LSTM, the model can consider both long-term and short-term dependencies when processing complex time sequence features;

[0113] Step 4: Multi-head self-attention mechanism: The multi-head self-attention mechanism (MHSA) is introduced into the model to capture the global dependencies in time series data through multiple parallel attention heads. This mechanism enhances the model's ability to perceive contextual information and effectively improves prediction accuracy.

[0114] Step 5: Model training and hyperparameter optimization: Use actual wind and photovoltaic power generation data to train the model and optimize the model's hyperparameters, including learning rate, batch size, and other parameters, to ensure model stability and generalization capabilities.

[0115] The preprocessed dataset is divided into a training set, a validation set, and a test set, accounting for 80%, 10%, and 10% respectively. The training set is used to train the model, the validation set is used for hyperparameter tuning and model selection, and the test set is used for final performance evaluation.

[0116] The training results are as follows Figure 4 As shown in the figure, after 200 rounds of training, the loss value of the training set rapidly decreases from an initial value close to 1 and eventually stabilizes, reaching a minimum loss value of 0.12. The loss value of the validation set also shows a gradual downward trend during training, with a minimum loss value of 0.22, indicating that the model has good generalization ability on the test set and can effectively avoid overfitting.

[0117] The hyperparameter optimization process is as follows Figure 5 As shown, at lower learning rates (such as 10 -4 to 10 -3 ), the validation loss (RMSE) of the model decreases significantly, indicating that the model can converge effectively in this range; however, when the learning rate increases to 10 -2 When the batch size is larger than 50, the validation loss rises sharply, indicating that the model is over-adjusting weights, leading to unstable training or even divergence. Similarly, analysis of batch size shows that smaller batches (such as 50 to 100) can significantly reduce validation loss and optimize the model's generalization ability. However, when the batch size is too large, the model's ability to capture data is weakened, leading to an increase in validation loss.

[0118] The optimal points of learning rate and batch size are 10 -3 and 100, meaning that with a moderate configuration of these two hyperparameters, the model can train with optimal speed and stability, resulting in optimal performance. The shaded area in the figure represents the error band, and the upper and lower boundaries of the error band typically represent the upper and lower limits of a certain error metric. For example, in the figure, the values ​​within the error band represent the degree of fluctuation in validation loss (such as RMSE) at different learning rates or batch sizes. A wider error band indicates greater uncertainty in model performance at that learning rate or batch size, while a narrower error band indicates more stable model performance.

[0119] like Figure 6 As shown in the figure, common mother wavelets include Daubechies, Haar, Meyer, etc. In different application scenarios, the appropriate mother wavelet should be selected according to the characteristics of the signal and the purpose of analysis. In addition, the choice of decomposition scale determines the depth of the signal decomposition level, that is, the extent to which details are retained or noise is filtered out. The db4 and coif1 wavelets have lower root mean square errors (RMSE) in model prediction, but the db4 wavelet has smaller error fluctuations, indicating its higher stability and effectiveness in feature extraction. The figure on the right shows the impact of the choice of wavelet decomposition level on model performance. When the decomposition level is 4, the model has the lowest RMSE, the best performance, and the smallest error fluctuations, revealing that the appropriate decomposition level can effectively balance the refinement of feature extraction and the model's noise resistance.

[0120] Step 6: Model evaluation and prediction: Use root mean square error (RMSE), mean absolute error (MAE) and coefficient of determination (R 2 ) and other indicators to compare and evaluate the prediction performance of different models to ensure the prediction accuracy and robustness of the present invention in practical applications;

[0121] The RMSE (root mean square error), MAE (mean absolute error) and R of seven prediction models including ARIMA, RNN, GRU, LSTM, TCN-LSTM, LSTM-FCN and TCN-LSTM-MHSA in four seasons (spring, summer, autumn and winter) are calculated respectively during the wind power generation process. 2 (Three common evaluation indicators) Results. The specific results are shown in Table 1. By analyzing these indicators, we can more clearly understand the performance of each model in different seasons:

[0122] Table 1 Evaluation indicators of different wind power generation models

[0123]

[0124]

[0125] The definitions of the indicators in Table 1 are as follows:

[0126] RMSE (Root Mean Square Error): measures the root mean square of the square difference between the model's predicted value and the true value. The smaller the value, the smaller the model's prediction error and the higher the prediction accuracy. MAE (Mean Absolute Error): represents the average of the absolute differences between the predicted value and the true value. The smaller the value, the higher the model's prediction accuracy. 2 (Coefficient of determination): Measures the degree of fit of the model. The closer the value is to 1, the better the model fit is and the higher the prediction accuracy is.

[0127] Traditional wind power generation prediction models, such as ARIMA, RNN, GRU, LSTM, TCN, and LSTM-FCN models, all have shortcomings in certain aspects:

[0128] The ARIMA model is only suitable for linear time series data and performs poorly with the nonlinear characteristics of wind power generation, resulting in large prediction errors and poor adaptability to real-world scenarios. While the RNN model can capture short-term dependencies, it struggles with long-term dependencies due to the vanishing gradient problem, making it difficult to handle the complex time series patterns found in wind power generation. The GRU model optimizes RNNs through a gating mechanism, but still has limitations in processing multimodal information and cannot handle the nonlinear and multidimensional characteristics of wind power generation data. The LSTM model effectively addresses long-term dependencies, but its high complexity, long training time, and inability to simultaneously process time and frequency domain features limit its effectiveness in processing multimodal data. The TCN-LSTM combined model combines the advantages of TCN and LSTM and can capture short-term and long-term dependencies, but it still has limitations in global time series modeling and multimodal feature fusion. The LSTM-FCN model, while incorporating the feature extraction capabilities of convolutional networks, suffers from convolutional networks' limited ability to capture global features and cannot fully model global dependencies in time series data.

[0129] Model comparison analysis:

[0130] The ARIMA model performs better in summer. 2 Up to 0.858, but in autumn R 2 It is only 0.381, which shows its limitation in dealing with seasonal fluctuations. The LSTM model is better than ARIMA overall. 2 is 0.83. Although the error increases in winter, R 2 The TCN-LSTM model performs well in capturing complex time series features. 2 The RNN and GRU models have a higher MAE in spring. 2 The LSTM-FCN model has a better overall performance than 0.75, especially in spring. 2 The model proposed in this paper (TCN-LSTM-MHSA) outperforms the traditional model in all seasons, especially in summer. 2The value reached 0.87, demonstrating its significant advantage in capturing the complex time series characteristics of wind power generation data. Furthermore, the model's RMSE and MAE values ​​were lower than those of other models, further validating its effectiveness and robustness in wind power generation forecasting. These comparative analyses demonstrate that different models have their own strengths and weaknesses in wind power generation forecasting, while the proposed model demonstrates strong comprehensive capabilities and warrants further exploration and optimization in practical applications.

[0131] like Figure 7 As shown, A, B, C, D, and E represent TCN-LSTM-TFAA-MHSA, No TFAA, No TCN, No LSTM, and NoMHSA. The RMSE and MAE of the model in spring are 0.11 and 0.079, respectively. 2 In summer, although the overall error decreased and the RMSE of the full model dropped to 0.105, the R 2 The value rises to 0.87, indicating that the model's prediction accuracy for summer wind power generation is further improved. In contrast, the ablation of the TFAA module has the most significant impact on the model, especially in autumn and winter, with RMSE rising to 0.138 and 0.128 respectively, and R 2 The values ​​dropped to 0.76 and 0.78 respectively, which shows that the TFAA module plays a key role in the complex seasonal fluctuations. The ablation of TCN and LSTM modules mainly affects the temporal dependency modeling of the model, especially in summer. After ablating TCN, R 2 The value dropped from 0.87 to 0.84.

[0132] Comprehensive data analysis shows that the complete wind power generation model outperforms any model with a single module removed across different seasons. The TFAA module, in particular, plays an irreplaceable role in addressing seasonal variations; the TCN and LSTM modules play a crucial role in capturing temporal dependencies and long-term patterns. Future model optimization should focus on strengthening these key modules, particularly tuning performance across different seasons, to further enhance the model's prediction accuracy and generalization capabilities. These results provide important data support and theoretical basis for improving energy forecasting models, and this invention can be applied to solar power generation forecasting.

Claims

1. A TCN-LSTM wind power generation prediction method combining time-frequency analysis and attention mechanism, characterized by The steps include: Step 1: Obtaining the original data of wind power generation and preprocessing the original data of wind power generation; Step 2: After data preprocessing, the frequency domain features of the wind power generation data are extracted through wavelet transform, and adaptive weighted fusion is performed with the time domain features to construct a time-frequency joint analysis module (TFAA). This module performs time-frequency joint feature analysis, extracts multimodal information, and obtains the wind power generation data set. Step 3: Build a TCN-LSTM combined network consisting of a temporal convolutional network (TCN) and a long short-term memory (LSTM) network. This improves the ability to perceive complex temporal features by processing both long-term and short-term dependency features. Step 4: Introduce the multi-head self-attention mechanism into the TCN-LSTM combined network to obtain a TCN-LSTM wind power generation prediction model that combines time-frequency analysis and the attention mechanism. By using multiple parallel attention heads to capture global dependencies, the model can perceive the contextual information of wind power generation data. Step 5: Use the wind power generation dataset generated in step 2 to train the model and optimize key parameters through hyperparameter optimization; Step 6: Evaluate the prediction performance of the trained TCN-LSTM wind power generation prediction model that combines time-frequency analysis and attention mechanism, and obtain the final TCN-LSTM wind power generation prediction model that combines time-frequency analysis and attention mechanism; Step 7: Use the final TCN-LSTM wind power generation prediction model that combines time-frequency analysis and attention mechanism to predict wind power generation.

2. The TCN-LSTM wind power generation prediction method combining time-frequency analysis and attention mechanism according to claim 1 is characterized by: The step 1 is specifically as follows: 1.

1. Data cleaning: Eliminate unreasonable records from the original data of wind power generation, which includes air density, wind speed, and temperature; 1.

2. Data interpolation: cubic spline interpolation is used to fill in missing data to ensure data continuity; 1.

3. Normalization: Use maximum and minimum normalization on all data to scale the data range to [0,1].

3. The TCN-LSTM wind power generation prediction method combining time-frequency analysis and attention mechanism according to claim 2 is characterized by: The method for constructing the time-frequency joint analysis module in step 2 is specifically as follows: 2.

1. Use wavelet transform to extract frequency domain feature information of pre-processed wind power generation data; 2.

2. Construct the time domain feature F for the data after wavelet transformation time (t) and frequency domain features F freq (f); 2.3、The time domain feature F time (t) and frequency domain features F freq (f) Feature fusion, calculation of fusion weight W time ; W time =σ(Conv1D(GAP(F time (t)+F freq (f)))) Where W time is the adaptive weight, which represents the relative importance of time domain and frequency domain features. The weight is automatically learned through the global average pooling GAP and the one-dimensional convolution Conv1D layer. σ is the Sigmoid activation function, and the output value is between [0, 1]. 2.

4. Obtain the fused feature representation F fusion : F fusion =W time F time (t)+(1-W time )F freq (f)。 4. The TCN-LSTM wind power generation prediction method combining time-frequency analysis and attention mechanism according to claim 3 is characterized by: The TCN-LSTM combined network model in the steps is as follows: Where, is the combined feature vector, which represents the final feature output after fusion; is the output feature of the LSTM model at time step t; is the output feature of the TCN model at time step t; β(t) is the time-varying adaptive adjustment function; W β is the trainable weight matrix; b β is the bias term.

Citation Information

Patent Citations

  • Photovoltaic short-term generating capacity prediction method integrated with time-frequency analysis

    CN114282711A

  • Wind power ultra-short-term prediction method based on SATCN-LSTM

    CN114676814A