Photovoltaic power explainable prediction method based on self-evolution digital twinning

CN122203204BActive Publication Date: 2026-10-20ANHUI UNIV
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202610307183.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-03-13
Publication Date
2026-10-20
Estimated Expiration
2046-03-13

AI Technical Summary

Technical Problem

[0004]针对现有技术的不足,本发明提供了一种基于自进化数字孪生的光伏发电功率可解释预测方法,解决了现有光伏预测技术中数据缺失修复困难及模型无法在线适应环境变化的问题

Benefits of technology

(1)本发明通过引入基于物理约束的条件扩散模型进行高保真数据修复,此时生成的修复数据相比传统基于对抗生成网络(GAN)的方法更稳定、多样且严格符合光伏物理规律,为下游预测奠定了更优质的数据基础;

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122203204B_ABST
    Figure CN122203204B_ABST
Patent Text Reader

Abstract

The application relates to an interpretable photovoltaic power prediction method based on self-evolution digital twinning, which comprises the following steps: recovering historical operation data of a photovoltaic power station based on a condition diffusion model based on physical constraints; generating physical prediction power by constructing a physical mechanism model; constructing a data-driven model, combining a convolutional neural network and a bidirectional long short-term memory network to extract features, introducing a double attention mechanism layer to perform attention weighting, and outputting data-driven prediction power; obtaining photovoltaic power prediction results by performing weighted fusion based on prediction error statistics; establishing a typical extreme weather memory bank, and performing targeted incremental learning optimization and updating on the model based on an attribution diagnosis result, so that the model is continuously closed-loop self-evolution. The application effectively solves the pain points of poor data quality, a black-box model that cannot be interpreted, and the inability to accurately identify the aging trend of components in the traditional photovoltaic prediction method, and significantly improves the prediction accuracy, logical transparency and operation robustness.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the fields of new energy power generation prediction and artificial intelligence application technology, and in particular to an interpretable prediction method for photovoltaic power generation based on self-evolving digital twins. Background Technology

[0002] As photovoltaic (PV) power generation continues to increase its share in the energy structure, its inherent volatility, intermittency, and randomness pose significant challenges to the power balance and safe dispatch of power systems. Accurate PV power forecasting is a key technology for solving this problem. Existing PV power forecasting methods are mainly divided into physical methods and data-driven methods. Physical methods are based on the equivalent circuit model of PV modules and rely on accurate meteorological data and module parameters; however, their prediction accuracy decreases significantly when modules age or parameters drift. Data-driven methods (such as deep learning models like CNN and LSTM) rely on high-quality historical data for training and typically employ a static "offline training, online deployment" model. However, in practical industrial applications, existing technologies suffer from two major pain points: First, the data quality is poor. The harsh environment of photovoltaic power plants often leads to missing or abnormal data due to sensor malfunctions and packet loss in communication transmission. Traditional interpolation methods have limited accuracy, while existing generative adversarial networks (GANs) are prone to model collapse due to gradient imbalances when repairing long-term data series. They also generate data with insufficient diversity and often violate physical laws, making it difficult to handle complex long-term weather patterns. Second, the model has poor adaptability (concept drift). The performance of photovoltaic modules degrades over time, and weather patterns exhibit seasonal variations. Once a static model is trained, it cannot adapt to these dynamic changes—a phenomenon known as concept drift—leading to a gradual decline in prediction accuracy after long-term operation and a disconnect from the real physical system.

[0003] Therefore, there is a need for an interpretable prediction method for photovoltaic power generation that possesses high-quality data self-repair capabilities and can evolve online in response to environmental changes, while also ensuring the interpretability of the predictions. Summary of the Invention

[0004] To address the shortcomings of existing technologies, this invention provides an interpretable prediction method for photovoltaic power generation based on self-evolving digital twins, which solves the problems of data loss repair difficulties and the inability of models to adapt to environmental changes online in existing photovoltaic prediction technologies.

[0005] To achieve the above technical objectives, the present invention provides the following technical solution: a method for interpretable prediction of photovoltaic power generation based on self-evolving digital twins, comprising the following steps: Collect meteorological characteristics and historical operation data of photovoltaic power plants, and construct a binary mask matrix using the effective observation values ​​in the real-time operation data as physical constraints. Build and train a photovoltaic digital twin data recovery model to repair historical operation data. Combine meteorological characteristics to form input data features, and use the actual power in the historical operation data as labels to build a repair dataset. A physical mechanism model is constructed, and numerical weather prediction data is input into the physical mechanism model to output the physical predicted power; the key parameters of the physical mechanism model include at least the heat transfer coefficient and the series resistance. A data-driven model is constructed, which inputs the features of the input data into the data-driven model and outputs the predicted power. The data-driven model includes a parallel feature extraction dual-branch, a feature fusion layer, a dual attention mechanism layer, and a fully connected layer. The photovoltaic digital twin data recovery model, the physical mechanism model, and the data-driven model constitute a photovoltaic power generation prediction model. The weighting coefficients of physical predicted power and data-driven predicted power are calculated based on the prediction error statistics within a preset historical sliding window, and then weighted and summed to obtain the photovoltaic power generation prediction result. Based on the cumulative error trend between the photovoltaic power generation prediction results and the actual power calculation, it is determined whether concept drift has occurred; If concept drift occurs, a typical extreme weather memory bank is established and an update strategy is designed. A normalized consistency score is calculated based on the feature weight distribution from the dual attention mechanism layer. At the same time, the meteorological attribution ratio of the photovoltaic digital twin data recovery model is calculated, and attribution diagnosis is performed. Based on the typical extreme weather memory bank, the photovoltaic power generation prediction model is optimized and updated by incremental learning, in combination with the attribution diagnosis results, so as to realize the continuous closed-loop self-evolution of the photovoltaic power generation prediction model.

[0006] Optionally, the construction and training of the photovoltaic digital twin data recovery model to repair historical operating data includes: The photovoltaic digital twin data recovery model is a conditional diffusion model based on physical constraints; Define the total loss function for training the photovoltaic digital twin data recovery model. as follows: ; in, This is the basic denoising error loss for the conditional diffusion model. Standard Gaussian noise representing the forward diffusion process in the conditional diffusion model. This represents the noise component predicted by the inverse denoising process of the conditional diffusion model. The conditional input states representing the forward diffusion process of the conditional diffusion model are the historical operating data of the photovoltaic power plant. via binary mask matrix The processed result, the processing procedure mathematically represented as follows: , Indicates a time step; This indicates the forward diffusion process in the conditional diffusion model at time step [missing information]. The noise-added state; These are the physical constraint weighting coefficients; The physical constraint loss is calculated using the following formula: ; in, The power prediction values ​​generated for the photovoltaic digital twin data recovery model This is the theoretical upper limit of power calculated based on the physical mechanism model. This is a nighttime indicator function, used when it is nighttime. ; Represents the ReLU activation function; Represents the square of the L2 norm; In the reverse denoising process of the conditional diffusion model, a deterministic accelerated sampling strategy based on the implicit denoising diffusion model is adopted, using skip-step subsequences. Perform reverse generation; use the following formula combined with the binary mask matrix. Calculate the denoised intermediate data state of the previous time step. : ; in, Indicates a time step. Indicates the number of reverse generation steps; The binary mask matrix is ​​constructed based on valid observations. In the real-time running data, the corresponding position of a valid observation in the binary mask matrix is ​​1, and the corresponding position of a missing value in the binary mask matrix is ​​0; the intermediate data state... In the reverse noise reduction process, the historical operating data of the photovoltaic power station is time-stepped. The distribution state; Historical operating data of photovoltaic power plants These are the noise scheduling parameters for the forward diffusion process in the pre-defined conditional diffusion model. These are unconstrained sampled values ​​generated during the forward diffusion process. This indicates element-wise multiplication.

