Photovoltaic power prediction method and device, computer equipment and storage medium

By decomposing and weighted smoothing the historical data of the photovoltaic site, the deviation problem of traditional photovoltaic power prediction models under unstable meteorological conditions is solved, and more accurate power prediction is achieved, which is suitable for grid scheduling and energy optimization of photovoltaic power generation systems.

CN120277368AActive Publication Date: 2025-07-08BEIJING EAST ENVIRONMENT ENERGY TECH

Patent Information

Application Number
CN202510757902.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-09
Publication Date
2025-07-08
Estimated Expiration
2045-06-09

AI Technical Summary

Technical Problem

Traditional photovoltaic power prediction models are difficult to fit the actual photovoltaic power output curve under unstable meteorological conditions, resulting in large deviations in the prediction results, affecting the power grid scheduling and the optimal allocation of energy resources.

Method used

By obtaining the historical power and meteorological data of the photovoltaic site, decomposition is carried out to obtain long-term trend characteristics and short-term fluctuation characteristics under multiple preset time scales. The pre-trained photovoltaic power prediction model is used to learn the mapping relationship of these features and perform weighted smoothing processing to improve prediction accuracy.

Benefits of technology

In scenarios with severe load-limiting and meteorological changes, the accuracy and reliability of photovoltaic power prediction are improved, and the power performance in future periods can be better characterized, and the violent fluctuations on short time scales can be reduced, and a smoother and more consistent prediction curve can be provided.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120277368A_ABST
    Figure CN120277368A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of clean energy, and discloses a photovoltaic power prediction method and device, computer equipment and a storage medium. The photovoltaic power prediction method comprises the following steps: acquiring first historical power data and first historical meteorological data of a target photovoltaic station; decomposing the first historical power data based on the fluctuation characteristics of the first historical power data to obtain first long-term trend characteristics and corresponding first short-term fluctuation characteristics of the first historical power data under a plurality of preset time scales; inputting the first long-term trend feature, the first short-term fluctuation feature and the first historical meteorological data under each preset time scale into a pre-trained photovoltaic power prediction model to obtain a power prediction result; performing weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result; according to the method, power prediction can be carried out by considering the fluctuation state of the first historical power data in the historical time period, and the obtained power prediction result can represent the specific performance of the power in the future time period.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of clean energy, and particularly to a photovoltaic power prediction method, device, computer device, and storage medium. Background Art

[0002] Currently, photovoltaic power generation faces challenges in power prediction under unstable meteorological conditions.

[0003] Due to the frequent drastic fluctuations in meteorological factors such as radiation intensity, ambient temperature, and air humidity, traditional prediction models are difficult to fit the actual photovoltaic power output curve, resulting in large deviations in prediction results. This error directly affects the efficiency of power grid dispatching and optimal allocation of energy resources. For example, when encountering sudden changes in sunny and cloudy conditions or sudden changes in temperature and humidity, traditional models may not be able to promptly reflect the changes in the actual output of photovoltaic panels, and the prediction often fails to keep up with the rise and fall of the actual power, thus reducing the reliability of the prediction.

[0004] Therefore, there is an urgent need to propose a photovoltaic power prediction method to solve the problem that traditional prediction models are difficult to fit the actual photovoltaic power output curve, resulting in large deviations in prediction results. Summary of the Invention

[0005] In view of this, the present invention provides a photovoltaic power prediction method, device, computer device, and storage medium to solve the problem that traditional prediction models are difficult to fit the actual photovoltaic power output curve, resulting in large deviations in prediction results.

[0006] In a first aspect, the present invention provides a photovoltaic power prediction method, and the photovoltaic power prediction method includes: obtaining first historical power data and first historical meteorological data of a target photovoltaic power station; decomposing the first historical power data based on the fluctuation characteristics of the first historical power data to obtain a first long-term trend characteristic and a corresponding first short-term fluctuation characteristic of the first historical power data at multiple preset time scales; inputting the first long-term trend characteristic, the first short-term fluctuation characteristic, and the first historical meteorological data at each of the preset time scales into a pre-trained photovoltaic power prediction model to obtain a power prediction result; wherein, the photovoltaic power prediction model is trained based on second historical power data in a first time period, third historical power data in a second time period, and second historical meteorological data; during the model training process, taking the third historical power data as a target value, learning, based on the photovoltaic power prediction model, the mapping relationship between the second long-term trend characteristic, the second short-term fluctuation characteristic, the second historical meteorological data and the third historical power data of the second historical power data at each of the preset time scales, and learning the fusion relationship when fusing sub-power prediction results corresponding to each of the preset time scales to obtain a power prediction result; and performing weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result.

[0007] As an exemplary embodiment, the method for training the photovoltaic power prediction model includes: obtaining second historical power data in a first time period, third historical power data in a second time period, and second historical meteorological data corresponding to the time sequence of the second historical power data of a target photovoltaic power station; wherein, the first time period and the second time period are adjacent in time sequence, and the first time period is earlier than the second time period; decomposing the second historical power data to obtain a second long-term trend characteristic and a corresponding second short-term fluctuation characteristic of the second historical power data at multiple preset time scales; inputting the second historical power data and the second historical meteorological data into a pre-constructed photovoltaic power prediction model for model training; during the model training process, taking the third historical power data as a target value, learning, based on the photovoltaic power prediction model, the mapping relationship between the second long-term trend characteristic, the second short-term fluctuation characteristic, and the second historical meteorological data and the third historical power data of the second historical power data at each of the preset time scales, and learning the fusion relationship when fusing sub-power prediction results corresponding to each of the preset time scales to obtain a power prediction result.

[0008] As an exemplary embodiment, the photovoltaic power prediction model includes multiple sub-prediction networks corresponding to the preset time scales and a weighted fusion module. The step of inputting the second historical power data and the second historical meteorological data into the pre-constructed photovoltaic power prediction model for model training includes: inputting the second long-term trend features, the second short-term fluctuation features, and the second historical meteorological data at each of the preset time scales into the sub-prediction networks corresponding to each of the preset time scales for training; during the training process, using the third historical power data as the target value, continuously adjusting the network parameters of each sub-prediction network so that each sub-prediction network learns the corresponding relationship between the second long-term trend features, the second short-term fluctuation features, the second historical meteorological data, and the third historical power data at the corresponding preset time scale until each sub-prediction network converges; based on the weighted fusion module, learning the fusion relationship when fusing the sub-power prediction results corresponding to each of the preset time scales to obtain the power prediction result.

[0009] As an exemplary embodiment, after decomposing the first historical power data based on the fluctuation features of the first historical power data to obtain the first long-term trend features and the corresponding first short-term fluctuation features of the first historical power data at multiple preset time scales, the photovoltaic power prediction method further includes: inputting the first long-term trend features and the first short-term fluctuation features into a pre-constructed feature correction model, and using the feature correction model to correct the first long-term trend features and / or the first short-term fluctuation features based on the mapping relationship between the second long-term trend features and the second short-term fluctuation features; wherein, the feature correction model is trained based on the second long-term trend features and the second short-term fluctuation features, and the feature correction model is composed of a first fully connected layer, a second fully connected layer, and a ReLU activation function; the first fully connected layer is used to input the second long-term trend features, the second fully connected layer is used to input the second short-term trend features, and the first fully connected layer and the second fully connected layer are activated by the ReLU activation function; during the model training process, continuously adjusting the model parameters of the feature correction model so that the feature correction model learns the mapping relationship between the second long-term trend features and the second short-term fluctuation features.

