Photovoltaic power generation power prediction method based on feature generation and cross attention mechanism

Through the photovoltaic power prediction method based on feature generation and cross attention mechanism, the existing model's prediction problem under complex meteorological conditions is solved, and the prediction accuracy and robustness are achieved, which is suitable for photovoltaic power prediction in different seasons.

CN119891175APending Publication Date: 2025-04-25ZHEJIANG UNIV +2

Patent Information

Application Number
CN202411964855.6
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-12-30
Publication Date
2025-04-25

AI Technical Summary

Technical Problem

The existing photovoltaic power prediction model has room for improvement in fully exploring multi-scale time characteristics, capturing the correlation between history and future meteorological conditions, and integrating the physical mechanism of photovoltaic power generation, and it is difficult to accurately predict the output of photovoltaic power under complex meteorological conditions.

Method used

The photovoltaic power generation power prediction method based on feature generation and cross attention mechanism is adopted. By collecting physical information and historical meteorological data of the photovoltaic power station, the effective irradiance and component temperature are calculated, the characteristics are extracted in different neural network structures, and the characteristics are fused in the long-term cross attention mechanism module to predict the power generation power.

Benefits of technology

It improves the accuracy and robustness of photovoltaic power generation prediction, reduces nRMSE in different seasons by about 20%, and enhances the model's understanding of the physical characteristics of the photovoltaic system and captures multi-scale time characteristics.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119891175A_ABST
    Figure CN119891175A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of new energy prediction, and particularly discloses a photovoltaic power generation power prediction method based on feature generation and a cross attention mechanism, and the method comprises the steps: obtaining key features, such as effective irradiance and assembly temperature, highly related to the power generation amount through the irradiance calculation of a module inclined plane method and a heat conduction mechanism; feature extraction modules with different network structures are designed, slow time-varying features and time sequence features are deeply mined, and a long-short term cross attention mechanism is introduced, so that the model can fully utilize long-term historical data and recent meteorological changes to capture key factors which have significant influence on future power generation power. According to the method, actual operation data of the photovoltaic power station are adopted for verification, nRMSE is reduced by about 20% compared with other models in four seasons, and the result shows that the precision in the prediction result is remarkably improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of new energy prediction technology, and in particular to a photovoltaic power prediction method based on feature generation and cross-attention mechanism. Background Art

[0002] As one of the most promising renewable energy sources in the world, solar energy has significant advantages such as abundant resources, clean and pollution-free, easy to obtain and utilize, and sustainable supply. In recent years, solar energy technology has received widespread attention and rapid development worldwide. Photovoltaic power stations have become an important part of the renewable energy field by directly converting solar energy into electrical energy. However, photovoltaic power generation has large volatility and randomness, because its power generation is usually affected by multiple factors such as the position of the sun, weather conditions, and climate change. This volatility has brought great challenges to the operation and planning of the power grid and increased the difficulty of maintaining the stability of the power grid. With the continuous expansion of the installed capacity of photovoltaic power stations, accurate prediction of photovoltaic power generation is crucial to ensure the reliability and stability of the power system. Accurate photovoltaic power prediction can not only reduce the system operation cost and uncertainty, but also effectively avoid power grid accidents that may be caused by the deviation between the predicted value and the actual power generation. Therefore, the development of a high-precision photovoltaic power prediction model has become a hot spot and difficulty in current research.

[0003] Although photovoltaic power generation prediction has made some progress in theory and technology, the existing hybrid models still have room for improvement in fully exploring multi-scale temporal characteristics, capturing the relationship between historical and future meteorological conditions, and integrating the physical mechanism of photovoltaic power generation. Therefore, it is necessary to build a prediction model that can simultaneously utilize the advantages of physical mechanisms and data-driven. Summary of the invention

[0004] The present invention provides a photovoltaic power prediction method based on feature generation and cross-attention mechanism to solve the problem of output prediction under complex meteorological conditions.

[0005] The power transfer learning prediction method for a newly built photovoltaic station by coupling irradiance and temperature comprises the following steps:

[0006] Step 1: Collect the physical information of the photovoltaic power station (such as the tilt angle and azimuth of the module), historical meteorological data, weather forecast data, and the operation data of the photovoltaic modules (such as historical power generation). Preprocess the data, including outlier detection, missing value filling, and data cleaning, to ensure data quality and integrity;

[0007] Step 2: Based on the principle of irradiance absorption by photovoltaic modules and the mechanism of heat transfer, calculate the two key characteristics of effective irradiance and module temperature. Effective irradiance calculation: Use the inclination and azimuth of the module to convert direct irradiance, scattered irradiance and ground reflected irradiance into irradiance in the normal direction of the module. Module temperature calculation: Consider ambient temperature, wind speed, and relative humidity factors, combine heat transfer models with measured data, and estimate the key parameters of module temperature. Combine the calculated effective irradiance and module temperature with the original data to construct a new power prediction model data set;

[0008] Step 3, divide the input data of the model into three parts. Day Ahead Features: including the power generation and meteorological data of the previous day, used to capture the slow time-varying characteristics and health status of photovoltaic modules. Intraday Features: including recent power generation and meteorological data, used to capture recent time series characteristics and meteorological changes. Future Features: including meteorological forecast information from the current time to the predicted time, used to predict the impact of future meteorological conditions on power generation;

[0009] Step 4: For different input data, different neural network structures are used for feature extraction. Day-ahead features: CNN extracts slow time-varying features to capture the long-term operating mode, historical weather, and equipment health status of PV modules. Intraday features: LSTM extracts time series features to capture the dynamic relationship between recent weather changes and power generation. Future features: LSTM network is used to extract future weather features and model the impact of future weather conditions on power generation;

[0010] Step 5: Input the features extracted in step 4 into the long-short-term cross attention mechanism (LSCAM) module, and apply the cross attention mechanism on the long-term and short-term time windows respectively;

[0011] Step 6: Input the fused features into the fully connected layer to predict the power generation. During the training process, appropriate loss functions and optimization algorithms are used to minimize the prediction error;

[0012] Step 7: Use the Optuna library to automatically adjust and optimize the model's hyperparameters, including the number of network layers and neurons. Use the Bayesian optimization method to find the best hyperparameter combination to improve the model's performance and prediction accuracy.

[0013] Step 8: Considering the seasonal changes in solar radiation intensity and duration, the data set is divided into seasons (spring, summer, autumn, and winter). The model is trained, validated, and tested for each seasonal data set, so that the model can focus on the specific patterns of each season and improve the accuracy and robustness of the prediction;

[0014] As a preferred method, model migration depends on the feature similarity between the two photovoltaic power plants. Using two photovoltaic power plants in the same area for model migration will obtain better prediction results.

[0015] Preferably, the slope irradiance feature extraction module is sensitive to the inclination and orientation angles of photovoltaic modules. For scenes with complex changes in mountain photovoltaic angles, a detailed analysis of the placement of photovoltaic modules in each area is required to ensure the effectiveness of feature extraction.

[0016] Preferably, the photovoltaic module inclined surface irradiance mechanism model expression is as follows:

[0017]

[0018] Among them, I e represents the prediction data of effective irradiance of photovoltaic modules based on empirical knowledge, I b ×R b Indicates the direct solar irradiance on the slope, I b is the direct solar irradiance on the horizontal plane, represents the amount of direct solar radiation on the inclined surface, β is the tilt angle of the photovoltaic module, and I d is the solar diffuse irradiance on the horizontal plane, represents the ground reflected irradiance, and ρ is the ground reflectivity.

[0019] Preferably, the photovoltaic module temperature mechanism expression is as follows:

[0020]

[0021] Among them, T m Indicates the temperature of the photovoltaic module, T a represents the ambient temperature, a represents the irradiance absorption rate of the photovoltaic module, η r Indicates the efficiency of the PV module at the reference temperature, T r represents the reference temperature, μ represents the temperature coefficient of the photovoltaic module, U PV The heat exchange coefficient of the total surface area of ​​the photovoltaic module is expressed as follows:

[0022] U PV =bv+c (3)

[0023] Among them, v represents wind speed, b and c represent coefficient and constant term respectively.

[0024] Preferably, after calculating the effective irradiance and component temperature, the feature generation method of the model merges these key features with the original data to construct a new power prediction model data set, so that the model can more accurately capture the complex relationship between photovoltaic power generation and meteorological factors, thereby improving the accuracy and robustness of the prediction.

[0025] As a preference, the root mean square error (RMSE), normalized root mean square error (nRMSE), accuracy, mean absolute error (MAE), and coefficient of determination (R 2 ) is used as the evaluation index of the model, and its expression is:

[0026]

[0027]

[0028] Where: m is the number of data; is the predicted value of the i-th data; y i is the i-th data; is the data average.

[0029] As a preferred method, RMSE measures the deviation between the predicted value and the true value, is more sensitive to outliers in the data, and can evaluate the overall prediction accuracy in photovoltaic power generation prediction, with the unit of MW; nRMSE is the normalized version of the root mean square error RMSE, which is scaled by dividing by the actual value range or average value to make the error evaluation comparable on data of different magnitudes; MAE represents the average of the absolute errors between the predicted value and the observed value. MAE is a linear score, all individual differences have equal weight on the average value, and there is no problem of enlarging the error due to square addition. Therefore, as a loss function, its robustness to outliers is higher than RMSE, with the unit of MW; accuracy measures the deviation between the prediction result at the 4th hour and the true value, with no unit; R 2 Indicates the correlation between the predicted value and the actual value, unitless.

[0030] Compared with the prior art, the beneficial effects and advantages of the present invention are:

[0031] (1) The present invention uses physical modeling and heat transfer principles to generate key features such as effective irradiance and component temperature, enhancing the model's understanding of the physical characteristics of the photovoltaic system.

[0032] (2) The present invention extracts slow time-varying features and time series features respectively through different network structures, thereby improving the model's ability to perceive information at different time scales.

[0033] (3) The present invention introduces LSCAM to balance the impact of different time scales and capture the correlation between historical meteorological data and future meteorological data. The nRMSE is reduced by about 20% on the test sets of different seasons, which improves the accuracy and robustness of the forecast. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] Figure 1 It is a flowchart of the photovoltaic power prediction method based on feature generation and cross attention mechanism of the present invention;

[0035] Figure 2 It is a flow chart of the mechanism data feature generation model of the present invention;

[0036] Figure 3 It is a flowchart of the long-term and short-term window cross attention mechanism of the present invention;

[0037] Figure 4 It is a comparison diagram of the component temperature calculation result and the actual measurement value of the present invention;

[0038] Figure 5 is a diagram of ablation experiment results of the present invention;

[0039] Figure 6 It is a spring test set prediction result diagram of the present invention;

[0040] Figure 7 It is a summer test set prediction result diagram of the present invention;

[0041] Figure 8 This is a graph of the prediction results of the autumn test set of the present invention;

[0042] Fig. 9 This is a graph of the prediction results of the winter test set of the present invention. DETAILED DESCRIPTION

[0043] The present invention will be described in detail below through specific embodiments in combination with the accompanying drawings so that people can understand the content and specific features of the present invention more intuitively and vividly, but the protection scope of the present invention is not limited to the following embodiments.

[0044] As attached Figure 1As shown, the present invention relates to a photovoltaic power prediction method based on feature generation and cross-attention mechanism, including data acquisition and data preprocessing, according to the analysis of the received irradiance and heat transfer mechanism of the component surface, the establishment of a coupling mechanism data-driven feature generation model, the establishment of feature extraction modules of different network structures, and the construction of a photovoltaic output prediction model based on the long-term and short-term window cross-attention mechanism. Through training and verification on different seasonal data sets, seasonal photovoltaic output prediction is achieved. The present invention first obtains the photovoltaic power generation historical data required for modeling and the meteorological data of different photovoltaic power stations, performs data preprocessing, and cyclically divides the data into training sets, verification sets, and test sets in a 3-week, 1-week, and 1-week manner, and constructs the input of the prediction model in combination with the established feature extraction module, and finally obtains the power generation prediction data of the photovoltaic power station in the future period by training in different seasons.