[0007] Optionally, the step of inputting numerical weather prediction data into a physical mechanism model and outputting a physical predicted power includes: Calculate the actual operating temperature of photovoltaic modules : ; in, For ambient temperature, Irradiance, For wind speed, Indicates the basic heat transfer coefficient of a photovoltaic module. This represents the wind speed gain heat transfer coefficient of a photovoltaic module. Combined with the actual operating temperature of photovoltaic modules A photoelectric conversion model is constructed using a single diode equivalent circuit, and the photoelectric conversion model is described by the following equations: ; in, For photocurrent, This is the reverse saturation current of the diode. For series resistance, For parallel resistors, For diode ideality factor, Boltzmann's constant, Represented by natural constant An exponential function with base 0; the current is obtained by solving the above formula. With voltage The correspondence is used to calculate the physical prediction power. : .

[0008] Optionally, the parallel feature extraction dual-branch includes a one-dimensional convolutional neural network branch and a bidirectional long short-term memory network branch, which respectively extract local features and temporal features from the input data features; The feature fusion layer concatenates local features and temporal features along the feature channel dimension to generate a comprehensive feature sequence. The dual attention mechanism layer receives the comprehensive feature sequence, which is then passed through a concatenated time attention module and feature attention module to generate the final feature vector. The fully connected layer maps the final feature vector to data-driven predicted power.

[0009] Optionally, the time attention module first calculates the importance weight of each time step based on the comprehensive feature sequence, and then performs a weighted sum of the importance weight and the comprehensive feature sequence in the feature channel dimension to generate a time context vector. The feature attention module first uses a fully connected layer to learn the feature weight distribution of the temporal context vector, and then performs element-wise weighting on the temporal context vector based on the feature weight distribution to obtain the final feature vector.

[0010] Optionally, the step of calculating the weighting coefficients of the physical predicted power and the data-driven predicted power based on the prediction error statistics within a preset historical sliding window and then performing a weighted summation to obtain the photovoltaic power generation prediction result includes: Within a preset historical sliding window, the root mean square error of the physical mechanism model and the data-driven model are calculated as the prediction error statistics. The weighting coefficients for the physical prediction power and the data-driven prediction power at each time step are calculated using an inverse error proportional function. The mathematical representation of this process is as follows: ; ; in, This represents the mean of the prediction error statistics of the physical mechanism model. This represents the mean of the prediction error statistics of the data-driven model. Indicates the adjustment parameter. Indicates a time step. , Representing time steps Weighting coefficients for physical prediction power and data-driven prediction power; The photovoltaic power generation prediction result is obtained by weighting the physical predicted power and the data-driven predicted power based on their respective weighting coefficients. The mathematical representation is as follows: ; in, , , Representing time steps The photovoltaic power generation prediction results, physical prediction power, and data-driven prediction power.

[0011] Optionally, determining whether concept drift has occurred based on the cumulative error trend between the photovoltaic power generation prediction results and the actual power calculation includes: The cumulative error trend at each time point is calculated using the exponentially weighted moving average method: ; in, Indicates time The cumulative error trend; Indicates the forgetting factor; Indicates time; Indicates time The instantaneous absolute error, based on the current time step Photovoltaic power generation prediction results With actual power The calculation, mathematically represented as follows: ; in, Operators for calculating the norm of a vector; Build dynamic trigger threshold : ; in, , These are the mean and standard deviation of the historical instantaneous absolute error, respectively; Sensitivity coefficient; Set the number of judgment cycles When Cumulative error trend within consecutive prediction periods All meet At that time, a conceptual drift occurred, in which the number of judgment cycles... It is an integer greater than 1.

[0012] Optionally, the establishment of a typical extreme weather memory bank and the design of an update strategy include: Real-time calculation of instantaneous absolute error ,when The corresponding time Input data characteristics and actual power Constituting sample pairs Store in a typical extreme weather memory bank , The mean of historical instantaneous absolute errors serves as the admission threshold parameter for a typical extreme weather memory database. The preset empirical coefficient; The typical extreme weather memory bank Fixed capacity When typical extreme weather memory bank The number of sample pairs in the middle has reached a fixed capacity. Furthermore, when new sample pairs are added to the database, a first-in, first-out (FIFO) strategy is adopted to automatically discard the sample pair that has been stored the longest.

[0013] Optionally, the calculation of the normalized consistency score based on the feature weight distribution from the dual attention mechanism layer includes: The Shapley contribution vector of each input data feature at the same prediction time is calculated using the game theory-based SHAP algorithm. ; Calculate the feature weight distribution Contribution vector of Shapley values Normalized consistency score ,in Operators for calculating the norm of a vector; The calculation of the meteorological attribution ratio of the photovoltaic digital twin data recovery model includes: Extract the input data features from the repaired dataset to determine the moment when concept drift occurred as the baseline state. The data is fed into the trained photovoltaic digital twin data recovery model to generate random perturbations, and the generated perturbation samples constitute a virtual neighborhood sample set. ,in Indicates time; In the virtual neighborhood sample set Searching for data-driven prediction power that enables the output of data-driven models Closest to actual power The counterfactual sample is denoted as the optimal counterfactual sample. That is, to solve: ; in, This represents the optimization operator for finding counterfactual samples that minimize the modulus. This indicates that the data-driven model is based on counterfactual samples. The output data drives the predicted power; Obtain the optimal counterfactual sample Then, calculate the counterfactual offset vector. : ; Calculate meteorological attribution ratio : ; in, Represents the counterfactual offset vector The sub-vector corresponding to the meteorological feature dimension. The perturbation norm of the meteorological features, including irradiance. Ambient temperature Wind speed .

[0014] Optionally, the incremental learning optimization and update of the photovoltaic power generation prediction model based on a typical extreme weather memory bank, combined with the attribution diagnosis results, includes: Constructing a hybrid loss function based on memory playback : ; in, These are the parameters for the photovoltaic power generation prediction model; This is the balance coefficient; The photovoltaic power generation prediction model is based on the latest real-time data stream. The loss is calculated as follows: ; The latest real-time data stream To determine the moment of concept drift, real-time photovoltaic power plant operation data within a preset detection period is collected. A trained photovoltaic digital twin data recovery model generates repair data, which, combined with corresponding meteorological characteristics and actual power output as labels, forms a repair sample set. The number of samples in this repair sample set. This refers to the samples in the restoration sample set, namely the restoration data and the corresponding meteorological characteristics. To and The corresponding actual power, The sample number in this repair sample set; It is a photovoltaic power generation prediction model in the memory bank of typical extreme weather. The loss is calculated as follows: ; in, A typical extreme weather memory bank Medium sample size A typical extreme weather memory bank The samples in the data, i.e., the features of the input data, A typical extreme weather memory bank The number of samples in A typical extreme weather memory bank The sample number in To and The corresponding actual power; Gradient descent is used to transform the memory-replay-based hybrid loss function. Gradient backpropagation is used to optimize the photovoltaic power generation prediction model, including: if and This increases the balance coefficient. Otherwise, reduce the balance coefficient. ; For data-driven models, update the weights of the parallel feature extraction dual-branch and dual-attention mechanism layers, and adjust the normalized consistency score. Then, an additional regularization loss is applied to the dual attention mechanism layer, calculated as follows: ; in, Indicates the regularization loss. The preset regularization penalty coefficient, Feature weight distribution The dimensional components, Shapley value contribution vector at the same prediction time The dimensional components, This indicates the number of feature dimensions in the input data. For physical mechanism models, if the meteorological attribution ratio If so, its key parameters should be recalibrated.