[0010] As an exemplary embodiment, before decomposing the first historical power data based on the fluctuation features of the historical power data, the photovoltaic power prediction method further includes: obtaining historical measured irradiance data that is temporally matched with the first historical power data; calculating the correlation coefficient between the historical measured irradiance data and the first historical power data that is temporally matched; and removing the first historical power data with a correlation coefficient less than the preset correlation coefficient.

[0011] As an exemplary embodiment, the weighted smoothing of the power prediction result to obtain the photovoltaic power prediction result includes: traversing each power prediction value in the power prediction result, and taking the first preset number of target power prediction values before and after the power prediction value as the prediction power data sequence; determining the smoothing weight of each target power prediction value based on the sequence distance between each target power prediction value in each prediction power data sequence and the power prediction value; wherein, each smoothing weight is inversely correlated with the sequence distance; correcting each power prediction value based on each smoothing weight and each target power prediction value to obtain the photovoltaic power prediction result.

[0012] As an exemplary embodiment, the photovoltaic power prediction method further includes: calculating the power change rate of each power prediction value relative to N adjacent power prediction values with earlier and / or later time sequences in the power prediction result; wherein, N is a positive integer; obtaining the power change rate corresponding to each power prediction value; determining the first preset number based on the power change rate; wherein, the first preset number is inversely correlated with the change rate.

[0013] In a second aspect, the present invention provides a photovoltaic power prediction device, which includes: an acquisition module for acquiring the first historical power data and the first historical meteorological data of a target photovoltaic power station; a decomposition module for decomposing the first historical power data based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend characteristics and the corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales; a power prediction module for inputting the first long-term trend characteristics, the first short-term fluctuation characteristics and the first historical meteorological data at each preset time scale into a pre-trained photovoltaic power prediction model to obtain a power prediction result; wherein, the photovoltaic power prediction model is trained based on the second historical power data in the first time period, the third historical power data in the second time period and the second historical meteorological data; in the process of model training, taking the third historical power data as the target value, learning the mapping relationship between the second long-term trend characteristics, the second short-term fluctuation characteristics, the second historical meteorological data and the third historical power data of the second historical power data at each preset time scale based on the photovoltaic power prediction model, and learning the fusion relationship when fusing the sub-power prediction results corresponding to each preset time scale to obtain the power prediction result; a smoothing module for performing weighted smoothing on the power prediction result to obtain the photovoltaic power prediction result.

[0014] In a third aspect, the present invention provides a computer device, comprising: a memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to perform the method according to the first aspect or any corresponding embodiment thereof.

[0015] In a fourth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, and the computer instructions are used to cause a computer to perform the method according to the first aspect or any corresponding embodiment thereof.

[0016] The power prediction method of the present invention obtains the first historical power data and the first historical meteorological data of a target photovoltaic power station; decomposes the first historical power data based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend characteristics and the corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales; inputs the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each preset time scale into a pre-trained photovoltaic power prediction model to obtain a power prediction result; wherein, the photovoltaic power prediction model is trained based on the second historical power data in the first period, the third historical power data in the second period, and the second historical meteorological data; during the model training process, with the third historical power data as the target value, the photovoltaic power prediction model learns the second long-term trend characteristics, the second short-term fluctuation characteristics, the mapping relationship between the second historical meteorological data and the third historical power data at each preset time scale, and the fusion relationship when learning to fuse the sub-power prediction results corresponding to each preset time scale to obtain the power prediction result; performs weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result; for the above implementation manner of inputting the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each preset time scale into the pre-trained photovoltaic power prediction model to obtain the power prediction result, the photovoltaic power prediction model is trained through the mapping relationship between the second long-term trend characteristics, the second short-term fluctuation characteristics, the second historical meteorological data, and the third historical power data at each preset time scale. During model training, it can consider the specific fluctuation states of each preset time scale in the scenario where load limitation and drastic meteorological changes coexist in the historical period of power data, and the power performance of the third historical power data in the future period relative to the time period corresponding to the fluctuation state; on the other hand, each preset time scale is independent of each other, and each preset time scale has its own mapping relationship, which can avoid interference between different preset time scales and improve the accuracy of power prediction at each preset time scale; further, by using the method of inputting the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each preset time scale into the photovoltaic power prediction model, it is possible to consider the fluctuation state of the first historical power data in the historical period for power prediction, and the obtained power prediction result can represent the specific performance of the power in the future period. Description of the Drawings

[0017] To more clearly illustrate the specific embodiments of the present invention or the technical solutions in the prior art, the following will briefly introduce the drawings required for the description of the specific embodiments or the prior art. Obviously, the drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other drawings can also be obtained based on these drawings.

[0018] Figure 1 is a schematic flowchart of a photovoltaic power prediction method according to an embodiment of the present invention; Figure 2 is a structural block diagram of a photovoltaic power prediction device according to an embodiment of the present invention; Figure 3 is a schematic hardware structure diagram of a computer device according to an embodiment of the present invention. Specific Embodiments

[0019] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the protection scope of the present invention.

[0020] Currently, photovoltaic power generation faces challenges in power prediction under unstable meteorological conditions.

[0021] Due to the frequent drastic fluctuations in meteorological factors such as radiation intensity, ambient temperature, and air humidity, it is difficult for the photovoltaic power prediction models in the related technologies to fit the actual photovoltaic power output curve, resulting in relatively large prediction errors. Such errors directly affect the efficiency of power grid dispatching and the optimal allocation of energy resources.

[0022] For example, when encountering sudden changes in sunlight or sudden changes in temperature and humidity, traditional models may not be able to promptly reflect the changes in the actual output of photovoltaic panels, and the prediction often fails to keep up with the rise and fall of the actual power, thereby reducing the reliability of the prediction.

[0023] On the other hand, in recent years, with the rapid increase in photovoltaic installed capacity, power grid load shedding (i.e., restricting photovoltaic output) often occurs on sunny days in various regions, especially more frequently during the winter heating period. Although such measures of artificially restricting output protect the safety of the power grid, they also cause historical power data to not match the actual irradiance, bringing additional difficulties to prediction.

[0024] Due to the participation of new energy power generation in intraday trading in the electricity spot market, the accuracy requirements for ultra-short-term (within 15 minutes to 2 hours) forecasting are getting higher and higher. Power plants need to report the ultra-short-term power forecasting results in advance and use them to formulate bidding strategies for intraday trading to increase revenue.

[0025] In the scenario where the above-mentioned load limit and drastic meteorological changes coexist, the errors of traditional forecasting methods are further amplified. Chain biases such as inaccurate weather forecasts leading to inaccurate forecasts at all levels may occur in short-term forecasting and ultra-short-term forecasting, resulting in it being difficult for the forecasting models in related technologies to fit the actual photovoltaic power output curve, and there is a problem of relatively large forecasting result deviations.

[0026] According to an embodiment of the present invention, an embodiment of a photovoltaic power forecasting method is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in a different order than here.

[0027] In this embodiment, a photovoltaic power forecasting method is provided. Figure 1 It is a flowchart of the photovoltaic power forecasting method according to an embodiment of the present invention, as Figure 1 shown, the process includes the following steps: Step S101, obtain the first historical power data and the first historical meteorological data of the target photovoltaic power station.