[0045] Example 1

[0046] A photovoltaic power station in Zhejiang Province is used to verify the effectiveness of the photovoltaic power prediction method based on the coupling mechanism data-driven feature generation and long-term and short-term cross-attention mechanism. The photovoltaic power station has been in operation for a long time and can collect data for a two-year period.

[0047] The collected data include PV power station power generation (PV output), GHI, DHI, DNI, environment temperature (ET), module temperature (Module temperature), wind speed (WS), relative humidity (RH), and the time resolution of the data is 15 minutes.

[0048] The historical data of photovoltaic power generation of photovoltaic power stations are collected, and the environmental monitoring instrument of the photovoltaic power station is used to obtain the data of environmental factors that affect photovoltaic power generation, such as horizontal irradiance, direct irradiance, scattered irradiance, ambient temperature, wind speed, and humidity. The data are preprocessed by eliminating outliers and filling in missing values, and the data set is divided into spring, summer, autumn, and winter according to the season.

[0049] In order to effectively capture the impact of equipment health status on power generation, feature extraction modules for different network structures were developed. Since CNN has significant advantages in spatiotemporal feature extraction and can capture the long-term trend of equipment performance, CNN is used to extract slow time-varying features for the power generation information one day before the forecast day. The slow time-varying features are used to consider the impact of equipment efficiency decline on power generation and correct the power generation on the forecast day. At the same time, the LSTM network is used for feature extraction for the meteorological and power generation information 4 hours before the current operating time. LSTM is good at capturing short-term dependencies in time series and can effectively identify the dynamic correlation between recent meteorological changes and power generation, which enables the model to more accurately predict short-term changes in power generation. Finally, for weather forecast data at future moments, LSTM is used for feature extraction to capture the impact of future meteorological conditions on power generation. By modeling future meteorological data, the model can predict the impact of meteorological changes in advance and improve the foresight of the forecast.

[0050] In the LSCAM module, the day-ahead features are used as Q, and the future features are used as K and V in the long-term time window. This window is designed to explore the relationship between current and future weather conditions using historical data. By calculating the similarity between historical data and future data, the model can identify the impact of long-term meteorological changes (such as seasonal changes, continuous sunny and rainy weather) on current power, thereby improving the stability and reliability of the forecast. In the short-term time window, the intraday features are used as Q, while the future features are still K and V. The model aims to capture the correlation between short-term meteorological changes and future meteorological conditions, and identify the direct impact of rapidly changing meteorological conditions (such as sudden direct radiation, scattered radiation) on power generation. CAM in the short-term window can focus on these key moments, ensuring that the model can dynamically adjust the forecast to reflect the rapid changes in meteorological conditions in a timely manner. Applying LSCAM, the model is able to balance the impact of different time scales. The attention mechanism can adaptively allocate weights between time windows according to the temporal pattern of the data, allowing the model to effectively integrate multi-scale meteorological influences, thereby automatically adjusting the forecast according to the current environmental changes. Historical data provides important background information for predicting the future, and the introduction of future data further improves the prediction accuracy of the model.

[0051] Taking into account the confirmation of different modules for the improvement of the accuracy of the photovoltaic power prediction model and the verification of the influence of feature extraction modules and LSCAM modules with different network structures on the performance of the photovoltaic power prediction model, the present invention designed and implemented the following ablation experiments on the annual data set. Baseline model: The calculation results of the fusion mechanism data-driven feature generation model. The photovoltaic power prediction model uses the LSTM network structure, but does not include feature extraction modules and LSCAM with different network structures. Baseline model + A: On the basis of the baseline model, feature extraction modules with different network structures are added to extract richer feature information. Baseline model + A + B: On the basis of the baseline model, feature extraction modules and LSCAM mechanism modules with different network structures are introduced at the same time to make full use of multi-scale features and time series information. The test set of each experiment was quantitatively evaluated, and the results are as follows. Figure 5 shown.