[0015] By employing the above technical solution, the present invention provides an interpretable prediction method for photovoltaic power generation based on self-evolving digital twins, which has at least the following beneficial effects: (1) This invention introduces a physical constraint-based conditional diffusion model for high-fidelity data repair. The repaired data generated is more stable, diverse and strictly conforms to the physical laws of photovoltaics compared with the traditional method based on Generative Adversarial Network (GAN), thus laying a better data foundation for downstream prediction. (2) The present invention adopts a dual-modal hybrid architecture that deeply integrates physical mechanism and data-driven approach, which takes into account the interpretability of physical model and the strong fitting ability of deep learning model to complex nonlinear features, and shows superior robustness under variable weather conditions. (3) This invention achieves logical self-examination by introducing a causal interpretable mechanism. The counterfactual reasoning engine can quantify the marginal contribution of environmental changes to the prediction results, effectively distinguish between sensor data drift and equipment performance degradation, and solve the pain point that traditional photovoltaic power generation prediction methods cannot explain "why it is wrong". At the same time, the cross-validation of multimodal interpretation further improves the transparency and security of decision-making under complex and extreme weather conditions. (4) The present invention designs a unique closed-loop self-evolution mechanism that can sense changes in the environment and equipment status in real time and effectively overcome concept drift through incremental learning, thereby adaptively maintaining high prediction accuracy throughout the entire task cycle. Attached Figure Description

[0016] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings: Figure 1 This is a schematic diagram of a large grid-connected photovoltaic power station structure in an embodiment of the present invention; Figure 2 This is a flowchart of an interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to the present invention. Figure 3 This is a schematic diagram illustrating the data recovery principle of the physical constraint-based conditional diffusion model in this embodiment of the present invention; Figure 4 This is a schematic diagram of the physical mechanism model in the hybrid prediction model of this invention. Figure 5 This is a schematic diagram of the data-driven model in the hybrid prediction model of this invention. Figure 6 This is a flowchart illustrating the closed-loop online evolution mechanism and error-triggered update process in an embodiment of the present invention. Detailed Implementation

[0017] To make the above-mentioned objects, features, and advantages of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments. This will allow for a full understanding of how the present application uses technical means to solve technical problems and achieve technical effects, and to facilitate its implementation.

[0018] Those skilled in the art will understand that all or part of the steps in the implementation of the methods of the embodiments can be implemented by a program instructing related hardware. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Moreover, this application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0019] Please refer to Figures 1-6 This illustration demonstrates a specific implementation of this embodiment. This embodiment recovers historical operating data of a photovoltaic power station by constructing a conditional diffusion model based on physical constraints; it generates physical predicted power by constructing a physical mechanism model; it constructs a data-driven model, combining convolutional neural networks and bidirectional long short-term memory networks for feature extraction, introducing a dual attention mechanism layer for attention weighting, and outputting data-driven predicted power; it generates photovoltaic power generation prediction results by weighted fusion based on prediction error statistics; it establishes a memory bank of typical extreme weather events, performs attribution diagnosis, and optimizes and updates the model through targeted incremental learning, achieving continuous closed-loop self-evolution of the model; it effectively solves the pain points of traditional photovoltaic prediction methods, such as poor data quality, unexplainable black-box models, and inability to accurately identify component aging trends, while significantly improving prediction accuracy, logical transparency, and operational robustness.

[0020] This embodiment proposes a specific application scenario for an interpretable prediction method for photovoltaic power generation based on self-evolving digital twins, namely a large-scale grid-connected photovoltaic power station located in Northwest China, the structural schematic diagram of which is shown below. Figure 1 As shown, the power station consists of three parts: a physical entity layer, a data acquisition and transmission layer, and a digital twin platform layer. The physical entity layer includes the photovoltaic array area and the electrical chain, where the photovoltaic array area contains the following physical equipment: Monocrystalline silicon module group: Composed of more than 120,000 monocrystalline silicon photovoltaic modules, divided into multiple power generation units, responsible for converting solar energy into DC power.

[0021] Weather station: Deployed within the photovoltaic array area to collect real-time environmental data and convert it into meteorological characteristics, including at least irradiance, ambient temperature, and wind speed.

[0022] The electrical chain refers to the complete electrical circuit connecting the above-mentioned electrical equipment (components-combiner boxes-inverters-substations) to ensure the continuous transmission of electrical energy, and includes the following equipment: String inverter: Each power generation unit is connected to a corresponding string inverter to complete the DC to AC conversion and collect the current, voltage and power data of the string level in real time.

[0023] Combiner box: It connects and aggregates the DC outputs of multiple photovoltaic module strings in parallel, reduces the number of DC side cables, and transmits the aggregated DC power to the inverter.

[0024] Box-type transformer: It steps up the low-voltage AC power output from the inverter to a medium-voltage level, which is convenient for long-distance transmission.

[0025] Step-up substation / main transformer: It further boosts the voltage of the photovoltaic array to the grid voltage level and serves as the connection hub between the power station and the external power grid.

[0026] Grid connection point: The physical connection point where the photovoltaic power station injects electricity into the public power grid, and it is also a key location for power generation metering and grid connection assessment.

[0027] Power grid: A public power network that receives and distributes the electricity generated by photovoltaic power plants.

[0028] The data acquisition and transmission layer is the middleware layer connecting physical devices and the upper-level platform. It includes data acquisition units and communication devices, as follows: SCADA system / monitoring host: This is the monitoring and data acquisition system, serving as the data hub of the entire power plant. Connected to various inverters, combiner boxes, weather stations, and step-up substation equipment via a communication network, it is responsible for collecting, aggregating, and storing all station operational data, including electrical quantity data and environmental monitoring data. The actual power generation monitored by the SCADA system will serve as the benchmark signal for subsequent model error monitoring and closed-loop evolution.

[0029] Data communication link: including various communication methods such as optical fiber, serial communication, and wireless transmission, responsible for transmitting the real-time data collected by the SCADA system to the digital twin platform.

[0030] The digital twin platform layer includes: Digital twin cloud platform: A computing platform deployed in the cloud or local data center that receives real-time data uploaded from the site and runs the core algorithm of this invention.

[0031] Twin computing server: A server cluster that provides computing power support for the digital twin platform and is responsible for executing computational tasks such as data repair, hybrid prediction, and self-evolution algorithms.

[0032] The core algorithm logic module, a collection of algorithms deployed on a twin computing server, is the core implementation carrier of the method of this invention. This core algorithm logic module further comprises three sub-modules: The data repair module, based on the constructed photovoltaic digital twin data recovery model, performs high-fidelity repair on missing and outlier values ​​in the collected historical operating data of the photovoltaic power plant. The hybrid prediction module implements a hybrid prediction architecture combining a physical mechanism model and a data-driven model, outputting the final photovoltaic power generation prediction result. The self-evolution center implements concept drift monitoring, attribution diagnosis, and incremental learning update mechanisms, driving the model's continuous closed-loop self-evolution.

[0033] In actual operation, historical data often suffers from missing, anomalies, and noise due to occasional sensor malfunctions, communication interference, and adverse environmental conditions such as sandstorms and snow accumulation. Simultaneously, the performance of photovoltaic modules slowly degrades over time, and local meteorological patterns exhibit significant seasonal and interannual variations, leading to continuous conceptual drift in data distribution. These data quality issues and the dynamic evolution of the system state are the core challenges that the method described in this invention aims to address.

[0034] To address the aforementioned challenges, this invention proposes an interpretable prediction method for photovoltaic power generation based on self-evolving digital twins, the process of which is as follows: Figure 2 As shown, the method specifically includes the following steps: Step 1: Construct a photovoltaic digital twin data recovery model.

[0035] This step involves data acquisition and mask construction, building a conditional diffusion model based on physical constraints to achieve data repair. The aim is to use physical laws to constrain the artificial intelligence model and recover a high-quality, complete data sequence from the original acquired data containing missing or abnormal data.

[0036] Step 1-1: Construct a training architecture for a conditional diffusion model based on physical constraints.

[0037] First, collect historical operating data of the photovoltaic power station. It includes key features such as photovoltaic power, irradiance, and temperature. To address the problems of unstable training and the tendency to generate data that violates physical common sense in traditional generative adversarial networks (GANs), this invention introduces a physical consistency constraint term into the training loss function of the conditional diffusion model.