[0028] Exemplarily, the first historical power data can be collected from the historical actual power output of the target photovoltaic power station.

[0029] Exemplarily, the first historical meteorological data can be obtained through historical weather forecasts and collection devices; among them, the first historical meteorological data includes global radiation, temperature, humidity, etc. given by historical weather forecasts, and also includes measured irradiance data collected by collection devices.

[0030] After obtaining the original data, steps such as data cleaning and preprocessing are performed on the first historical power data and the first historical meteorological data.

[0031] Step S102, decompose the first historical power data based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend characteristics and the corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales.

[0032] As described above, in the scenario where the above-mentioned load limit and drastic meteorological changes coexist, the historical power data fluctuates. In order to consider the fluctuations in the historical power data for power prediction, in this embodiment, the first historical power data is decomposed based on the fluctuation characteristics of the historical power data to obtain the first long-term trend characteristics and the corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales.

[0033] Among them, exemplarily, the decomposition of the first historical power data based on the fluctuation characteristics of the historical power data can be achieved by means of wavelet transform. Wavelet transform is a signal processing method that can decompose time series data at different frequencies and time resolutions, and can capture both local fluctuations and global trends at the same time. In this embodiment, discrete wavelet transform is performed on the first historical power data, and multi-level wavelet decomposition is performed on the power time series to obtain a set of wavelet coefficients [CA_1, CD_1,..., CD_n], ……, [CA_i, CD_1,..., CD_n]; where CA_i represents the approximation coefficient of the i-th layer of wavelet decomposition, and [CA_1, CD_1,..., CD_n] represents the detail coefficients under each layer of wavelet decomposition. The approximation coefficient is used to represent the first long-term trend of the historical power data, and the detail coefficient is used to represent the first short-term fluctuation under each layer of wavelet decomposition. Each set of wavelet coefficients represents the dynamic characteristics of the first historical power data at each preset time scale. Wavelet decomposition is a general extension compared to the time sampling method in the related art.

[0034] However, the wavelet decomposition (wavelet transform) method in the related art usually does not consider the time scale during decomposition, but only performs multiple rounds of decomposition on the power sequence data or meteorological sequence data to obtain the approximation coefficient of the i-th layer of wavelet decomposition and the detail coefficients under each layer of wavelet decomposition. Further, a related power prediction model is trained through the approximation coefficient obtained by the last round of decomposition and the fluctuation coefficients obtained by the last round and / or the previous rounds of decomposition. The fluctuation characteristics obtained by this method can reflect the fluctuation of the sequence data to a certain extent. However, the above process has high requirements for the quality of the original power sequence data and the decomposition process during wavelet decomposition.

[0035] On the one hand, the long-term trend features and short-term fluctuation trends obtained by decomposition have a relatively high correlation with the original power sequence data. The final decomposition result can only reflect the long-term trend features and short-term fluctuation trends of the original power sequence data at the corresponding fixed time scale, and cannot fully consider the power fluctuations of the photovoltaic power station at different time scales based on the randomness of power fluctuations. On the other hand, in the related technologies, the method of using wavelet decomposition for power prediction requires multiple rounds of wavelet decomposition to extract detailed features with higher time resolution for power prediction with a shorter time scale of the prediction target (for example, for ultra-short-term power prediction from 15 minutes to 4 hours). As the number of decomposition rounds (levels) increases step by step, the long-term trend features obtained after multiple rounds of wavelet decomposition more precisely represent the long-term stable trend of power, while the short-term fluctuations are more prominent in detailed features. However, too many rounds of wavelet decomposition may result in the short-term fluctuations obtained being affected by factors such as noise in the power sequence and power mutations under restricted power generation. The long-term trend features obtained are lost in the fluctuations at the fixed time scale corresponding to the original power sequence due to excessive decomposition rounds. And, in the related technologies, for the long-term trend features and short-term trends obtained by decomposition, a scheme of training respective prediction branches for the long-term trend features and short-term trends and then directly averaging the prediction results to obtain the final power prediction result is usually adopted. The deviation caused by building the model during the averaging process is inevitably averaged into the power prediction result. The above three factors lead to poor prediction accuracy when the finally trained power prediction model is used for prediction.

[0036] To solve the above problems, in the present invention, after obtaining the first historical power data, the first historical power data is decomposed based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend features and corresponding first short-term fluctuation features of the first historical power data at multiple preset time scales.

[0037] Among them, the preset time scales are hour, day and night, day, week, and season.

[0038] Exemplarily, after obtaining the first historical power data, the first historical power data can be first intercepted according to the preset time scales to respectively obtain the first sub-historical power data sequences with preset time scales of hour, day and night, day, week, and season. Further, each sub-historical power data sequence is decomposed to obtain the first long-term trend features and corresponding first short-term fluctuation features of the first historical power data at multiple preset time scales.

[0039] Exemplarily, before inputting the first long-term trend features and the first short-term fluctuation features at each of the preset time scales into the photovoltaic power prediction model, each group of wavelet scale features is input into an independent encoder network designed according to the preset time scale, and mapped into a unified feature space for subsequent processing; the encoded features at each preset time scale are input into the backbone structure of the model to participate in the subsequent prediction task.

[0040] Further, after obtaining the first long-term trend features and the first short-term fluctuation features at each of the preset time scales, the first long-term trend features, the first short-term fluctuation features, and the first historical meteorological data at each of the preset time scales are input into a pre-trained photovoltaic power prediction model to obtain a power prediction result.

[0041] Step S103, input the first long-term trend features, the first short-term fluctuation features, and the first historical meteorological data at each of the preset time scales into a pre-trained photovoltaic power prediction model to obtain a power prediction result; wherein, the photovoltaic power prediction model is trained based on the second historical power data in the first time period, the third historical power data in the second time period, and the second historical meteorological data; during the model training process, taking the third historical power data as the target value, based on the photovoltaic power prediction model, learning the second long-term trend features, the second short-term fluctuation features of the second historical power data at each of the preset time scales, the mapping relationship between the second historical meteorological data and the third historical power data, and the fusion relationship when learning to fuse the sub-power prediction results corresponding to each of the preset time scales to obtain the power prediction result.

[0042] In this embodiment, the photovoltaic power prediction model is trained based on the second historical power data in the first time period, the third historical power data in the second time period, and the second historical meteorological data; the first time period and the second time period are adjacent in time sequence, and the first time period is earlier than the second time period; during the model training process, taking the third historical power data as the target value, based on the photovoltaic power prediction model, learning the second long-term trend features, the second short-term fluctuation features of the second historical power data at each of the preset time scales, the mapping relationship between the second historical meteorological data and the third historical power data, and the fusion relationship when learning to fuse the sub-power prediction results corresponding to each of the preset time scales to obtain the power prediction result; that is, when the photovoltaic power model is trained, the short-term fluctuations and long-term trends of historical power data at different preset time scales are considered.