[0052] based on Figure 5 The results show that the baseline model + A + B achieved the best results in all indicators, with an R of 0.979. 2 , with nRMSE of 0.0374, MAE of 0.927, and RMSE of 2.449; followed by the baseline model + A, which obtained an R of 0.974 2 , nRMSE of 0.0419, MAE of 1.142 and RMSE of 2.745; the performance of the baseline model is weaker than the previous two. It is proved that by combining the feature extraction of different network structures with LSCAM, the model can more comprehensively capture the key features and time relationships in the data, providing strong support for the accurate prediction of photovoltaic power generation.

[0053] Figure 6 , Figure 7 , Figure 8 and Fig. 9 , a, b, c, and d show the prediction results of the test set in different seasons in detail. Figure a uses a curve to specifically illustrate the difference between the predicted values ​​and the actual values ​​of different models for a certain day in the season. Figure b shows the superimposed prediction error of all models, and the prediction error is defined as the difference between the actual value and the predicted value. Finally, Figures c and d summarize the evaluation indicators of all prediction models, including nRMSE and accuracy key performance indicators. These results verify the effectiveness of the proposed model in photovoltaic power generation prediction and more accurately reflect the stability of the model in different seasons.

[0054] The prediction results are shown in Table 2:

[0055] Table 2 Prediction results of different prediction models for different weather types

[0056]

[0057]

[0058] Preferably, by comparing the prediction results of different models, it can be seen that on data sets of different seasons, the photovoltaic power prediction model of coupling mechanism data-driven feature generation and long-term and short-term cross-attention mechanism shows higher prediction accuracy, which is better than other models. All indicators are greatly improved compared with other models, which verifies that the photovoltaic power prediction method of coupling mechanism data-driven feature generation and long-term and short-term cross-attention mechanism has high adaptability on data sets of different seasons. The comparison chart of evaluation indicators of each model in each season is as follows: Figure 6 , Figure 7 , Figure 8 , Fig. 9 shown.

[0059] Preferably, the mechanism data driven feature generation, different network structure feature extraction and LSCAM module extract slow time-varying features and time series features, balance information from different time scales, and capture the relationship between meteorological changes and future power generation. It effectively improves the accuracy and robustness of photovoltaic power generation prediction, successfully captures the complex spatiotemporal dependence of photovoltaic power generation, and provides strong support for the stable operation of the power grid.

[0060] Other technologies mentioned in the present invention, such as LSTM, CNN network structure, etc., are all existing technologies and are not described in detail.

[0061] The present invention is described in detail above in conjunction with the embodiments, but the contents described are only preferred embodiments of the present invention and cannot be considered to limit the scope of implementation of the present invention. All equivalent changes and improvements made according to the scope of application of the present invention should still fall within the scope of the patent coverage of the present invention.

Claims

