Photovoltaic power prediction method and system considering physical mechanism correction
By using a physics-neural network joint model and GA genetic algorithm optimization, combined with historical and future data, photovoltaic power prediction is performed, solving the problem that the prediction results in existing technologies do not conform to physical principles, and achieving higher prediction accuracy and adaptability.
Patent Information
- Application Number
- CN202411810878.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-10
- Publication Date
- 2026-05-15
- Estimated Expiration
- 2044-12-10
AI Technical Summary
Existing photovoltaic power generation prediction models cannot guarantee that the prediction results comply with physical principles, resulting in output power exceeding the upper limit of photovoltaic system capacity or failing to fully consider key meteorological factors such as temperature and irradiance, thus affecting the accuracy of prediction.
A physics-neural network joint model is adopted, which combines historical photovoltaic power plant data and physical data at future moments. The weights and hyperparameters are optimized through GA genetic algorithm, and physical correction is performed to ensure that the prediction results meet the physical constraints of the photovoltaic system.
It significantly improves the accuracy and robustness of photovoltaic power prediction, can adapt to different weather conditions and environmental changes, reduces prediction deviations, and supports the stable operation of photovoltaic power plants.
Smart Images

Figure CN119740747B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of photovoltaic power generation prediction technology, and relates to a photovoltaic power prediction method and system that takes into account physical mechanism correction. Background Technology
[0002] With the transformation of the global energy structure and the rapid development of renewable energy, photovoltaic power generation, as an important component of renewable energy, is becoming increasingly important. Photovoltaic power generation utilizes the photovoltaic effect to directly convert sunlight into electricity, and has advantages such as being clean, pollution-free, and sustainable. It is of great significance for reducing greenhouse gas emissions and promoting sustainable energy development.
[0003] However, photovoltaic (PV) power generation is significantly affected by various meteorological conditions, including solar irradiance, ambient temperature, and wind speed. These meteorological conditions are complex and difficult to predict accurately, resulting in significant fluctuations and uncertainties in PV power output. This uncertainty poses a significant challenge to power system operation, scheduling, and load balancing. Therefore, accurately predicting PV power output is crucial for ensuring the stable operation of the power system and the efficient utilization of renewable energy.
[0004] In recent years, with the rapid development of machine learning and deep learning technologies, data-driven forecasting methods have gradually become the mainstream in the field of photovoltaic power generation forecasting. In particular, deep learning technologies such as Long Short-Term Memory (LSTM) networks have achieved significant results in photovoltaic power generation forecasting due to their powerful data processing capabilities and nonlinear relationship learning abilities. These models can learn the complex relationship between photovoltaic power generation and meteorological conditions from a large amount of historical data and can adapt well to changing meteorological conditions, improving the accuracy and stability of forecasts.
[0005] While machine learning and deep learning technologies have shown great potential in photovoltaic (PV) power generation forecasting, they also have some inherent problems. Because these models are data-driven, they cannot guarantee that the predictions adhere to the underlying physical principles. Therefore, in practical applications, these models may produce physically unreasonable predictions, such as output power exceeding the capacity limit of the PV system, or failing to adequately consider the direct impact of key meteorological factors such as temperature and irradiance on power output. These problems not only affect the accuracy of the predictions but may also adversely impact the operation, scheduling, and load balancing of the power system. Summary of the Invention
[0006] The purpose of this invention is to solve the technical problem that the output power exceeds the capacity limit of the photovoltaic system or the direct impact of key meteorological factors such as temperature and irradiance on the power in the prior art is not fully considered, which leads to a decrease in the accuracy of the prediction. The invention provides a photovoltaic power prediction method and system that considers physical mechanism correction.
[0007] To achieve the above objectives, the present invention employs the following technical solution:
[0008] The first aspect of this invention provides a photovoltaic power prediction method considering physical mechanism correction, comprising the following steps:
[0009] Acquire historical photovoltaic power plant data and physical data of photovoltaic power plants at future moments;
[0010] Based on historical photovoltaic power plant data, parameters with high correlation to photovoltaic power are selected as prediction input parameters;
[0011] The historical photovoltaic power plant data corresponding to the predicted input parameters and the physical data of the photovoltaic power plant at future moments are input into a pre-trained physical-neural network joint model to obtain the final predicted photovoltaic power.
[0012] The training method for the pre-trained physical-neural network joint model is as follows:
[0013] The historical photovoltaic power plant data corresponding to the predicted input parameters are input into the neural network model to obtain the predicted photovoltaic power by the neural network.
[0014] Based on the physical data of the photovoltaic power station at future moments, the physical prediction of photovoltaic power is obtained;
[0015] The weights of the neural network-predicted photovoltaic power and the physical-predicted photovoltaic power are adjusted to obtain the final predicted photovoltaic power.
[0016] The joint loss function is determined based on the final predicted photovoltaic power and the actual photovoltaic power.
[0017] Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model.
[0018] Furthermore, the physical data includes direct irradiance, solar altitude angle, azimuth angle, panel tilt angle and orientation, total irradiance on the horizontal plane, ground reflectivity, scattering coefficient and reflection coefficient.
[0019] Furthermore, the step of selecting parameters with high correlation to historical photovoltaic power output as prediction input parameters based on historical photovoltaic power plant data specifically involves:
[0020] The correlation between historical photovoltaic power plant data and historical photovoltaic data is calculated using the Pearson correlation coefficient, and parameters with high correlation are selected as prediction input parameters.
[0021] Furthermore, the physical prediction of photovoltaic power is described as follows:
[0022]
[0023] in, Indicates effective irradiance. Indicates the area of the photovoltaic panel. This indicates the temperature-dependent conversion efficiency.
[0024] Furthermore, the final predicted photovoltaic power is described as follows:
[0025]
[0026] in, Indicates the physical prediction of photovoltaic power; This indicates that the neural network predicts photovoltaic power. This represents the weighting coefficient, with a value range of [0, 1].
[0027] Furthermore, the joint loss function is described as follows:
[0028]
[0029] in, N This indicates the sequence length of the final predicted photovoltaic power. The sequence representing the final predicted photovoltaic power is numbered. i The value of the position, The sequence representing the actual photovoltaic power generation is numbered. i The value of the position.
[0030] Furthermore, based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model, specifically:
[0031] The negative value of the joint loss function is selected as the fitness function; multiple individuals are randomly generated as the initial population; each individual represents a set of parameter vectors; the parameter vectors include the hyperparameters of the neural network model and the weight coefficients of the neural network-predicted photovoltaic power and the physical-predicted photovoltaic power;
[0032] Iterate through the following steps until the population fitness no longer increases significantly, then select the individual with the highest fitness in the population as the optimal parameter vector combination:
[0033] Based on the fitness function, the roulette wheel selection method is used to select individuals with higher fitness in the population, resulting in a population with high fitness.
[0034] Based on a population with high fitness, two individuals are randomly selected and cross-crossed using a uniform cross-cross method to generate new individuals;
[0035] New individuals are randomly mutated and added to the new population, while the individuals with the highest fitness in the high-fitness population are retained.
[0036] Furthermore, after obtaining the final predicted photovoltaic power, the following steps are also included:
[0037] If the current irradiance is less than the preset irradiance threshold, the final predicted photovoltaic power will be 0.
[0038] When the final predicted photovoltaic power is greater than or equal to the maximum power of the actual photovoltaic system, then the final predicted photovoltaic power is the maximum power of the actual photovoltaic system.
[0039] Furthermore, the neural network model is an LSTM model.
[0040] A second aspect of the present invention provides a photovoltaic power prediction system that considers physical mechanism correction, comprising:
[0041] The data acquisition module acquires historical photovoltaic power plant data and physical data of the photovoltaic power plant at future moments;
[0042] The input parameter confirmation module selects parameters that are highly correlated with historical photovoltaic power as prediction input parameters based on historical photovoltaic power plant data.
[0043] The photovoltaic power prediction module inputs the historical photovoltaic power plant data and the physical data of the photovoltaic power plant at future moments corresponding to the prediction input parameters into a pre-trained physical-neural network joint model to obtain the final predicted photovoltaic power.
[0044] The training method for the pre-trained physical-neural network joint model is as follows:
[0045] The historical photovoltaic power plant data corresponding to the predicted input parameters are input into the neural network model to obtain the predicted photovoltaic power by the neural network.
[0046] Based on the physical data of the photovoltaic power station at future moments, the physical prediction of photovoltaic power is obtained;
[0047] The weights of the neural network-predicted photovoltaic power and the physical-predicted photovoltaic power are adjusted to obtain the final predicted photovoltaic power.
[0048] The joint loss function is determined based on the final predicted photovoltaic power and the actual photovoltaic power.
[0049] Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model.
[0050] Compared with the prior art, the present invention has the following beneficial effects:
[0051] This invention discloses a photovoltaic power prediction method that considers physical mechanism correction. By combining historical photovoltaic power plant data with physical data from future times and selecting highly correlated parameters as prediction inputs, this method can more comprehensively capture the key factors affecting photovoltaic power. Simultaneously, by utilizing a pre-trained physical-neural network joint model, physical prediction and neural network prediction are combined, and through weight correction, the bias that may be introduced by a single prediction method is effectively reduced, thus significantly improving prediction accuracy. The physical-neural network joint model in this method not only considers historical data of photovoltaic power plants but also incorporates physical data from future times. This makes the model more adaptable and robust to changes in environmental factors such as different weather conditions, light intensity, and temperature. Even under extreme weather conditions, it can maintain high prediction accuracy, providing strong support for the operation and maintenance management of photovoltaic power plants. The use of a GA genetic algorithm to optimize model parameters not only simplifies the model training process but also improves the model's intelligence level. By automatically adjusting the weights of the neural network-predicted photovoltaic power and the physical prediction of photovoltaic power, as well as the hyperparameters of the neural network model, the model can quickly adapt to new data, achieving continuous optimization of prediction results.
[0052] Furthermore, the introduction of weight coefficients for physical prediction and neural network prediction enables the prediction model to flexibly adjust the contribution of the two prediction methods based on the statistical characteristics of historical data and changes in environmental conditions, thereby enhancing the model's adaptability and generalization ability.
[0053] Furthermore, by introducing irradiance condition constraints and system maximum power constraints, the physical limitations of photovoltaic systems in actual operation are taken into account, making the prediction results more consistent with the actual situation. The prediction results are also corrected according to the actual environmental conditions and the physical characteristics of the photovoltaic system, thereby significantly improving the accuracy of the prediction and helping to reduce energy waste and grid dispatch problems caused by prediction deviations.
[0054] This invention discloses a photovoltaic power prediction system that considers physical mechanism correction. By combining the advantages of physical mechanisms and neural network models, it can more accurately capture the variation law of photovoltaic power plant output power, significantly improving the accuracy and reliability of prediction. During the training of the physical-neural network joint model, a GA genetic algorithm is used to automatically adjust the weights of the neural network prediction of photovoltaic power and the physical prediction of photovoltaic power, as well as the hyperparameters of the neural network model, so that the model can adapt to different environmental conditions and changes in the characteristics of photovoltaic power plants. This enhances the model's adaptability and generalization ability, and improves the robustness of prediction. Attached Figure Description
[0055] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0056] Figure 1 This is a structural block diagram of the physics-neural network joint model provided in an embodiment of the present invention;
[0057] Figure 2 A schematic diagram of the training process of the physical-neural network joint model provided in an embodiment of the present invention;
[0058] Figure 3 A flowchart of a photovoltaic power prediction method considering physical mechanism correction provided in an embodiment of the present invention;
[0059] Figure 4 Here is a block diagram of the photovoltaic power prediction method that takes into account physical mechanism correction in this invention;
[0060] Figure 5 Block diagram of a photovoltaic power prediction system that takes into account physical mechanism correction.
[0061] The module consists of: 1-Data preprocessing module; 2-Physical parameter input module; 3-Neural network model; 4-Physical model; 5-Correction module; and 6-Optimization and update module. Detailed Implementation
[0062] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. The components of the embodiments of the present invention described and marked in the accompanying drawings can generally be arranged and designed in various different configurations.
[0063] Therefore, the following detailed description of the embodiments of the invention provided in the accompanying drawings is not intended to limit the scope of the claimed invention, but merely to illustrate selected embodiments of the invention. All other embodiments obtained by those skilled in the art based on the embodiments of the invention without inventive effort are within the scope of protection of the invention.
[0064] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0065] In the description of the embodiments of the present invention, it should be noted that if terms such as "upper," "lower," "horizontal," or "inner" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product of the invention is in use, they are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation of the present invention. Furthermore, terms such as "first" and "second" are only used to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0066] Furthermore, the use of the term "horizontal" does not imply that the component must be absolutely horizontal, but rather that it can be slightly tilted. For example, "horizontal" simply means that its direction is more horizontal than "vertical," and does not mean that the structure must be completely horizontal, but can be slightly tilted.
[0067] In the description of the embodiments of the present invention, it should also be noted that, unless otherwise explicitly specified and limited, the terms "set," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in the present invention according to the specific circumstances.
[0068] The present invention will now be described in further detail with reference to the accompanying drawings:
[0069] See Figure 1 This invention provides a photovoltaic power prediction method that considers physical mechanism correction, offering a physical-neural network joint model, specifically including:
[0070] Data preprocessing module 1, physical parameter input module 2, neural network model 3, physical model 4, correction module 5, and optimization and update module 6;
[0071] The data preprocessing module 1 is connected to the neural network module 3, and sends the processed data into the neural network module 3 for training or prediction.
[0072] The physical model 4 accepts the actual physical parameters of the module 2 as input, calculates the physical photovoltaic power as output, and then sends it together with the output of the neural network module 3 into the correction module 5 to output the final predicted photovoltaic power, thereby calculating the joint loss function.
[0073] The irradiance threshold correction and power limitation are also located in the correction module 5, which is used to perform physical corrections on the physical-neural network joint model during the actual prediction phase.
[0074] The negative value of the joint loss function is fed into the optimization and update module 6 as a fitness function. The GA genetic algorithm is used to dynamically optimize the hyperparameters of the neural network model 3 and the weight coefficients of the correction module 5 to find the optimal parameter combination.
[0075] See Figure 2 and Figure 4 This invention provides a photovoltaic power prediction method that considers physical mechanism correction, the specific steps of which are as follows:
[0076] S1, acquire historical photovoltaic power station data, divided into training set and test set, acquire physical data of photovoltaic power station at future time (i.e. the time corresponding to the test set);
[0077] Specifically, historical photovoltaic power plant data includes historical photovoltaic power generation, outdoor temperature, outdoor humidity, direct solar irradiance, wind speed, photovoltaic panel temperature, and atmospheric pressure.
[0078] The physical data for a photovoltaic power station at a future time include direct irradiance, solar altitude angle, azimuth angle, panel tilt angle and orientation, total irradiance on the horizontal plane, ground reflectivity, scattering coefficient, and reflection coefficient. Direct irradiance and total irradiance on the horizontal plane can be obtained from weather forecast data, while solar altitude angle and azimuth angle can be calculated using the latitude and longitude of the photovoltaic power station and the future time. The remaining data can be obtained through measurement.
[0079] All historical photovoltaic power plant data are time series.
[0080] S2. Based on historical photovoltaic power plant data, select parameters with high correlation to historical photovoltaic power as prediction input parameters; generally, parameters with a correlation greater than 0.5 and less than or equal to 1 are selected as input.
[0081] This embodiment uses the Pearson correlation coefficient (PCC) to calculate the linear correlation between historical photovoltaic power plant data. The closer to +1, the stronger the positive linear correlation; the closer to -1, the stronger the negative linear correlation; and the closer to 0, the weaker the linear correlation. The PCC is defined as follows:
[0082]
[0083] in, X i The first historical photovoltaic power plant data i The value of the position; Y i It is the [number]th ... i The value of the position, and These represent historical photovoltaic power plant data and the average historical photovoltaic power output, respectively. n It is the sequence length of historical photovoltaic power plant data;
[0084] The predicted input parameters are standardized. Specifically, the standardization process can be mathematically represented as follows:
[0085]
[0086] This indicates the mean of the predicted input parameters. This represents the standard deviation of the predicted input parameters. Standardization eliminates the influence of feature scale, allowing the model to treat each feature more fairly and accelerating model convergence.
[0087] In practice, timestamp data can be extracted into months, hours, etc. as new input variables as needed, and the influence of trends and seasonality on model learning can be eliminated by data difference, so that the neural network module can combine time series information with photovoltaic output.
[0088] This embodiment performs time series interpolation on the missing input data, specifically by using data from the same time points several days before and after the missing data.
[0089] S3, input the historical photovoltaic power plant data corresponding to the predicted input parameters into the neural network model to obtain the predicted photovoltaic power by the neural network;
[0090] This embodiment uses an LSTM model; the training set of historical photovoltaic power plant data corresponding to the predicted input parameters is fed into the LSTM network for training. The input layer size is consistent with the sum of the number of input variables and the target variable. In this embodiment, the target variable is photovoltaic power prediction, so the output layer size is 1. The selection of the hidden layer size should meet the actual needs, so as to fully learn the data and avoid overfitting.
[0091] This embodiment incorporates an early stopping strategy into the LSTM model training and sets an iteration count threshold.
[0092] Determine whether the cumulative number of iterations in which the joint loss function of the correction module 5 no longer decreases exceeds the iteration threshold:
[0093] If not, it means that the performance of the LSTM model is still improving and training should continue.
[0094] If so, it means that the LSTM model has converged, so stop training to prevent the LSTM model from overfitting.
[0095] Specifically, when outputting the LSTM model, the mean and standard deviation input by the data preprocessing module 1 should be used for inverse standardization to ensure that the output conforms to the actual physical scale of the neural network predicting photovoltaic power.
[0096] S4, based on the physical data of the photovoltaic power station at future moments, obtains the physical prediction of photovoltaic power;
[0097] The photovoltaic power output is calculated using physical model 4 based on the physical data of the photovoltaic power station at future moments. The specific calculation formula is as follows:
[0098]
[0099] in Indicates effective irradiance. Indicates the area of the photovoltaic panel. Indicates temperature-dependent conversion efficiency. This represents the photovoltaic power generation calculated using a physical model;
[0100] Specifically, effective irradiance The calculation typically consists of three components:
[0101]
[0102] in Direct irradiance is the amount of radiation directly from the sun, which can be obtained through meteorological data or solar radiation meters. This represents the angle of incidence, which is the angle between the sunlight and the normal to the panel. The formula for calculating this angle is as follows:
[0103]
[0104] in Indicates the solar altitude angle. Indicates the tilt angle of the photovoltaic panel. Indicates the azimuth of the sun. This indicates the azimuth angle of the photovoltaic panel, typically 0° for south.
[0105] The Scattered irradiance, representing indirect radiation from the sky, can be obtained by subtracting the direct irradiance component from the total horizontal irradiance of the entire sky.
[0106]
[0107] in The horizontal irradiance of the entire sky can be obtained from meteorological information. As described above;
[0108] The Ground reflected irradiance can be represented by ground albedo. To estimate, we usually take 0.2, and the calculation formula is as follows:
[0109]
[0110] The and These represent the scattering coefficient and the reflection coefficient, respectively. They are proportionality coefficients related to the angle of the photovoltaic panel and environmental conditions, and are determined specifically according to the experimental environment and conditions.
[0111] Specifically, the temperature-dependent conversion efficiency It can be calculated using the following formula:
[0112]
[0113] in This indicates the efficiency of a photovoltaic module at a reference temperature, and is often referred to as the rated conversion efficiency. This indicates a reference temperature, typically 25°C. The temperature of a photovoltaic panel can be obtained using a temperature sensor. The temperature loss coefficient represents the effect of temperature increase on conversion efficiency, and is typically taken as 0.0045 to 0.005 / ℃.
[0114] S5, perform weight correction on the photovoltaic power predicted by the neural network and the photovoltaic power predicted by the physical method to obtain the final predicted photovoltaic power;
[0115] In this embodiment of the invention, the correction module 5 receives the predicted value from the neural network model 3 and the physical calculation value from the physical model 4, respectively, and performs physical correction to obtain a joint output value. The correction formula is as follows:
[0116]
[0117] in, This represents the photovoltaic power generation calculated using the physical model 4. This represents the photovoltaic power generation predicted by the LSTM model. This represents the neural network prediction output that takes physical corrections into account. This represents the weight parameter, and its value range is... When the LSTM model's prediction results do not conform to physical laws, the weight parameters can be increased. To ensure the physical consistency of the prediction results;
[0118] S6, determine the joint loss function based on the final predicted photovoltaic power and the actual photovoltaic power;
[0119] Specifically, the loss function is defined as the average of the squared prediction errors of the LSTM model, i.e., (MSE):
[0120]
[0121] in N This indicates the sample size of the predicted output. This represents the neural network prediction output that takes physical corrections into account. P actual This represents the actual photovoltaic power generation value. The weight parameters of the LSTM model are updated by calculating the gradient of the loss function.
[0122] S7. Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model.
[0123] This invention uses a GA genetic algorithm to optimize and update the parameters of the neural network module 3 and the correction module 5, and selects the optimal parameter combination for prediction. The specific process is as follows:
[0124] S701, initialize a certain number of parameter vectors, including the hyperparameters of the LSTM model and the weight coefficients of each part of the joint output, as the initial population and pass them into module 3 and module 5;
[0125] S702, Select the negative value of the joint loss function as the fitness function, treat each set of parameters as an individual, calculate the fitness of each individual and judge its quality.
[0126] S703, using the roulette wheel selection method to select individuals with higher fitness from the individuals, the roulette wheel selection method being mathematically represented as follows:
[0127]
[0128] in Represents the total number of individuals. The formula above normalizes individual fitness, representing the fitness of each individual based on its probability. The higher the probability, the more likely the individual will be selected for reproduction; in this embodiment, individuals with a probability of more than 50% are considered to have higher fitness.
[0129] S704, Crossover operation simulates biological gene crossover. In this embodiment, uniform crossover operation is used, that is, for two individuals, the parameters at the same position of each pair are exchanged with a certain probability to generate new individuals.
[0130] S705, the mutation operation randomly alters individual parameters to simulate natural gene mutations, thereby increasing population diversity and preventing the algorithm from getting trapped in local optima. The random noise added in this embodiment follows a normal distribution.
[0131] S706: After completing the crossover and mutation operations, the newly generated individuals are added to the population to form the next generation population, while retaining the individual with the highest fitness from the previous generation to ensure that the optimal solution is not lost during the evolution process.
[0132] S708, iterate through steps S702-S705 until the population fitness no longer increases significantly.
[0133] It should be noted that the number of iterations of the optimization update module 6 and the number of iterations of the neural network model 3 are not the same. Since the weight parameter matrix of the LSTM model can be updated frequently through gradient descent, it takes less time; while the genetic algorithm updates more slowly, and the parameters changing too frequently will also lead to a decrease in model performance. Therefore, the iteration frequency of the neural network model 3 and the optimization update module 6 can be kept in proportion.
[0134] S8, in actual prediction, inputs historical photovoltaic power plant data and physical data of the photovoltaic power plant at future moments into a pre-trained physical-neural network joint model to obtain the final photovoltaic predicted power.
[0135] In this embodiment, the weight parameters of the LSTM model are updated based on the gradient value of the joint loss function. Simultaneously, the negative value of the joint loss function serves as the fitness function of the GA genetic algorithm, iteratively generating parameter combinations with higher fitness through selection, crossover, and mutation. Whenever the number of training epochs of the LSTM model reaches a certain value, the optimization update module is used to update the LSTM hyperparameters and the weight parameters of the physical correction module.
[0136] Once the neural network photovoltaic power prediction model considering physical mechanism corrections is trained, it can be used for actual prediction. The prediction process does not include the parameter update step found in the training process, but new physical corrections are added before the final output, namely irradiance threshold correction and power limitation. This aims to ensure that the model can provide more stable and physically reasonable prediction results under different weather and irradiance conditions, thereby optimizing the operating efficiency and security of the power system.
[0137] See Figure 3 In one embodiment of the present invention, when the LSTM model is trained and put into practical application for prediction, the correction module 5 also adds irradiance threshold correction:
[0138] Set the minimum effective irradiance threshold for activation. When the physical parameter input module 2 inputs Less than the start-up threshold At that time, the output power of the photovoltaic system is set to zero, that is:
[0139]
[0140] Irradiance threshold correction can avoid situations where nighttime power generation is not zero or is negative in actual predictions, making the model predictions more consistent with physics and significantly improving their interpretability.
[0141] Specifically, the correction module 5 also incorporates a power limit, designed to adjust the power limit based on the maximum installed capacity of the photovoltaic system. P max The power of the combined output is limited to prevent over-prediction caused by excessively large individual data points, ensuring that the power output is within the actual range; ensuring that the final predicted photovoltaic power does not exceed the maximum installed capacity of the photovoltaic system; when the final predicted photovoltaic power exceeds the maximum installed capacity of the photovoltaic system, the output power is set to the installed capacity.
[0142] In order to ensure the accurate operation of the photovoltaic power prediction method that takes into account the physical mechanism correction of the present invention, the parameters of the physical model 4 can be flexibly adjusted according to the photovoltaic power generation system of different scales and configurations, different geographical locations and environments, and the input variables and physical parameters (such as direct irradiance, solar altitude angle, panel tilt angle, etc.) to ensure the accuracy of the physical correction itself.
[0143] See Figure 5 This invention provides a photovoltaic power prediction system that considers physical mechanism correction, comprising:
[0144] The data acquisition module acquires historical photovoltaic power plant data and physical data of the photovoltaic power plant at future moments;
[0145] The input parameter confirmation module selects parameters that are highly correlated with historical photovoltaic power as prediction input parameters based on historical photovoltaic power plant data.
[0146] The photovoltaic power prediction module inputs the historical photovoltaic power plant data and the physical data of the photovoltaic power plant at future moments corresponding to the prediction input parameters into a pre-trained physical-neural network joint model to obtain the final predicted photovoltaic power.
[0147] The training method for the pre-trained physical-neural network joint model is as follows:
[0148] The historical photovoltaic power plant data corresponding to the predicted input parameters are input into the neural network model to obtain the predicted photovoltaic power by the neural network.
[0149] Based on the physical data of the photovoltaic power station at future moments, the physical prediction of photovoltaic power is obtained;
[0150] The weights of the neural network-predicted photovoltaic power and the physical-predicted photovoltaic power are adjusted to obtain the final predicted photovoltaic power.
[0151] The joint loss function is determined based on the final predicted photovoltaic power and the actual photovoltaic power.
[0152] Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model.
[0153] The above are merely preferred embodiments of the present invention and are not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A photovoltaic power prediction method considering physical mechanism correction, characterized in that, Includes the following steps: Acquire historical photovoltaic power plant data and physical data of photovoltaic power plants at future moments; Based on historical photovoltaic power plant data, parameters with high correlation to photovoltaic power are selected as prediction input parameters; The historical photovoltaic power plant data corresponding to the predicted input parameters and the physical data of the photovoltaic power plant at future moments are input into a pre-trained physical-neural network joint model to obtain the final predicted photovoltaic power. The training method for the pre-trained physical-neural network joint model is as follows: The historical photovoltaic power plant data corresponding to the predicted input parameters are input into the neural network model to obtain the predicted photovoltaic power by the neural network. Based on the physical data of the photovoltaic power station at future moments, the physical prediction of photovoltaic power is obtained; The photovoltaic power predicted by the neural network and the photovoltaic power predicted by physical methods are weighted and corrected to obtain the final predicted photovoltaic power; the final predicted photovoltaic power is described as follows: in, Indicates the physical prediction of photovoltaic power; This indicates that the neural network predicts photovoltaic power. This represents the weighting coefficient, with a value range of [0, 1]. The joint loss function is determined based on the final predicted photovoltaic power and the actual photovoltaic power; the joint loss function is described as follows: in, N This indicates the sequence length of the final predicted photovoltaic power. The sequence representing the final predicted photovoltaic power is numbered. i The value of the position, The sequence representing the actual photovoltaic power generation is numbered. i The value of the position; Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model. Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical prediction of photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model, specifically: The negative value of the joint loss function is selected as the fitness function; multiple individuals are randomly generated as the initial population; each individual represents a set of parameter vectors; the parameter vectors include the hyperparameters of the neural network model and the weight coefficients of the neural network-predicted photovoltaic power and the physical-predicted photovoltaic power; Iterate through the following steps until the population fitness no longer increases significantly, then select the individual with the highest fitness in the population as the optimal parameter vector combination: Based on the fitness function, the roulette wheel selection method is used to select individuals with higher fitness in the population, resulting in a population with high fitness. Based on a population with high fitness, two individuals are randomly selected and cross-crossed using a uniform cross-cross method to generate new individuals; New individuals are randomly mutated and added to the new population, while the individuals with the highest fitness in the high-fitness population are retained. After obtaining the final predicted photovoltaic power, the following steps are also included: If the current irradiance is less than the preset irradiance threshold, the final predicted photovoltaic power will be 0. When the final predicted photovoltaic power is greater than or equal to the maximum power of the actual photovoltaic system, then the final predicted photovoltaic power is the maximum power of the actual photovoltaic system.
2. The photovoltaic power prediction method considering physical mechanism correction according to claim 1, characterized in that, The physical data include direct irradiance, solar altitude angle, azimuth angle, panel tilt angle and orientation, total irradiance on the horizontal plane, ground reflectivity, scattering coefficient and reflection coefficient.
3. The photovoltaic power prediction method considering physical mechanism correction according to claim 1, characterized in that, The method of selecting parameters with high correlation to historical photovoltaic power output as prediction input parameters based on historical photovoltaic power plant data is as follows: The correlation between historical photovoltaic power plant data and historical photovoltaic data is calculated using the Pearson correlation coefficient, and parameters with high correlation are selected as prediction input parameters.
4. The photovoltaic power prediction method considering physical mechanism correction according to claim 1, characterized in that, The physical prediction of photovoltaic power is described as follows: in, Indicates effective irradiance. Indicates the area of the photovoltaic panel. This indicates the temperature-dependent conversion efficiency.
5. The photovoltaic power prediction method considering physical mechanism correction according to claim 1, characterized in that, The neural network model is an LSTM model.
6. A photovoltaic power prediction system considering physical mechanism correction, based on the photovoltaic power prediction method considering physical mechanism correction as described in claim 1, characterized in that, include: The data acquisition module acquires historical photovoltaic power plant data and physical data of the photovoltaic power plant at future moments; The input parameter confirmation module selects parameters that are highly correlated with historical photovoltaic power as prediction input parameters based on historical photovoltaic power plant data. The photovoltaic power prediction module inputs the historical photovoltaic power plant data and the physical data of the photovoltaic power plant at future moments corresponding to the prediction input parameters into a pre-trained physical-neural network joint model to obtain the final predicted photovoltaic power. The training method for the pre-trained physical-neural network joint model is as follows: The historical photovoltaic power plant data corresponding to the predicted input parameters are input into the neural network model to obtain the predicted photovoltaic power by the neural network. Based on the physical data of the photovoltaic power station at future moments, the physical prediction of photovoltaic power is obtained; The weights of the neural network-predicted photovoltaic power and the physical-predicted photovoltaic power are adjusted to obtain the final predicted photovoltaic power. The joint loss function is determined based on the final predicted photovoltaic power and the actual photovoltaic power. Based on the joint loss function, the GA genetic algorithm is used to update the weights of the neural network predicting photovoltaic power and the physical predicting photovoltaic power, as well as the hyperparameters of the neural network model, to obtain a pre-trained physical-neural network joint model.