[0043] In the above implementation manner of inputting the first long-term trend feature, the first short-term fluctuation feature, and the first historical meteorological data at each of the preset time scales into a pre-trained photovoltaic power prediction model to obtain a power prediction result, the photovoltaic power prediction model is trained through the mapping relationship between the second long-term trend feature, the second short-term fluctuation feature, the second historical meteorological data, and the third historical power data at each of the preset time scales. During model training, it is possible to consider the specific fluctuation states of each preset time scale in the scenario where power data coexists with load curtailment and drastic meteorological changes during the historical period, as well as the power performance of the third historical power data in the future period relative to the time period corresponding to the fluctuation state. On the other hand, each preset time scale is independent, and there is a respective mapping relationship under each preset time scale, which can avoid interference between different preset time scales and improve the accuracy of power prediction under each preset time scale. Further, by using the method of inputting the first long-term trend feature, the first short-term fluctuation feature, and the first historical meteorological data at each of the preset time scales into the photovoltaic power prediction model, it is possible to consider the fluctuation state of the first historical power data during the historical period for power prediction, and the obtained power prediction result can represent the specific performance of the power in the future period.

[0044] Step S104: Perform weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result.

[0045] In order to further improve the practicality of the power prediction result output by the power prediction model, the present invention adds a post-processing step after obtaining the preliminary prediction value to smooth and correct the prediction curve.

[0046] Exemplarily, when performing weighted smoothing on the power prediction result, the method of using a triangular dynamic weighting window can be adopted to smooth the prediction result; specifically, when calculating the smoothed value at a certain moment, the prediction values within a certain range before and after it are considered, and a scheme is given in which the power value centered on the current moment has the highest weight and the weight gradually linearly decreases as the distance from the center increases.

[0047] The implementation manner of performing weighted smoothing on the power prediction result can effectively reduce the drastic fluctuations or spikes on the short-time scale while keeping the overall curve trend unchanged, making the prediction curve look smoother and more coherent.

[0048] The power prediction method of the present invention obtains the first historical power data and the first historical meteorological data of a target photovoltaic power station; decomposes the first historical power data based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend characteristics and the corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales; inputs the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each preset time scale into a pre-trained photovoltaic power prediction model to obtain a power prediction result; wherein, the photovoltaic power prediction model is trained based on the second historical power data in a first time period, the third historical power data in a second time period, and the second historical meteorological data; during the model training process, using the third historical power data as the target value, the photovoltaic power prediction model learns the second long-term trend characteristics, the second short-term fluctuation characteristics, the mapping relationship between the second historical meteorological data and the third historical power data at each preset time scale, and the fusion relationship when learning to fuse the sub-power prediction results corresponding to each preset time scale to obtain the power prediction result; performs weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result; in the above implementation manner of inputting the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each preset time scale into the pre-trained photovoltaic power prediction model to obtain the power prediction result, the photovoltaic power prediction model is trained through the mapping relationship between the second long-term trend characteristics, the second short-term fluctuation characteristics, the second historical meteorological data, and the third historical power data at each preset time scale. During model training, it can consider the specific fluctuation states of each preset time scale in the scenario where load limitation and drastic meteorological changes coexist in the historical period of power data, as well as the power performance of the third historical power data in the future period relative to the time period corresponding to the fluctuation state; on the other hand, each preset time scale is independent of each other, and each preset time scale has its own mapping relationship, which can avoid the interference of different preset time scales and improve the accuracy of power prediction at each preset time scale; further, by using the method of inputting the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each preset time scale into the photovoltaic power prediction model, it can consider the fluctuation state of the first historical power data in the historical period for power prediction, and the obtained power prediction result can represent the specific performance of the power in the future period.

[0049] Data cleaning in related technologies usually uses simple mean or linear interpolation to process outliers and missing values, but this rough method cannot accurately identify and process abnormal data, which may lead to a decline in the data quality of the model input.

[0050] To solve the above problems, as an exemplary embodiment, after obtaining the first historical power data and the first historical meteorological data of the target photovoltaic power station, the photovoltaic power prediction method further includes: calculating the power change amount of adjacent moments in the first historical power data; marking the historical power data with a negative power change amount and an absolute value of the power change amount greater than a first preset value, or the absolute value of the power change amount less than a second preset value and lasting for a preset duration as abnormal historical power data; the second preset value is approximately zero; screening the power data whose time sequence is prior to the abnormal historical power data to obtain a first target power value that first appears with a positive power change amount or an absolute value of the change amount less than or equal to the first preset value, or a second target power value that first appears with an absolute value greater than the second preset value; and correcting the abnormal historical power data based on the numerical change trend of the first target power value and / or the second target power value to obtain first corrected power data.

[0051] In this embodiment, for the obtained first historical power data, the power change amount is calculated. Further, the historical power data with a negative power change amount and an absolute value of the power change amount greater than a first preset value (indicating that there may be a sudden large drop in power at a certain moment due to data transmission error or the photovoltaic power station receiving a power limit instruction), or the absolute value of the power change amount less than a second preset value and lasting for a preset duration is marked as abnormal historical power data; the second preset value is approximately zero (indicating that there may be a power drop to a low value close to zero or to zero due to data transmission error or the photovoltaic power station receiving a power limit instruction within a period of time) is marked as abnormal historical power data; the above method of marking abnormal historical power data based on the power change amount can, compared with traditional methods that rely on thresholds or simple interpolation, more sensitively capture the sudden drop and abnormal flat section of power based on differences, so as to accurately locate the abnormal points.

[0052] Further, the power data whose time sequence is prior to the abnormal historical power data is screened by means of upward interpolation to obtain a first target power value that first appears with a positive power change amount or an absolute value of the change amount less than or equal to the first preset value, or a second target power value that first appears with an absolute value greater than the second preset value; the abnormal historical power data is corrected based on the numerical change trend of the first target power value and the second target power value to obtain first corrected power data; the above upward interpolation method shows excellent stability when filling missing values in the new energy field. Especially when there is a long data gap, forward interpolation can provide a smooth and reasonable transition and will not introduce excessive fluctuations like simple linear interpolation.

[0053] In addition, considering that in special cases such as load curtailment on sunny days, the relationship between the actual output of the photovoltaic system and solar irradiance will deviate abnormally. In the present invention, a correlation threshold filtering mechanism is further set to further screen the historical power data according to the correlation coefficient between the measured irradiance data and the actual power data.

[0054] Specifically, as an exemplary embodiment, the historical meteorological data includes historical measured irradiance data. After obtaining the first historical power data and the first historical meteorological data of the target photovoltaic power station, the photovoltaic power prediction method further includes: In the historical meteorological data, extract the historical measured irradiance data corresponding to the time series of the first historical power data; Taking a day as the time scale, calculate the correlation coefficient between the historical measured irradiance corresponding to the time series and the first historical power data; Eliminate the first historical power data with a correlation coefficient less than the preset correlation coefficient; wherein, the preset correlation coefficient takes any value within the range of [0.8, 1]; In this embodiment, taking a day as the time scale, calculate the correlation coefficient between the historical measured irradiance corresponding to the time series and the first historical power data; if the correlation coefficient is lower than the preset correlation coefficient, it is considered that the photovoltaic output on that day is inconsistent with the normal light - power generation mode, and there may be, for example, output limitation under sunny conditions due to load curtailment for peak shaving, or abnormal factors interfering with the data on that day; filter the first historical power data below the threshold to eliminate these abnormal data with meteorological - power mismatch, ensuring that the data input into the model is more accurate and reliable.

[0055] After the above cleaning steps, the quality of the historical data set used by the model is greatly improved, laying a solid foundation for subsequent predictions.