[0038] Define the total loss function for training the photovoltaic digital twin data recovery model. as follows: ; in, It serves as the basic denoising error loss for the conditional diffusion model, used to ensure the authenticity of the statistical distribution of the generated data; Standard Gaussian noise representing the forward diffusion process in the conditional diffusion model. This represents the noise component predicted by the inverse denoising process of the conditional diffusion model. The conditional input states representing the forward diffusion process of the conditional diffusion model are the historical operating data of the photovoltaic power plant. via binary mask matrix The processed result, the processing procedure mathematically represented as follows: , Indicates a time step; This indicates the forward diffusion process in the conditional diffusion model at time step [missing information]. The noise-added state; Physical constraint weighting coefficients (preferred in this embodiment) ); The physical constraint loss is based on the principle of utilizing the one-sided suppression property of the ReLU function to construct a "physical energy boundary," calculated as follows: ; in, Power predictions generated for a photovoltaic digital twin data recovery model; The theoretical power limit calculated based on the physical mechanism model constructed in step 2-1 is the maximum power that the component can theoretically emit under this irradiance and ambient temperature. This is a nighttime indicator function, determined based on the solar altitude angle or irradiance, when it is nighttime. If the model generates non-zero power at this time ( Those who violate this rule will be severely punished. Represents the ReLU activation function; This represents the square of the L2 norm.

[0039] Steps 1-2: Perform mask-based deterministic accelerated sampling (Inference) In the model inference stage, i.e. the data repair stage, in order to meet the real-time (second-level response) requirements of photovoltaic power prediction, this invention abandons the random sampling method of the traditional DDPM (Denoising Diffusion Probability Model) which requires thousands of iterations, and adopts the deterministic accelerated sampling strategy of the Denoising Diffusion Implicit Model (DDIM).

[0040] Set the jump sequence (For example, compressing 1000 steps into 50 steps), in the reverse denoising process of the conditional diffusion model, the following formula is used in conjunction with the binary mask matrix. Implement strong physical constraints and calculate the denoised intermediate data state of the previous time step. : ; in, Indicates a time step. Indicates the number of reverse generation steps; The binary mask matrix is ​​constructed based on valid observations. The corresponding position of the valid observation in the real-time running data is 1, and the corresponding position of the missing value is 0. Historical operating data of photovoltaic power plants These are the noise scheduling parameters for the forward diffusion process in the pre-defined conditional diffusion model. Unconstrained sampled values ​​generated for the diffusion model. This indicates element-wise multiplication.

[0041] The intermediate data status This refers to the historical operating data (photovoltaic power) of a photovoltaic power station at different time steps during the iterative process of reverse denoising. The distribution state is determined. By iteratively executing the deterministic accelerated sampling strategy of the above formula, the data state is gradually decoupled from the initial noise and converges to the physical truth. When the reverse generation steps are completed, the final output data state is used as the repair data, which is then combined with the synchronously collected meteorological features to construct the repair dataset.

[0042] In the above formula, The term "observation injection" refers to directly calculating the value of a given time point within a preset noise scheduling parameter. Under the theoretical state, real information is forced to be injected into the generation process to prevent the model from "tampering" with existing data; The term "missing value generation" means that for missing time points, unconstrained sampled values ​​are used. Fill in the gaps.

[0043] The repaired dataset output in this step retains the authenticity of the original data while effectively generating and repairing the missing parts under the constraints of physical laws.

[0044] The data recovery principle of the conditional diffusion model based on physical constraints in this embodiment can be referred to... Figure 3 The figure shows the parameter sequence of the forward diffusion process. It depicts the evolution path of data from physical space to noise space: where This refers to the initial physical data state, which includes key characteristics such as photovoltaic power, irradiance, and temperature. (in ) for the first Each time step represents the intermediate noise-added state after Gaussian noise is injected into the original data according to preset noise scheduling parameters. This represents the final limiting state where the features have been completely transformed into standard Gaussian noise. This sequence defines the benchmark for model learning, enabling the model to accurately reverse noise interference and recover high-quality repaired data during the reverse denoising process. For the raw data (including missing / outliers) collected from photovoltaic power plants, a binary mask matrix is ​​generated based on the valid observations. ,in This indicates that the value at this location is missing or outlier. This indicates that the location is an observation (a valid observation), represented by a binary mask matrix. Historical operational data Constructing conditional inputs by performing element-wise multiplication. The data is input into the physical constraint-based conditional diffusion model constructed in this invention. In the conditional diffusion model, a forward diffusion process (i.e., noise addition process) and a backward denoising process (i.e., generation process) are performed sequentially. A physical constraint loss is constructed, and the gradient is backpropagated to train, update, and optimize the conditional diffusion model. The trained conditional diffusion model generates high-quality repair data that balances statistical rationality and physical interpretability. Combined with synchronously collected meteorological features, a repair dataset is formed, which serves as the input to the hybrid prediction model in step 2 for photovoltaic power prediction.

[0045] This invention introduces a physical constraint-based conditional diffusion model for high-fidelity data repair. The repaired data generated in this way is more stable, diverse, and strictly conforms to the physical laws of photovoltaics compared with traditional methods based on generative adversarial networks (GANs), thus laying a higher quality data foundation for downstream prediction.

[0046] Step 2: Construct a hybrid prediction model that integrates physics and data-driven approaches.

[0047] The high-quality repaired dataset from step 1 and the numerical weather prediction (NWP) data are used as inputs and fed into a hybrid parallel prediction model consisting of a physical mechanism model and a data-driven model for parallel computation. Then, after feature fusion and attention mechanisms, and then through a fully connected layer, the data prediction power is finally output.

[0048] Step 2-1: Construct a physical mechanism model of a single diode.

[0049] This model is based on the single-diode equivalent circuit of a photovoltaic cell (e.g., Figure 4 The system (as shown) is designed to provide an interpretable forecasting benchmark protected by the laws of physics, ensuring that forecasts do not deviate drastically under extreme weather conditions.

[0050] First, implement refined temperature correction for the photovoltaic modules. This takes into account the ambient temperature. Irradiance and wind speed The overall impact on the thermal characteristics of photovoltaic modules is considered, and the actual operating temperature of the photovoltaic modules is calculated using a heat balance formula. : ; in The basic heat transfer coefficient (or static heat dissipation coefficient) of a photovoltaic module reflects its ability to dissipate heat to the environment through radiation and natural convection at zero wind speed. The wind speed gain heat transfer coefficient (or convection cooling coefficient) of a photovoltaic module reflects the contribution of wind speed to the forced convection cooling effect of the photovoltaic module.

[0051] Secondly, considering the actual operating temperature of photovoltaic modules A photoelectric conversion model is constructed using a single diode equivalent circuit, and the output current is... Satisfy the following equation: ; in, For photocurrent, This is the reverse saturation current of the diode. This is the series resistance (characterizing line loss). This is a parallel resistor (characterizing leakage current). For diode ideality factor, Boltzmann's constant, Represented by natural constant An exponential function with base 0; This embodiment uses the Newton-Raphson method to numerically iterate and solve the above equation to obtain the current. With voltage The correspondence is used to calculate the output physical prediction power. : .

[0052] Step 2-2: Construct the CNN-BiLSTM network data-driven model.

[0053] The data-driven model constructed in this embodiment is as follows: Figure 5 As shown, using the repaired time series data as input, a parallel dual-branch architecture is adopted, combined with a time and feature dual attention mechanism, aiming to accurately capture the complex transient mapping relationship between meteorology and power, and provide a visual explanation of the decision-making basis.

[0054] (1) Parallel feature extraction layer The input data features obtained in step 1 (in For the real number space, This indicates the length of the time step in the historical sliding window. (This indicates the number of feature dimensions of the input data.) Simultaneously input the following two branches: The CNN branch (one-dimensional convolutional neural network branch) implements local morphological feature extraction: a 3-layer one-dimensional convolutional network (Conv1D) is used. The kernel size of each layer is set to 3, the activation function is ReLU, and max pooling (MaxPooling1D) is added between layers to extract higher-order morphological features. To address the time dimension reduction issue caused by pooling, transposed convolution or linear interpolation is used at the end of this branch to restore the time dimension. Obtain the aligned local features As the output of a branch of a one-dimensional convolutional neural network. Feature dimension of local features. Typically, the value can be selected from 32 to 128; in this embodiment, it is set to 64.

[0055] The BiLSTM branch (Bidirectional Long Short-Term Memory branch) implements long and short-term dependency extraction: it employs a two-layer bidirectional long short-term memory network with 64 hidden units. This branch outputs the hidden state sequence at each time step. As a temporal feature, the feature dimension of the temporal feature .

[0056] (2) Feature fusion layer The outputs of the two branches are concatenated along the feature channel dimension to form a comprehensive feature sequence containing both local and global information. : ; in, This indicates a splicing operation.

[0057] (3) Dual Attention Layer Temporal attention mechanism and feature attention mechanism are applied sequentially in a cascade manner.

[0058] Temporal Attention Module: Based on comprehensive feature sequences Calculate each time step Importance weight and combined with the comprehensive feature sequence A time context vector is generated by weighted summation along the feature channel dimension. The mathematical representation of this process is as follows: ; ; ; in, Indicates time step The attention score is used to measure the degree of influence of that historical moment on the current prediction task; This represents the learnable weight vector of the temporal attention module. This is a transpose operation; , These represent the learnable weight matrix and bias term of the temporal attention module, respectively. Represents the hyperbolic tangent function; Indicates time step Attention score This indicates the length of the time step in the historical sliding window. Represented by natural constant An exponential function with base 0; Represents the time steps in the comprehensive feature sequence Its characteristics.

[0059] In the above formula, and All of these represent indices in the time series, and their values ​​are all within the set of integers. .in, This refers to the target time step in which the attention weights are currently being calculated, while As a summation symbol The traversal index below represents all historical moments within the window that participated in the weight normalization calculation. In actual calculations, for each specific target time step... traversing variables All will be taken arrive This allows for the global normalization of all values ​​of the sequence context information.

[0060] Physical meaning: Importance weight Visualized heatmaps can help operations and maintenance personnel identify the historical moments that have the greatest impact on current forecasts (such as irradiation mutations 15 minutes ago).

[0061] Feature Attention module: designed to calculate the importance weights of different feature channels (corresponding to the power of the original input, ambient temperature, irradiance, and extracted high-dimensional features).

[0062] First, the temporal context vector is learned using a fully connected layer. Feature weight distribution : ; ; in, express, express, Use the Sigmoid activation function; , These represent the learnable weight matrix and bias term of the feature attention module, respectively; Then, using this feature weight distribution For time context vectors Element-wise product is performed to obtain the final feature vector. : ; Physical meaning: Feature weight distribution The visual bar charts can intuitively show whether the data-driven model relies more on "historical power" or "real-time irradiance", thus helping to determine the validity of sensor data.

[0063] (4) Predicted output and interpretability The final feature vector The input to the fully connected (dense) layer is mapped to a single data-driven prediction power. : ; in, This represents the mapping operation of fully connected layers in a neural network.

[0064] The interpretability of the model is reflected in the importance weights. It can be plotted as a heatmap, visually showing which historical moments contribute the most to the current prediction; feature weight distribution. The mapping of the corresponding channels can be parsed back to the original input feature dimensions, which can be plotted as a bar chart to show the degree of dependence of the model on each feature (such as the current irradiance, historical power change trend, etc.) when making decisions.

[0065] This invention adopts a dual-modal hybrid architecture that deeply integrates physical mechanisms and data-driven approaches, taking into account both the interpretability of the physical model and the strong fitting ability of the deep learning model to complex nonlinear features, and exhibits superior robustness under variable weather conditions.

[0066] Step 3: Perform adaptive weighted fusion based on historical instantaneous absolute errors.

[0067] To ensure the robustness of the dynamic fusion of the physical mechanism model and the accuracy of the data-driven model, this step designs a dynamic weight allocation strategy based on recent performance, calculates adaptive weighted fusion dynamic weights, and guides the fusion of the prediction results of the two models.

[0068] Set the length of the history sliding window (For example, the past 7 days), within this window, the root mean square error (RMSE) of the physical mechanism model and the data-driven model are calculated as the prediction error statistics respectively; The weighting coefficients for the physical prediction power and the data-driven prediction power at each time step are calculated using an inverse error proportional function. The mathematical representation of this process is as follows: ; ; in, This represents the mean of the prediction error statistics of the physical mechanism model within a preset historical sliding window. This represents the mean of the prediction error statistics of the data-driven model within a preset historical sliding window; Indicates the adjustment parameter (recommended value). This is used to slightly adjust the balance between the two models; Indicates a time step. , Representing time steps Weighting coefficients for physical prediction power and data-driven prediction power; The adaptability of this strategy lies in its ability to address errors caused by parameter drift in the physical mechanism model. When it increases, its weight It will automatically decrease; conversely, when extreme weather causes the data-driven model to fail, it will automatically tilt towards the physical mechanism model.

[0069] The photovoltaic power generation prediction result is obtained by weighting and summing the physical predicted power and the data-driven predicted power based on their respective weighting coefficients: ; in, , , Representing time steps The photovoltaic power generation prediction results, physical prediction power, and data-driven prediction power.

[0070] Step 4: Run the closed-loop online evolution mechanism.

[0071] This step aims to construct an intelligent closed loop of "monitoring-diagnosis-attribution-directed evolution," enabling the perception of performance degradation and more accurately diagnosing its root causes. This allows for precise self-evolution by addressing the specific "symptom" (external weather fluctuations or internal equipment aging) through targeted model parameter updates. The closed-loop online evolution mechanism and error-triggered update process for this step can be found in [reference needed]. Figure 6 .

[0072] Step 4-1: Concept drift perception and triggering.

[0073] The Exponentially Weighted Moving Average (EWMA) method is used to track the statistical characteristics of the prediction error in real time, monitor the error in real time, and calculate the cumulative error trend at each time point. ; in, Indicates time The cumulative error trend (i.e., cumulative trend); The forgetting factor is represented (in this example, it is set to 0.9, indicating a greater focus on recent trends). Representing the forgetting factor The power is used to correct for deviations in the cumulative error trend. Indicates time; Indicates time The instantaneous absolute error, based on the current time step Predicted power (photovoltaic power generation prediction results) ) and actual power calculate: Actual power The actual power data is acquired in real time by the Supervisory Control and Data Acquisition (SCADA) system within the photovoltaic power plant, rather than relying solely on offline datasets. This actual power data serves as a benchmark signal for error monitoring during model operation, and is compared with the corresponding input data features. Together they form sample pairs, which are used for dynamic screening and storage of typical extreme weather memory databases.

[0074] Build dynamic trigger threshold : ; in, , These are the mean and standard deviation of the historical instantaneous absolute error, respectively; The sensitivity coefficient is typically set to 3. The historical instantaneous absolute error refers to the sequence of instantaneous absolute errors generated by the model within a preset historical stable operating period before the current monitoring period; the system establishes the benchmark boundary of prediction performance by statistically analyzing the error distribution within this fixed historical window.

[0075] To effectively filter out transient noise interference and avoid false triggering, this invention employs a continuous triggering judgment mechanism.

[0076] Set the number of judgment cycles When The trend of cumulative error within a series of consecutive prediction periods (one prediction period is one inference process of the model). All meet the trigger conditions At that time, a concept drift was determined, triggering an online update signal. The number of judgment cycles is as follows. The integer is greater than 1. Determine the number of cycles. The configuration can be adjusted according to actual stability requirements; in this embodiment, it is set as follows: If no concept drift occurs, proceed to the next round of prediction.

[0077] Step 4-2: Multimodal causal diagnosis and root cause attribution.

[0078] A bimodal causal diagnostic module is constructed. Once an online update is triggered, it immediately enters the attribution diagnostic mode and performs the following two parallel attribution analyses to achieve online evolution of the model based on memory playback and joint parameter fine-tuning: (1) Multimodal interpretation consistency verification (internal logic health diagnosis of the model) This step aims to verify whether the model's "sayings" (attention weights) are consistent with its "doings" (actual contributions).

[0079] Signal extraction: Extract the feature weight distribution from the feature attention module of the data-driven model described in step 2-2. Simultaneously, the game-theory-based SHAP (SHapley Additive exPlanations) algorithm is used to calculate the Shapley value contribution vector of each input data feature at the same prediction time. .

[0080] Consistency quantification: Calculate the normalized consistency score between the two. To quantify the degree of mismatch in internal logic: ; in Operators for calculating the norm of a vector.

[0081] Set consistency score threshold (In this embodiment, it is set that...) If the normalized consistency score If the data-driven model's internal attention allocation mechanism deviates significantly from the actual contribution of the features, it indicates that feature fusion or the attention mechanism may have failed. This signal serves as a leading indicator for prioritizing and fine-tuning the relevant network layers.

[0082] (2) Physical constraint counterfactual reasoning (physical root cause diagnosis of prediction bias) This step aims to answer, within the framework of physical laws, "at least what compliance features need to be changed to correct prediction bias," thereby distinguishing whether the bias originates from the environment or the equipment.

[0083] Constructing a counterfactual search space: using the input data features at the moment when the current prediction deviation exceeds the limit (i.e., the moment when concept drift is judged to have occurred) as the baseline state. Using the conditional diffusion model trained in step 1 with physical constraints, while satisfying the physical constraint loss... Under constraints, around the reference state Controlled random perturbation generation, the generated perturbation samples constitute a physically compliant virtual neighborhood sample set. The baseline state It is used as the logical starting point and physical center point for perturbation generation to limit the search boundary of virtual samples and ensure the local relevance of the generated results.

[0084] Perform goal-oriented optimization search: on a virtual neighborhood sample set Searching for data-driven prediction power that enables the output of data-driven models Closest to actual power The counterfactual sample is denoted as the optimal counterfactual sample. That is, to solve: ; in, This represents an optimization operator for finding counterfactual samples that minimize the modulus (or absolute value); This indicates that the data-driven model is based on virtual neighborhood samples. The output data drives the predicted power.

[0085] The counterfactual search process targets data-driven power prediction. The purpose of the calculation is to isolate the fixed linearity error of the physical mechanism model branches and approximate the actual power by driving the output of the branches with independent constraint data. This allows for the accurate extraction of the mapping offset features of the data-driven model branches in the current environment; the resulting counterfactual offset vector It can accurately reflect the degree of mismatch between nonlinear prediction logic and physical reality, providing isolated diagnostic evidence for subsequent judgment of performance degradation caused by meteorological fluctuations or equipment aging.

[0086] Obtain the optimal counterfactual sample Then, calculate the counterfactual offset vector. : ; Through analysis The disturbance amplitudes of each component are attributed, and the meteorological attribution ratio is calculated. : ; in, Represents the counterfactual offset vector The sub-vector corresponding to the meteorological feature dimension. Operators for calculating the norm of a vector. The perturbation norm of the meteorological features, including irradiance. Ambient temperature Wind speed .

[0087] To make a summary decision, the root cause attribution rules are as follows: Set meteorological attribution threshold (In this embodiment, it is set that...) If the meteorological attribution ratio If the current forecast bias is attributed primarily to "external weather fluctuations," then the counterfactual offset vector is considered to be the main cause. If the implicit characteristics of the equipment state, such as the theoretical efficiency of the component or the series resistance, are significantly disturbed, then the judgment bias is mainly attributed to the performance degradation of the internal equipment ("internal equipment aging").

[0088] Step 4-3: Diagnosis-driven targeted incremental learning and joint optimization.

[0089] Based on the accurate attribution diagnosis results from step 4-2, a targeted, forgetting-resistant incremental learning process is initiated, and a parameter-oriented update strategy is formulated.

[0090] (1) Construction and updating of typical extreme weather memory bank.

[0091] To prevent the model from forgetting old knowledge (such as summer patterns) when learning new data (such as winter patterns), i.e., the catastrophic forgetting problem, this invention establishes a typical extreme weather memory buffer to store high-value historical samples.

[0092] Typical extreme weather memory bank The build and update strategy is as follows: Sample admission mechanism: To capture key patterns that lead to prediction difficulties, a typical extreme weather memory bank continuously filters high-value samples. This invention employs an admission strategy based on a dynamic threshold for prediction error: Real-time calculation of instantaneous absolute error ,when When the current moment is determined to be a typical scenario with learning value, the corresponding input data features are... and actual power Constituting sample pairs Store in a typical extreme weather memory bank ,in Indicates time, The mean of historical instantaneous absolute errors serves as the admission threshold parameter for a typical extreme weather memory database. The preset empirical coefficient (in this embodiment, it is taken as...) ).

[0093] Capacity and Update Management: Typical Extreme Weather Memory Bank Fixed capacity (In this embodiment, the value is set to 1000), when the typical extreme weather memory bank The number of sample pairs in the middle has reached a fixed capacity. Furthermore, when new sample pairs are added to the database, a first-in, first-out (FIFO) strategy is adopted to ensure that the inventory of samples reflects the latest state distribution and to automatically discard the sample pairs that have been stored the longest.

[0094] Online learning sampling: performing online incremental learning and calculating a hybrid loss function based on memory playback. At that time, from A small batch of samples is uniformly and randomly sampled to participate in gradient calculation, thereby maintaining the model's memory of historical key patterns and effectively mitigating catastrophic forgetting.

[0095] Adaptive updates to the memory: As the model is continuously adjusted, the admission threshold parameter... This also leads to a recalculation, making the typical extreme weather memory database more comprehensive. The sample selection criteria can adapt to the evolution of the model, enabling the co-evolution of the memory bank and the model.

[0096] (2) Constructing a diagnostic-oriented hybrid loss function Constructing a hybrid loss function based on Experience Replay : ; in, These are the parameters for the photovoltaic power generation prediction model; This is the balance coefficient; The photovoltaic power generation prediction model is based on the latest real-time data stream. The loss is used to adapt to the new environment, and the calculation method is as follows: ; The latest real-time data stream To determine the moment of concept drift, real-time photovoltaic power plant operation data within a preset detection period is collected. A trained photovoltaic digital twin data recovery model generates repaired data, which is then labeled with corresponding meteorological characteristics and actual power output. The constructed repair sample set, The number of samples in this repair sample set. This refers to the samples in the restoration sample set, namely the restoration data and the corresponding meteorological characteristics. The sample number in this repair sample set; It is a photovoltaic power generation prediction model in the memory bank of typical extreme weather. The loss above, used to maintain historical capabilities, is calculated as follows: ; in, A typical extreme weather memory bank Medium sample size A typical extreme weather memory bank The samples in the data, i.e., the features of the input data, A typical extreme weather memory bank The number of samples in A typical extreme weather memory bank The sample number in To and The corresponding actual power; Balance coefficient Control the rate of absorption of new knowledge and the strength of retention of old knowledge, and dynamically adjust based on attribution diagnosis results: If attributed to meteorological fluctuations (meteorological attribution ratio) And normalized consistency score If the prediction bias is determined to be entirely due to normal migration of the external meteorological environment, and the model can maintain high-quality decision consistency, then the prediction accuracy will improve. (e.g., set to 0.8), increase the processing speed of the latest real-time data stream. The learning weights enable the model to quickly capture the latest meteorological evolution patterns and achieve real-time self-evolution of prediction accuracy; If attributed to equipment aging (weather attribution ratio) ) or model logic mismatch (normalized consistency score) ), then reduce (If set to 0.5), the emphasis is on learning about historical steady states and physical laws, specifically: like and The prediction bias is determined to be caused by a combination of internal equipment performance degradation and model logic mismatch; in this case, the balance coefficient should be reduced. By increasing The proportion of [something] guides the model to regress to historical steady state and physical laws, and suppresses the model from making incorrect fits to new data streams containing logical biases; like and The determination is that although there are significant external weather fluctuations, the model's current decision-making logic is no longer consistent with them; to prevent parameter oscillations in complex environments, the balance coefficient should be reduced. Utilizing typical extreme weather memory banks The samples impose robustness constraints on the model; like and The judgment model logic is generally consistent, but the main reason for the deviation is equipment aging or non-meteorological internal faults; in this case, the balance coefficient should be reduced. This allows the model to learn from historical benchmark performance and avoids misidentifying the output characteristics of equipment degradation as normal evolutionary patterns.