1. A photovoltaic power prediction method based on feature generation and cross-attention mechanism, characterized in that: The following steps are involved: Step 1: Define the prediction of the power generation of a photovoltaic power station in the next 15 minutes to 4 hours as a prediction task. Different photovoltaic power stations correspond to different prediction tasks. Step 2: Collect physical information of the PV power station, historical meteorological data, weather forecast data, and operating data of PV modules to provide a comprehensive data foundation for the model; Step 3: Analyze the heat transfer principle of the irradiance received on the surface of photovoltaic modules and the module temperature, build a feature generation model driven by mechanism data, calculate the two key features of effective irradiance and module temperature, merge these features with the original data, build a new power prediction model data set, and enhance the model's ability to describe physical processes; Step 4: The input of the power prediction model is mainly divided into three parts: (1) Historical data of the previous day: providing long-term historical information, reflecting the health status and slow time-varying characteristics of the PV modules; (2) Historical data of the four hours before the current moment: providing short-term historical information, capturing the dynamic characteristics of recent meteorological changes and power generation; (3) Weather forecast information from the current moment to the predicted moment: providing data on future meteorological conditions to help the model predict future power generation; Step 5: Different neural network structures are used for feature extraction for different input data: For the historical data of the previous day, a convolutional neural network is used to extract slow time-varying features to capture the long-term operation mode and health status of the PV modules. For the historical data of the previous four hours, a long short-term memory network is used to extract time series features to capture the dynamic relationship between recent meteorological changes and power generation. For future weather forecast data, an LSTM network is also used to extract future weather features to model the impact of future weather conditions on power generation. Step 6: Input the features extracted in step 5 into the long-term and short-term cross attention mechanism module, and apply the cross attention mechanism on the long-term and short-term time windows respectively. In the long-term time window, the historical features of the previous day are used as Q, and the future meteorological features are used as K and V to capture the association between long-term meteorological changes and future power generation. In the short-term time window, the recent historical features are used as Q, and the future meteorological features are used as K and V to capture the immediate impact of short-term meteorological fluctuations on future power generation. Step 7: Considering that the intensity and duration of solar radiation fluctuate significantly due to seasonal changes, the dataset is divided by season so that the model can focus on the specific patterns of each season. The model is trained, validated, and tested for datasets in different seasons. Step 8: Use the Optuna library to automatically adjust and optimize the model's hyperparameters, and use the Bayesian optimization algorithm to find the best hyperparameter combination. Hyperparameter optimization aims to improve the prediction accuracy and robustness of the model, prevent overfitting or underfitting, and ensure that the model has good generalization ability under different seasons and meteorological conditions; Step 9: The model is trained on data sets of different seasons, and the prediction results are compared with the power generation power measurement values. The prediction performance of the model on data sets of different seasons is evaluated to obtain a photovoltaic power generation power prediction model suitable for four seasons.

2. The photovoltaic power prediction method based on feature generation and cross-attention mechanism according to claim 1 is characterized in that: The physical information of the power station includes the longitude and latitude of the power station, the azimuth of the support, and the inclination of the support; the historical meteorological data and numerical weather forecast data include direct irradiance DNI, scattered irradiance DHI, horizontal irradiance GHI, ambient temperature and relative humidity; the power station operation data includes the generated power and the inverter voltage and current.

3. The photovoltaic power prediction method based on feature generation and cross-attention mechanism according to claim 1 is characterized in that: The features calculated by the mechanism data-driven feature generation model are effective irradiance and component temperature, which are integrated with DNI, DHI and GHI features to form the prediction model features.

4. The photovoltaic power prediction method based on feature generation and cross-attention mechanism according to claim 1 is characterized in that: The prediction feature extraction module consists of three parts, including day-ahead features, intraday features, and future features.

5. The photovoltaic power prediction method based on feature generation and cross-attention mechanism according to claim 1 is characterized in that: CNN is used to extract day-ahead features, and LSTM is used to extract intraday features and future features.

6. The photovoltaic power prediction method based on feature generation and cross-attention mechanism according to claim 1 is characterized in that: The day-ahead features and future features are processed through the long-term window of LSCAM, and the intraday features and future features are processed through the short-term window of LSCAM.

Citation Information

Patent Citations

  • Photovoltaic power prediction method of deep neural network model fused with attention mechanism

    CN110909919A

  • Power transfer learning prediction method for newly-built photovoltaic station coupling irradiance and temperature

    CN118643328A

  • Photovoltaic power generation prediction method and device

    CN118760888A

  • Hybrid photovoltaic power prediction method and system based on multi-source data fusion

    US20220373984A1

Cited By

  • Short-term net load prediction method and system considering seasonal characteristics

    CN121261333A

  • Ultra-short-term solar irradiance prediction method, equipment and medium

    CN122241136A