[0056] As an exemplary embodiment, the method for training the photovoltaic power prediction model includes: Obtain the second historical power data of the target photovoltaic power station in the first period, the third historical power data in the second period, and the second historical meteorological data corresponding to the time series of the second historical power data; wherein, the first period and the second period are adjacent in time series, and the first period is earlier than the second period; decompose the second historical power data to obtain the second long-term trend characteristics and corresponding second short-term fluctuation characteristics of the second historical power data at multiple preset time scales; input the second historical power data and the second historical meteorological data into a pre-constructed photovoltaic power prediction model for model training; during the model training, use the third historical power data as the target value, and based on the photovoltaic power prediction model, learn the mapping relationship between the second long-term trend characteristics, the second short-term fluctuation characteristics of the second historical power data at each of the preset time scales, the second historical meteorological data and the third historical power data, and learn the fusion relationship when fusing the sub-power prediction results corresponding to each of the preset time scales to obtain the power prediction result.

[0057] Exemplarily, the first period can be a season, and the second period is the target prediction duration for photovoltaic power prediction.

[0058] Exemplarily, the photovoltaic power prediction model is used for ultra-short-term photovoltaic power prediction, and the second period is from 15 minutes to 4h.

[0059] Exemplarily, the photovoltaic power prediction model is used for short-term photovoltaic power prediction, and the second period is 24h, 32h, 72h.

[0060] Exemplarily, after obtaining the second historical power data of the target photovoltaic power station in the first period and the third historical power data in the second period, correct the second historical power data and the third historical power data for abnormal historical power data as in the above embodiments.

[0061] Furthermore, decompose the corrected second historical power data to obtain the second long-term trend characteristics and corresponding second short-term fluctuation characteristics of the second historical power data at multiple preset time scales.

[0062] Exemplarily, after obtaining the second historical power data, based on the fluctuation characteristics of the second historical power data, decompose the second historical power data to obtain the first long-term trend characteristics and corresponding second short-term fluctuation characteristics of the second historical power data at multiple preset time scales.

[0063] Among them, the preset time scales are hour, day and night, day, week, season.

[0064] Exemplarily, after obtaining the second historical power data, the second historical power data may first be intercepted according to a preset time scale to respectively obtain second sub-historical power data sequences with preset time scales of hour, day and night, day, week, and quarter. Further, each second sub-historical power data sequence is decomposed to obtain second long-term trend features and corresponding second short-term fluctuation features of the second historical power data at multiple preset time scales.

[0065] Exemplarily, a method of wavelet decomposition may be used to perform multi-layer wavelet decomposition on the second historical power data to obtain long-term trend features and short-term fluctuation features. Specifically, discrete wavelet transform (DWT) is performed on the second historical power data to obtain detail coefficients and approximation coefficients of each layer of wavelet transform. Among them, the approximation coefficients are used to represent the second long-term trend features of the second historical power data, and the detail coefficients are used to represent the second short-term fluctuation features under each layer of wavelet decomposition. Each group of wavelet coefficients represents the dynamic features of the first historical power data at each preset time scale.

[0066] In the above method, wavelet decomposition is performed on the second historical power data according to a preset time scale. Compared with the wavelet decomposition method in the related art, the long-term trend features and short-term fluctuation features of the second historical power data at multiple preset time scales can be obtained.

[0067] In one embodiment, for the obtained multiple second sub-historical power data sequences, different scaling functions and wavelet functions may be set based on the fluctuation features of the second sub-historical power data sequences to match the fluctuation states of each second sub-historical power data sequence.

[0068] In one embodiment, for the obtained multiple second sub-historical power data sequences, different scaling functions and wavelet functions may be set based on the fluctuation features of the second sub-historical power data sequences, and at the same time, different wavelet decomposition layers may be set based on the fluctuation features of the second sub-historical power data sequences to match the fluctuation states of each second sub-historical power data sequence. Further, each group of wavelet scale features is input into an independent encoder network designed according to a preset time scale to map it to a unified feature space for subsequent processing. The encoded features of each preset time scale are input into a pre-constructed backbone structure of the photovoltaic power model to participate in subsequent training tasks.

[0069] Further, input the mapped second historical power data and the second historical meteorological data into a pre-constructed photovoltaic power prediction model for model training; during the model training process, using the third historical power data as the target value, based on the photovoltaic power prediction model, learn the second long-term trend characteristics, the second short-term fluctuation characteristics of the second historical power data at each of the preset time scales, the mapping relationship between the second historical meteorological data and the third historical power data, and the fusion relationship when learning to fuse the sub-power prediction results corresponding to each of the preset time scales to obtain the power prediction result.

[0070] For the above method, on the one hand, input the long-term trend and short-term fluctuations of the second historical power data obtained by wavelet decomposition of the second historical power data according to the preset time scale into the photovoltaic power prediction model for model training. During the model training, the long-term trend characteristics and short-term fluctuation characteristics at multiple preset time scales have different time domain resolutions, and the model can learn the corresponding relationship between the power fluctuation conditions and power values at each time domain resolution.

[0071] As described above, in the wavelet decomposition method in the related art, too many rounds of wavelet decomposition may cause the short-term fluctuations extracted to be influencing factors such as noise in the power sequence, power mutations under the influence of power curtailment, etc. The long-term trend characteristics extracted are lost in the fluctuations of the original power sequence corresponding to the fixed preset time scale due to too many rounds of decomposition, resulting in inaccurate prediction results of the finally trained power prediction model.

[0072] To solve this problem, in the present invention, after obtaining the long-term trend characteristics and short-term fluctuation characteristics at multiple preset time scales, further construct a feature correction model during model training to correct the fluctuation characteristics; for example, after obtaining the second long-term trend characteristics and the second short-term trend characteristics, in order to further enhance the interaction ability between different time scale information, construct a neural network based on the second long-term trend characteristics and the second short-term trend characteristics, and learn the non-linear dependence relationship between the second long-term trend characteristics and the second short-term trend characteristics between different time scale channels through the neural network.

[0073] Based on this, as an exemplary embodiment, after decomposing the first historical power data based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend characteristics and corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales, the photovoltaic power prediction method further includes: inputting the first long-term trend characteristics and the first short-term fluctuation characteristics into a pre-constructed feature correction model, and using the feature correction model to correct the first long-term trend characteristics and / or the first short-term fluctuation characteristics based on the mapping relationship between the second long-term trend characteristics and the second short-term fluctuation characteristics; wherein, the feature correction model is trained based on the second long-term trend characteristics and the second short-term fluctuation characteristics, and the feature correction model is composed of a first fully connected layer, a second fully connected layer, and a ReLU activation function; the first fully connected layer is used to input the second long-term trend characteristics, the second fully connected layer is used to input the second short-term trend characteristics, and the first fully connected layer and the second fully connected layer are activated by the ReLU activation function; during the process of model training, the model parameters of the feature correction model are continuously adjusted so that the feature correction model learns the mapping relationship between the second long-term trend characteristics and the second short-term fluctuation characteristics.

[0074] In the above implementation manner, a non-linear dependence relationship between different scale channels can be established through the feature correction model, so as to more accurately capture the coupling behavior between multiple scales; the method of inputting the first long-term trend characteristics and the first short-term fluctuation characteristics into a pre-constructed feature correction model, on the one hand, when the long-term trend characteristics show abnormal mutations, the stable trend information provided by the short-term fluctuation characteristics can correct them, making the overall model more robust to drastic weather changes.