[0097] (3) Perform joint optimization and parameter fine-tuning.

[0098] Gradient descent is used to transform the memory-replay-based hybrid loss function. Gradient backpropagation is used to perform joint optimization: For data-driven models: Update the weights of the parallel feature extraction dual-branch and dual-attention mechanism layers. If the normalized consistency score... Then, an additional regularization loss is applied to the dual attention mechanism layer to correct its focusing logic. The calculation method is as follows: ; in, Indicates the regularization loss. The preset regularization penalty coefficient, Feature weight distribution The dimensional components, Shapley value contribution vector at the same prediction time The dimensional components, This represents the number of feature dimensions in the input data. Regularization loss. It is calculated between the internal feature attention weights and the external physical contribution components, aiming to force the model to calibrate its attention allocation.

[0099] For the physical mechanism model: if attributed to equipment aging (weather attribution ratio) If so, its key parameters (such as heat transfer coefficient) will be activated simultaneously. Series resistor Calibration procedures (etc.).

[0100] Data recovery model: Through gradient coupling, its generation parameters are fine-tuned to better reflect the current (especially after aging) state characteristics when repairing data. Specifically: based on... The gradient generated in the prediction stage is backpropagated to the photovoltaic digital twin data recovery model described in step 1; the prediction accuracy is used as a monitoring signal using the chain rule, so that the update direction of the photovoltaic digital twin data recovery model is simultaneously affected by the basic denoising error loss of the conditional diffusion model and... The joint constraints enable end-to-end dynamic coupling between the data repair logic and the prediction task. Specifically, the generated parameters refer to the noise components predicted by the reverse denoising process of the conditional diffusion model in step 1. The internal connection weights, and the historical operating data of the photovoltaic power plant. With binary mask matrix Feature embedding layer parameters mapped to a high-dimensional latent space.