[0075] As an exemplary embodiment, the photovoltaic power prediction model includes multiple sub-prediction networks corresponding to the preset time scales and a weighted fusion module. The process of inputting the second historical power data and the second historical meteorological data into a pre-constructed photovoltaic power prediction model for model training includes: inputting the second long-term trend characteristics, the second short-term fluctuation characteristics, and the second historical meteorological data at each preset time scale into the sub-prediction networks corresponding to each preset time scale for training; during the training process, taking the third historical power data as the target value, continuously adjusting the network parameters of each sub-prediction network so that each sub-prediction network learns the corresponding relationship between the second long-term trend characteristics, the second short-term fluctuation characteristics, the second historical meteorological data, and the third historical power data at the corresponding preset time scale until each sub-prediction network converges; based on the weighted fusion module, learning the fusion relationship when fusing the sub-power prediction results corresponding to each preset time scale to obtain the power prediction result.

[0076] In this embodiment, the photovoltaic power prediction model includes multiple sub-prediction networks corresponding to the preset time scales and a weighted fusion module; wherein, each sub-prediction network uses the third historical power data as the target value and inputs the second long-term trend feature, the second short-term fluctuation feature, and the second historical meteorological data corresponding to the preset time scale for training; when performing model training, the features extracted under different wavelet scales are respectively sent into multiple sub-prediction networks with relatively independent structures and their respective exclusive network weights. Each sub-prediction network is trained for the features of a specific scale and outputs the power prediction estimate at the current scale, which can avoid interference between different scales and improve the accuracy and stability of each sub-prediction network.

[0077] Exemplarily, the sub-prediction network can be a decoupled sub-predictor.

[0078] Further, after all sub-prediction networks have completed individual predictions, the photovoltaic power prediction model fuses the sub-power prediction results of each sub-prediction network through the weighted fusion module to obtain the photovoltaic power prediction result.

[0079] Among them, exemplarily, the weighted fusion module can adopt a multi-head attention mechanism to assign a fusion weight to the output of each sub-prediction network according to the input features and the historical prediction error feedback of each sub-prediction network, and finally fuse the sub-power prediction results based on the fusion weights to obtain the power prediction result.

[0080] Specifically, the weighted fusion module can be a Hierarchical Attention Fusion (HAF) module, which is used to integrate the prediction results of different scales; this module uses a multi-head attention mechanism to assign a fusion weight to the output of each sub-prediction network according to the input features and the historical error feedback , and finally aggregates and outputs the predicted value using Equation (1): (1) In Equation (1), represents the power prediction result, represents the fusion weight of the i-th sub-prediction network, represents the sub-power prediction result of the i-th sub-prediction network, and the sum of the fusion weights of all sub-prediction networks is 1.

[0081] In one embodiment, when assigning a weight to the output of each sub-prediction network according to the input features and the historical prediction error feedback of each sub-prediction network, as a possible implementation, the fusion weights can be matched according to the prediction errors of each sub-prediction network on the test set; among them, the fusion weights are positively correlated with the prediction errors.

[0082] In one embodiment, when allocating a weight to each sub-prediction network output according to the historical prediction error feedback of the input feature and each sub-prediction network, the corresponding relationship between the second long-term trend feature, the second short-term trend feature, and the fusion weight can be learned based on the test results when testing each sub-prediction network; when performing photovoltaic power prediction subsequently, the fusion weight is determined based on the first long-term trend feature, the first short-term trend feature, and the corresponding relationship.

[0083] As an exemplary embodiment, decomposing the first historical power data based on the fluctuation characteristics of the first historical power data to obtain the first long-term trend feature and the corresponding first short-term fluctuation feature of the first historical power data at multiple preset time scales includes: obtaining the preset scale function and the preset wavelet function corresponding to each of the preset time scales during wavelet decomposition; sequentially performing discrete wavelet decomposition on the first historical power data based on each of the scale functions and wavelet functions to obtain the approximation coefficient and the detail coefficient corresponding to each of the preset time scales; wherein, the approximation coefficient is used to represent the first long-term trend feature of the historical power data at the current preset time scale, and the detail coefficient is used to represent the first short-term fluctuation feature at the current preset time scale.

[0084] As an exemplary embodiment, performing weighted smoothing on the power prediction result to obtain the photovoltaic power prediction result includes: traversing each power prediction value in the power prediction result, and taking the first preset number of target power prediction values before and after the power prediction value as the prediction power data sequence; determining the smoothing weight of each target power prediction value based on the sequence distance of each target power prediction value in each prediction power data sequence relative to the power prediction value; wherein, each smoothing weight is inversely correlated with the sequence distance; correcting each power prediction value based on each smoothing weight and each target power prediction value to obtain the photovoltaic power prediction result.

[0085] In this embodiment, in order to further improve the practicality of the power prediction result output by the power prediction model, the present invention adds a post-processing step after obtaining the preliminary prediction value to smooth and correct the prediction curve.

[0086] Specifically, in the power prediction result, traversing each power prediction value, and taking the first preset number of target power prediction values before and after the power prediction value as the prediction power data sequence; determining the smoothing weight of each target power prediction value based on the sequence distance of each target power prediction value in each prediction power data sequence relative to the power prediction value; wherein, each smoothing weight is inversely correlated with the sequence distance; correcting each power prediction value based on each smoothing weight and each target power prediction value to obtain the photovoltaic power prediction result.

[0087] Specifically, at a moment t corresponding to each of the power prediction values, the first preset number of target power values before and after are selected as the predicted power data sequence; based on the sequence distance of each of the target power prediction values in each of the predicted power data sequences relative to the power prediction value, the smoothing weight of each of the target power prediction values is determined.

[0088] Then the smoothed power can be calculated according to Equation (2): (2) In Equation (2), is the smoothed power, is the original predicted value within the window, the smoothing weight is ω k , k is the sequence distance of each of the target power prediction values relative to the power prediction value, as |k| increases (that is, the farther away from the moment center t corresponding to the power prediction value), ω k becomes smaller, ω k decreases linearly to 0 according to the triangle rule.

[0089] The above smoothing method can effectively reduce the severe fluctuations or spikes on the short-time scale while keeping the overall curve trend unchanged, making the prediction curve look smoother and more coherent.

[0090] In the present invention, further smoothing of the power prediction result is considered by further considering the differences in time points or output characteristics; specifically, as an exemplary embodiment, the photovoltaic power prediction method further includes: in the power prediction result, calculating the power change rate of each power prediction value relative to N adjacent power prediction values that are earlier and / or later in time series; where N is a positive integer; obtaining the power change rate corresponding to each of the power prediction values; determining the first preset number based on the power change rate; where the first preset number is inversely correlated with the change rate.

[0091] In this embodiment, the power change rate of each power prediction value relative to N adjacent power prediction values that are earlier and / or later in time series is calculated; where N is a positive integer; the power change rate corresponding to each of the power prediction values is obtained; the first preset quantity is determined based on the power change rate, so as to adjust the quantity of target power prediction values selected during smoothing according to the influence of the time point or output characteristics of the photovoltaic power station; in the above implementation, in time periods with large slope changes such as sunrise in the early morning and sunset in the evening of photovoltaic output, a smaller window can be used to retain change details; while in the period of stable output at noon, a slightly larger window can be used to filter out minute jitters; compared with the traditional method of using a fixed sliding average window, this dynamic weighted smoothing strategy has two advantages: on the one hand, it ensures the effectiveness of the smoothing process (both removing irrelevant noise and not overly weakening the true change signal), and on the other hand, it also improves the interpretability of the results (using different smoothing intensities in different stages, which is more in line with the actual physical meaning). The prediction curve of the photovoltaic power prediction result obtained after smoothing is smoother and closer to the actual situation, and is more valuable for grid dispatching and power station operation.

[0092] This embodiment provides a photovoltaic power prediction device, as Figure 2 shown, including: An acquisition module 501, configured to acquire first historical power data and first historical meteorological data of a target photovoltaic power station; A decomposition module 502, configured to decompose the first historical power data based on the fluctuation characteristics of the first historical power data, so as to obtain a first long-term trend characteristic and a corresponding first short-term fluctuation characteristic of the first historical power data at multiple preset time scales; A power prediction module 503, configured to input the first long-term trend characteristic, the first short-term fluctuation characteristic, and the first historical meteorological data at each of the preset time scales into a pre-trained photovoltaic power prediction model to obtain a power prediction result; where the photovoltaic power prediction model is trained based on second historical power data in a first time period, third historical power data in a second time period, and second historical meteorological data; during the model training process, taking the third historical power data as the target value, learning the mapping relationship between the second long-term trend characteristic, the second short-term fluctuation characteristic, the second historical meteorological data and the third historical power data of the second historical power data at each of the preset time scales, and learning the fusion relationship when fusing sub-power prediction results corresponding to each of the preset time scales to obtain the power prediction result; A smoothing module 504, configured to perform weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result.

[0093] It should be noted here that the examples and application scenarios implemented by the above modules and the corresponding steps are the same, but are not limited to the content disclosed in the above embodiments.

[0094] It should be noted that the above module, as a part of the device, can be implemented by software or by hardware. Among them, the hardware environment includes a network environment.

[0095] An embodiment of the present invention further provides a computer device, including a processor, a communication interface, a memory, and a communication bus. Among them, the processor, the communication interface, and the memory complete communication with each other through the communication bus. The memory is used to store a computer program; the processor is used to execute the method in any of the above embodiments by running the computer program stored on the memory.

[0096] Figure 3 is a structural block diagram of an optional computer device according to an embodiment of the present application. As Figure 3 shown, it includes a processor 10, a communication interface 20, a memory 30, and a communication bus 40. Among them, the processor 10, the communication interface 20, and the memory 30 complete communication with each other through the communication bus 40. Among them, the memory 30 is used to store a computer program; when the processor 10 is used to execute the computer program stored on the memory 30, it implements the method of any of the above embodiments.

[0097] Optionally, in this embodiment, the above communication bus may be a PCI (Peripheral Component Interconnect) bus, an EISA (Extended Industry Standard Architecture) bus, etc. The communication bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, Figure 3 only a thick line is used to represent it in the figure, but it does not mean that there is only one bus or one type of bus.

[0098] The communication interface is used for communication between the above computer device and other devices.

[0099] The memory may include a RAM, and may also include a non-volatile memory, for example, at least one disk memory. Optionally, the memory may also be at least one storage device located far from the aforementioned processor.

[0100] The above-mentioned processor may be a general-purpose processor, which may include but is not limited to: CPU (Central Processing Unit, central processing unit), NP (Network Processor, network processor), etc.; it may also be a DSP (Digital Signal Processing, digital signal processor), ASIC (Application Specific Integrated Circuit, application-specific integrated circuit), FPGA (Field-Programmable Gate Array, field-programmable gate array) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.

[0101] Optionally, the specific examples in this embodiment may refer to the examples described in the above embodiments, and will not be elaborated herein.

[0102] Those of ordinary skill in the art can understand that Figure 3 The structure shown is only schematic. The device for implementing the method of any one of the above embodiments may be a terminal device, which may be a smart phone (such as an Android phone, an IOS phone, etc.), a tablet computer, a palm computer, and a mobile Internet device (Mobile Internet Devices, MID), a PAD and other terminal devices. Figure 3 It does not limit the structure of the above-mentioned electronic device. For example, the terminal device may further include more or fewer components than those shown (such as a network interface, a display device, etc.), or have a different configuration from that shown. Figure 3 shown, or have a different configuration from that shown. Figure 3 shown.

[0103] Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above embodiments can be completed by instructing the relevant hardware of the terminal device through a program, and the program can be stored in a computer-readable storage medium. The storage medium may include: a flash drive, a ROM, a RAM, a magnetic disk or an optical disc, etc.

[0104] As an exemplary embodiment, the present application also provides a computer-readable storage medium, in which a computer program is stored, and the computer program is configured to execute the method steps of any one of the embodiments when running.

[0105] Optionally, in this embodiment, the above storage medium may be used for the program code for executing the method steps of the embodiments of the present application.

[0106] Optionally, in this embodiment, the above storage medium may be located on at least one of the multiple network devices in the network shown in the above embodiments.

[0107] Optionally, in this embodiment, the storage medium is configured to store the method for executing the above embodiment.

[0108] Optionally, for the specific examples in this embodiment, reference may be made to the examples described in the above embodiment, and details thereof will not be repeated herein.

[0109] Optionally, in this embodiment, the above storage medium may include, but is not limited to: various media that can store program codes, such as USB flash drives, ROMs, RAMs, mobile hard disks, magnetic disks, or optical discs.

[0110] The serial numbers of the embodiments of the present application above are only for description and do not represent the superiority or inferiority of the embodiments.

[0111] If the integrated unit in the above embodiment is implemented in the form of a software functional unit and sold or used as an independent product, it may be stored in the above computer-readable storage medium. Based on such an understanding, the technical solution of the present application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, may be embodied in the form of a software product. The computer software product is stored in the storage medium and includes several instructions for causing one or more computer devices (which may be personal computers, servers, or network devices, etc.) to execute all or part of the steps of the method in the above embodiment.

[0112] In several embodiments provided by the present application, it should be understood that the disclosed client can be implemented in other ways. Among them, the device embodiments described above are only illustrative. For example, the division of units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed couplings or direct couplings or communication connections to each other can be through some interfaces. The indirect couplings or communication connections of units or modules can be in an electrical or other form.

[0113] The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they can be located in one place or distributed to multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution provided in this embodiment.

[0114] In addition, in each embodiment of the present application, the functional units can be integrated in a processing unit, or each unit can exist physically alone, or two or more units can be integrated in one unit. The above integrated units can be implemented in the form of hardware or in the form of software functional units.

[0115] In the above-mentioned embodiments of the present application, the descriptions of the respective embodiments have their own emphases. For the parts not detailed in a certain embodiment, reference may be made to the relevant descriptions of other embodiments.

[0116] The above are only the preferred embodiments of the present application. It should be noted that for those of ordinary skill in the art, without departing from the principle of the present application, several improvements and refinements can be made, and these improvements and refinements should also be regarded as the protection scope of the present application.

Claims