[0101] Through the closed loop of "perception (step 4-1) → diagnosis (step 4-2) → directed evolution (step 4-3)" described above, the present invention achieves a leap from passive adaptation to active diagnosis and symptomatic self-healing, ensuring the sustainability of the prediction accuracy of the method of the present invention throughout the entire mission cycle.

[0102] This invention achieves logical self-examination by introducing a causal interpretability mechanism. The counterfactual reasoning engine can quantify the marginal contribution of environmental changes to the prediction results, effectively distinguishing between sensor data drift and equipment performance degradation, and solving the pain point of traditional photovoltaic power generation prediction methods being unable to explain "why it is wrong". At the same time, the cross-validation of multimodal interpretation further improves the transparency and security of decision-making under complex and extreme weather conditions. In addition, this invention designs a unique closed-loop self-evolutionary mechanism that can perceive changes in the environment and equipment status in real time, and effectively overcome concept drift through incremental learning, thereby adaptively maintaining high prediction accuracy throughout the entire mission cycle.

[0103] In the description of this specification, the references to terms such as "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., indicate that a specific feature, structure, material, or characteristic described in connection with that embodiment or example is included in at least one embodiment or example of this application. Furthermore, the specific features, structures, materials, or characteristics described may be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of those different embodiments or examples.

[0104] The logic and / or steps represented in the flowchart or otherwise described herein, for example, can be considered as a sequenced list of executable instructions for implementing logical functions, and can be embodied in any computer-readable medium for use by, or in conjunction with, an instruction execution system, apparatus or device (such as a computer-based system, a processor-included system or other system that can fetch and execute instructions from, an instruction execution system, apparatus or device).

[0105] The above embodiments provide a detailed description of the present invention. Specific examples have been used to illustrate the principles and implementation methods of the present invention. The descriptions of the above embodiments are only for the purpose of helping to understand the method and core ideas of the present invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of the present invention. Therefore, the content of this specification should not be construed as a limitation of the present invention.

Claims

1. A method for interpretable prediction of photovoltaic power generation based on self-evolving digital twins, characterized in that, include: Collect meteorological characteristics and historical operation data of photovoltaic power plants, and construct a binary mask matrix using the effective observation values ​​in the real-time operation data as physical constraints. Build and train a photovoltaic digital twin data recovery model to repair historical operation data. Combine meteorological characteristics to form input data features, and use the actual power in the historical operation data as labels to build a repair dataset. A physical mechanism model is constructed, and numerical weather prediction data is input into the physical mechanism model to output the physical predicted power; the key parameters of the physical mechanism model include at least the heat transfer coefficient and the series resistance. A data-driven model is constructed, which inputs the features of the input data into the data-driven model and outputs the predicted power. The data-driven model includes a parallel feature extraction dual-branch, a feature fusion layer, a dual attention mechanism layer, and a fully connected layer. The photovoltaic digital twin data recovery model, the physical mechanism model, and the data-driven model constitute a photovoltaic power generation prediction model. The weighting coefficients of physical predicted power and data-driven predicted power are calculated based on the prediction error statistics within a preset historical sliding window, and then weighted and summed to obtain the photovoltaic power generation prediction result. Based on the cumulative error trend between the photovoltaic power generation prediction results and the actual power calculation, it is determined whether concept drift has occurred; If conceptual drift occurs, a typical extreme weather memory bank is established and an update strategy is designed. A normalized consistency score is calculated based on the feature weight distribution from the dual-attention mechanism layer. Simultaneously, the meteorological attribution ratio of the photovoltaic digital twin data recovery model is calculated for attribution diagnosis. Based on the attribution diagnosis results and the typical extreme weather memory bank, the photovoltaic power generation prediction model is incrementally learned and optimized to achieve continuous closed-loop self-evolution of the photovoltaic power generation prediction model. The calculation of the normalized consistency score based on the feature weight distribution from the dual-attention mechanism layer includes: The Shapley contribution vector of each input data feature at the same prediction time is calculated using the game theory-based SHAP algorithm. ; Calculate the feature weight distribution Contribution vector of Shapley values Normalized consistency score ,in Operators for calculating the norm of a vector; The calculation of the meteorological attribution ratio of the photovoltaic digital twin data recovery model includes: Extract the input data features from the repaired dataset to determine the moment when concept drift occurred as the baseline state. The data is fed into the trained photovoltaic digital twin data recovery model to generate random perturbations, and the generated perturbation samples constitute a virtual neighborhood sample set. ,in Indicates time; In the virtual neighborhood sample set Searching for data-driven prediction power that enables the output of data-driven models Closest to actual power The counterfactual sample is denoted as the optimal counterfactual sample. That is, to solve: ; in, This represents the optimization operator for finding counterfactual samples that minimize the modulus. This indicates that the data-driven model is based on counterfactual samples. The output data drives the predicted power; Obtain the optimal counterfactual sample Then, calculate the counterfactual offset vector. : ; Calculate meteorological attribution ratio : ; in, Represents the counterfactual offset vector The sub-vector corresponding to the meteorological feature dimension. The perturbation norm of the meteorological features, including irradiance. Ambient temperature Wind speed .

2. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 1, characterized in that: The construction and training of the photovoltaic digital twin data recovery model to repair historical operational data includes: The photovoltaic digital twin data recovery model is a conditional diffusion model based on physical constraints; Define the total loss function for training the photovoltaic digital twin data recovery model. as follows: ; in, This is the basic denoising error loss for the conditional diffusion model. Standard Gaussian noise representing the forward diffusion process in the conditional diffusion model. This represents the noise component predicted by the inverse denoising process of the conditional diffusion model. The conditional input states representing the forward diffusion process of the conditional diffusion model are the historical operating data of the photovoltaic power plant. via binary mask matrix The processed result, the processing procedure mathematically represented as follows: , Indicates a time step; This indicates the forward diffusion process in the conditional diffusion model at time step [missing information]. The noise-added state; These are the physical constraint weighting coefficients; The physical constraint loss is calculated using the following formula: ; in, The power prediction values ​​generated for the photovoltaic digital twin data recovery model This is the theoretical upper limit of power calculated based on the physical mechanism model. This is a nighttime indicator function, used when it is nighttime. ; Represents the ReLU activation function; Represents the square of the L2 norm; In the reverse denoising process of the conditional diffusion model, a deterministic accelerated sampling strategy based on the implicit denoising diffusion model is adopted, using skip-step subsequences. Perform reverse generation; use the following formula combined with the binary mask matrix. Calculate the denoised intermediate data state of the previous time step. : ; in, Indicates a time step. Indicates the number of reverse generation steps; The binary mask matrix is ​​constructed based on valid observations. In the real-time running data, the corresponding position of a valid observation in the binary mask matrix is ​​1, and the corresponding position of a missing value in the binary mask matrix is ​​0; the intermediate data state... In the reverse noise reduction process, the historical operating data of the photovoltaic power station is time-stepped. The distribution state; Historical operating data of photovoltaic power plants These are the noise scheduling parameters for the forward diffusion process in the pre-defined conditional diffusion model. These are unconstrained sampled values ​​generated during the forward diffusion process. This indicates element-wise multiplication.

3. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 1, characterized in that: The process of inputting numerical weather prediction data into a physical mechanism model and outputting physical predicted power includes: Calculate the actual operating temperature of photovoltaic modules : ; in, For ambient temperature, Irradiance, For wind speed, Indicates the basic heat transfer coefficient of a photovoltaic module. This represents the wind speed gain heat transfer coefficient of a photovoltaic module. Combined with the actual operating temperature of photovoltaic modules A photoelectric conversion model is constructed using a single diode equivalent circuit, and the photoelectric conversion model is described by the following equations: ; in, For photocurrent, This is the reverse saturation current of the diode. For series resistance, For parallel resistors, For diode ideality factor, Boltzmann's constant, Represented by natural constant An exponential function with base 0; the current is obtained by solving the above formula. With voltage The correspondence is used to calculate the physical prediction power. : 。 4. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 1, characterized in that: The parallel feature extraction dual-branch includes a one-dimensional convolutional neural network branch and a bidirectional long short-term memory network branch, which respectively extract local features and temporal features from the input data features; The feature fusion layer concatenates local features and temporal features along the feature channel dimension to generate a comprehensive feature sequence. The dual attention mechanism layer receives the comprehensive feature sequence, which is then passed through a concatenated time attention module and feature attention module to generate the final feature vector. The fully connected layer maps the final feature vector to data-driven predicted power.

5. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 4, characterized in that: The time attention module first calculates the importance weight of each time step based on the comprehensive feature sequence, and then performs a weighted sum of the importance weight and the comprehensive feature sequence in the feature channel dimension to generate a time context vector. The feature attention module first uses a fully connected layer to learn the feature weight distribution of the temporal context vector, and then performs element-wise weighting on the temporal context vector based on the feature weight distribution to obtain the final feature vector.

6. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 1, characterized in that: The process involves calculating the weighting coefficients of the physical predicted power and the data-driven predicted power based on the prediction error statistics within a preset historical sliding window, and then performing a weighted summation to obtain the photovoltaic power generation prediction result, including: Within a preset historical sliding window, the root mean square error of the physical mechanism model and the data-driven model are calculated as the prediction error statistics. The weighting coefficients for the physical prediction power and the data-driven prediction power at each time step are calculated using an inverse error proportional function. The mathematical representation of this process is as follows: ; ; in, This represents the mean of the prediction error statistics of the physical mechanism model. This represents the mean of the prediction error statistics of the data-driven model. Indicates the adjustment parameter. Indicates a time step. , Representing time steps Weighting coefficients for physical prediction power and data-driven prediction power; The photovoltaic power generation prediction result is obtained by weighting the physical predicted power and the data-driven predicted power based on their respective weighting coefficients. The mathematical representation is as follows: ; in, , , Representing time steps The photovoltaic power generation prediction results, physical prediction power, and data-driven prediction power.

7. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 1, characterized in that: The determination of whether concept drift has occurred based on the cumulative error trend between the photovoltaic power generation prediction results and the actual power calculation includes: The cumulative error trend at each time point is calculated using the exponentially weighted moving average method: ; in, Indicates time The cumulative error trend; Indicates the forgetting factor; Representing the forgetting factor The power is used to correct for deviations in the cumulative error trend; Indicates time; Indicates time The instantaneous absolute error, based on the current time step Photovoltaic power generation prediction results With actual power The calculation, mathematically represented as follows: ; in, Operators for calculating the norm of a vector; Build dynamic trigger threshold : ; in, , These are the mean and standard deviation of the historical instantaneous absolute error, respectively; Sensitivity coefficient; Set the number of judgment cycles When Cumulative error trend within consecutive prediction periods All meet At that time, a conceptual drift occurred, in which the number of judgment cycles... It is an integer greater than 1.

8. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 7, characterized in that: The establishment of a typical extreme weather memory database and the design of an update strategy include: Real-time calculation of instantaneous absolute error ,when The corresponding time Input data characteristics and actual power Constituting sample pairs Store in a typical extreme weather memory bank , The mean of historical instantaneous absolute errors serves as the admission threshold parameter for a typical extreme weather memory database. The preset empirical coefficient; The typical extreme weather memory bank Fixed capacity When typical extreme weather memory bank The number of sample pairs in the middle has reached a fixed capacity. Furthermore, when new sample pairs are added to the database, a first-in, first-out (FIFO) strategy is adopted to automatically discard the sample pair that has been stored the longest.

9. The interpretable prediction method for photovoltaic power generation based on self-evolving digital twins according to claim 1, characterized in that: The optimization and updating of the photovoltaic power generation prediction model based on the memory database of typical extreme weather, combined with the attribution diagnosis results, includes incremental learning: Constructing a hybrid loss function based on memory playback : ; in, These are the parameters for the photovoltaic power generation prediction model; This is the balance coefficient; The photovoltaic power generation prediction model is based on the latest real-time data stream. The loss is calculated as follows: ; The latest real-time data stream To determine the moment of concept drift, real-time photovoltaic power plant operation data within a preset detection period is collected. A trained photovoltaic digital twin data recovery model generates repair data, which, combined with corresponding meteorological characteristics and actual power output as labels, forms a repair sample set. The number of samples in this repair sample set. This refers to the samples in the restoration sample set, namely the restoration data and the corresponding meteorological characteristics. To and The corresponding actual power, The sample number in this repair sample set; It is a photovoltaic power generation prediction model in the memory bank of typical extreme weather. The loss is calculated as follows: ; in, A typical extreme weather memory bank Medium sample size A typical extreme weather memory bank The samples in the data, i.e., the features of the input data, A typical extreme weather memory bank The number of samples in A typical extreme weather memory bank The sample number in To and The corresponding actual power; Gradient descent is used to transform the memory-replay-based hybrid loss function. Gradient backpropagation is used to optimize the photovoltaic power generation prediction model, including: if and This increases the balance coefficient. Otherwise, reduce the balance coefficient. ; For data-driven models, update the weights of the parallel feature extraction dual-branch and dual-attention mechanism layers, and adjust the normalized consistency score. Then, an additional regularization loss is applied to the dual attention mechanism layer, calculated as follows: ; in, Indicates the regularization loss. The preset regularization penalty coefficient, Feature weight distribution The dimensional components, Shapley value contribution vector at the same prediction time The dimensional components, This indicates the number of feature dimensions in the input data. For physical mechanism models, if the meteorological attribution ratio If so, its key parameters should be recalibrated.

Citation Information

Patent Citations

  • Generating capacity prediction method and system based on digital twinborn model of photovoltaic power station

    CN120237637A

  • Photovoltaic power prediction method and system

    CN120764756A