1. A photovoltaic power prediction method, characterized in that The photovoltaic power prediction method includes: Obtaining first historical power data and first historical meteorological data of a target photovoltaic power station; Decomposing the first historical power data based on the fluctuation characteristics of the first historical power data to obtain first long-term trend characteristics and corresponding first short-term fluctuation characteristics of the first historical power data at multiple preset time scales; Inputting the first long-term trend characteristics, the first short-term fluctuation characteristics, and the first historical meteorological data at each of the preset time scales into a pre-trained photovoltaic power prediction model to obtain a power prediction result; wherein, the photovoltaic power prediction model is trained based on second historical power data in a first time period, third historical power data in a second time period, and second historical meteorological data; during the model training process, taking the third historical power data as the target value, based on the photovoltaic power prediction model, learning the second long-term trend characteristics, second short-term fluctuation characteristics, the mapping relationship between the second historical meteorological data and the third historical power data at each of the preset time scales, and the fusion relationship when learning to fuse sub-power prediction results corresponding to each of the preset time scales to obtain a power prediction result; Performing weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result.

2. The photovoltaic power prediction method according to claim 1, wherein The method for training the photovoltaic power prediction model includes: Obtaining second historical power data in a first time period, third historical power data in a second time period, and second historical meteorological data corresponding to the time sequence of the second historical power data of a target photovoltaic power station; wherein, the first time period and the second time period are adjacent in time sequence, and the first time period is earlier than the second time period; Decomposing the second historical power data to obtain second long-term trend characteristics and corresponding second short-term fluctuation characteristics of the second historical power data at multiple preset time scales; Inputting the second historical power data and the second historical meteorological data into a pre-constructed photovoltaic power prediction model for model training; during the model training process, taking the third historical power data as the target value, based on the photovoltaic power prediction model, learning the second long-term trend characteristics, the second short-term fluctuation characteristics, and the mapping relationship between the second historical meteorological data and the third historical power data at each of the preset time scales, and the fusion relationship when learning to fuse sub-power prediction results corresponding to each of the preset time scales.

3. The photovoltaic power prediction method according to claim 2, characterized in that, The photovoltaic power prediction model includes sub-prediction networks corresponding to multiple preset time scales and a weighted fusion module, and the inputting the second historical power data and the second historical meteorological data into a pre-constructed photovoltaic power prediction model for model training includes: Input the second long-term trend feature, the second short-term fluctuation feature, and the second historical meteorological data at each of the preset time scales into the sub-prediction networks corresponding to the respective preset time scales for training; during the training process, using the third historical power data as the target value, continuously adjust the network parameters of each sub-prediction network so that each sub-prediction network learns the corresponding relationship between the second long-term trend feature, the second short-term fluctuation feature, the second historical meteorological data, and the third historical power data at the corresponding preset time scale until each sub-prediction network converges; Based on the weighted fusion module, learn the fusion relationship when fusing the sub-power prediction results corresponding to each preset time scale to obtain the power prediction result.

4. The photovoltaic power prediction method according to claim 3, wherein After decomposing the first historical power data based on the fluctuation feature of the first historical power data to obtain the first long-term trend feature and the corresponding first short-term fluctuation feature of the first historical power data at multiple preset time scales, the photovoltaic power prediction method further includes: Input the first long-term trend feature and the first short-term fluctuation feature into a pre-constructed feature correction model, and use the feature correction model to correct the first long-term trend feature and / or the first short-term fluctuation feature based on the mapping relationship between the second long-term trend feature and the second short-term fluctuation feature; wherein, the feature correction model is trained based on the second long-term trend feature and the second short-term fluctuation feature, and the feature correction model is composed of a first fully connected layer, a second fully connected layer, and a ReLU activation function; the first fully connected layer is used to input the second long-term trend feature, the second fully connected layer is used to input the second short-term trend feature, and the first fully connected layer and the second fully connected layer are activated by the ReLU activation function; during the process of model training, continuously adjust the model parameters of the feature correction model so that the feature correction model learns the mapping relationship between the second long-term trend feature and the second short-term fluctuation feature.

5. The photovoltaic power prediction method according to claim 1, wherein, Before decomposing the first historical power data based on the fluctuation feature of the historical power data, the photovoltaic power prediction method further includes: Obtain the historical measured irradiance data that is temporally matched with the first historical power data; Calculate the correlation coefficient between the historical measured irradiance data and the first historical power data that is temporally matched; Remove the first historical power data with a correlation coefficient less than the preset correlation coefficient.

6. The photovoltaic power prediction method according to claim 1, characterized in that The weighted smoothing of the power prediction result to obtain the photovoltaic power prediction result includes: In the power prediction result, traverse each power prediction value, and use the first preset number of target power prediction values before and after the power prediction value as the prediction power data sequence; Determine the smoothing weight of each target power prediction value based on the sequence distance of each target power prediction value in each prediction power data sequence relative to the power prediction value; wherein, each smoothing weight is inversely correlated with the sequence distance. Based on each of the smoothing weights and each of the target power prediction values, correct each of the power prediction values to obtain a photovoltaic power prediction result.

7. The photovoltaic power prediction method according to claim 6, wherein, The photovoltaic power prediction method further includes: In the power prediction result, calculate the power change rate of each power prediction value relative to N adjacent power prediction values that are earlier and / or later in time series; where N is a positive integer; Obtain the power change rate corresponding to each of the power prediction values; Determine the first preset quantity based on the power change rate; where the first preset quantity is inversely correlated with the change rate.

8. A photovoltaic power prediction device, characterized in that, The photovoltaic power prediction device includes: An acquisition module, configured to acquire first historical power data and first historical meteorological data of a target photovoltaic power station; A decomposition module, configured to decompose the first historical power data based on the fluctuation characteristics of the first historical power data to obtain a first long-term trend characteristic and a corresponding first short-term fluctuation characteristic of the first historical power data at multiple preset time scales; A power prediction module, configured to input the first long-term trend characteristic, the first short-term fluctuation characteristic, and the first historical meteorological data at each of the preset time scales into a pre-trained photovoltaic power prediction model to obtain a power prediction result; where the photovoltaic power prediction model is trained based on second historical power data in a first time period, third historical power data in a second time period, and second historical meteorological data; during the model training process, taking the third historical power data as the target value, learning the mapping relationship between the second long-term trend characteristic, the second short-term fluctuation characteristic, the second historical meteorological data, and the third historical power data of the second historical power data at each of the preset time scales, and learning the fusion relationship when fusing sub-power prediction results corresponding to each of the preset time scales to obtain a power prediction result; A smoothing module, configured to perform weighted smoothing on the power prediction result to obtain a photovoltaic power prediction result.

9. A computer device, characterized in that, Including: A memory and a processor, which are communicatively connected to each other. The memory stores computer instructions, and the processor executes the computer instructions to execute the photovoltaic power prediction method according to any one of claims 1 to 7.

10. A computer-readable storage medium, characterized in that, Computer instructions are stored on the computer-readable storage medium, and the computer instructions are used to cause a computer to execute the photovoltaic power prediction method according to any one of claims 1 to 7.

Citation Information

Patent Citations

  • Photovoltaic output power prediction method and system and storage medium

    CN109840633A

  • Power efficiency optimization method based on intelligent load management

    CN119578923A

  • Photovoltaic power generation short-term power prediction method and system

    WO2023216576A1

Cited By

  • Generating capacity prediction method and device, electronic equipment, storage medium and program product

    CN121010048A

  • Photovoltaic power prediction method

    CN121256366A