Meteorological probability prediction method based on physical constraint and condition diffusion model and related device

By introducing a meteorological probability prediction method based on physical constraints and conditional diffusion models, the problems of computational complexity and physical illusion in high-timeliness and high-resolution meteorological forecasting are solved. This method achieves high-precision regional meteorological forecasting, adapts to complex terrain and local microclimate characteristics, and supports power grid dispatching decisions.

CN122332813APending Publication Date: 2026-07-03CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD +2
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CHINA ELECTRIC POWER RESEARCH INSTITUTE CO LTD
Filing Date
2026-04-17
Publication Date
2026-07-03

AI Technical Summary

Technical Problem

Existing meteorological forecasting methods suffer from problems such as high computational complexity, difficulty in quantifying uncertainty, generation of physical illusion samples, and insufficient scale adaptability in high-timeliness and high-resolution forecasting. In particular, they are difficult to handle complex terrain and local microclimate characteristics in regional high-resolution forecasting.

Method used

A meteorological probability prediction method based on physical constraints and conditional diffusion models is adopted. By introducing meteorological physical constraints, multimodal pre-trained encoders and conditional diffusion models, combined with experimental fine-tuning strategies, high-resolution meteorological element probability predictions are generated, guiding the generation of samples that conform to physical laws and adapting to high-resolution regional scenarios.

Benefits of technology

It significantly improves the physical consistency and interpretability of the prediction results, can accurately capture terrain boundaries and local meteorological changes in high-resolution scenarios, provides high-precision local microclimate predictions, and supports the decision-making basis for power grid dispatch.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122332813A_ABST
    Figure CN122332813A_ABST
Patent Text Reader

Abstract

This invention belongs to the field of meteorological forecasting and artificial intelligence application technology, and discloses a meteorological probability prediction method and related device based on physical constraints and conditional diffusion models. The meteorological probability prediction method includes: acquiring historical data for the time to be predicted, including meteorological data for a preset historical time period, power data from new energy power plants, and auxiliary data, including time characteristics and equipment status characteristics; based on the historical data for the time to be predicted, using a trained meteorological probability prediction model to make a prediction and obtain the prediction result; the meteorological probability prediction model includes a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module. The technical solution disclosed in this invention can eliminate physical illusion samples, improve prediction interpretability, and adapt to high-resolution regional scenes, handling complex terrain and local microclimate characteristics.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention belongs to the field of meteorological forecasting and artificial intelligence application technology, and specifically relates to a meteorological probability prediction method and related device based on physical constraints and conditional diffusion models. Background Technology

[0002] Accurate forecasting of regional meteorological elements (such as solar irradiance, wind speed, and wind direction) is the core foundation for new energy resource assessment, power grid dispatching, and meteorological disaster prevention and mitigation.

[0003] Traditional numerical weather prediction (NWP) methods, based on fluid dynamics and thermodynamic equations, offer strong physical consistency but suffer from high computational complexity and low update frequency, making them unsuitable for applications requiring high timeliness. In recent years, deep learning methods, such as Convolutional Neural Networks (CNNs) and Transformers, have achieved significant results in weather forecasting, dramatically improving inference speed. However, most current mainstream deep learning meteorological models are deterministic point forecasting (DPF) models. These models typically optimize by minimizing the mean squared error (MSE), tending to generate smooth average forecasts. This makes it difficult to capture high-frequency details such as dramatic fluctuations in irradiance or extreme wind speeds. Furthermore, deterministic models cannot provide confidence intervals for forecasts, making it difficult to quantify the inherent randomness and uncertainty of meteorological systems. This leaves downstream users lacking effective decision-making support when facing extreme weather risks.

[0004] To address these issues, generative artificial intelligence techniques, such as Probabilistic Diffusion Models (PDM), have been introduced into the meteorological field. PDM learns the asymptotic denoising process of data distribution to generate probabilistic prediction sets with high texture detail and diversity, demonstrating excellent performance in capturing non-stationary meteorological features. However, directly applying general PDM models to high-resolution regional meteorological forecasts still has significant drawbacks: First, the lack of physical constraints means that the purely data-driven generation process is prone to producing "illusion" samples that violate meteorological physics (e.g., generating high nighttime irradiance or spatially discontinuous wind fields), leading to poor interpretability of the prediction results. Second, insufficient scale adaptability; existing research mainly focuses on low-resolution global-scale predictions, making it difficult to handle complex terrain boundary conditions and local microclimate characteristics in regional high-resolution (e.g., 1km~9km) predictions. Summary of the Invention

[0005] The purpose of this invention is to provide a meteorological probability prediction method and related apparatus based on physical constraints and conditional diffusion models to solve one or more of the aforementioned technical problems. The technical solution disclosed in this invention can eliminate physical illusion samples, improve prediction interpretability, and adapt to high-resolution regional scenes, handling complex terrain and local microclimate characteristics.

[0006] To achieve the above objectives, the present invention adopts the following technical solution: In a first aspect, this invention provides a meteorological probability prediction method based on a physical constraint and conditional diffusion model, comprising: Acquire historical data for the time to be predicted; wherein, the historical data includes meteorological data, power data of new energy power plants, and auxiliary data for a preset historical time period; the auxiliary data includes time characteristics and equipment status characteristics; Based on historical data of the time to be predicted, a trained meteorological probability prediction model is used to make a prediction and obtain the prediction result. The meteorological probability prediction model includes: a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module. The data preprocessing module inputs historical data and performs cleaning, normalization, and feature construction to obtain standardized time-series input data. The multimodal pre-trained encoder module inputs the standardized time-series input data and extracts features separately, using a cross-attention mechanism to weightedly fuse the extracted multimodal features to generate a multimodal conditional embedding. The conditional diffusion model prediction module, guided by the multimodal conditional embedding, performs forward noise addition and backward noise reduction processes to generate a multi-set probability prediction sequence for future meteorological elements. The uncertainty quantification module performs statistical analysis on the multi-set probability prediction sequence, calculates the prediction mean and standard deviation step-by-step, constructs confidence intervals based on the 3σ criterion, and outputs the calculated prediction mean, prediction standard deviation, and corresponding confidence intervals as the prediction results. In the reverse denoising process of the conditional diffusion model prediction module, meteorological physical constraints are introduced for gradient guidance.

[0007] A further improvement of the technical solution of this invention is that the multimodal pre-trained encoder module includes: a meteorological branch, a power branch, an auxiliary feature branch, and a fusion layer; wherein, the meteorological branch is used to input time-series meteorological data sequences from standardized time-series input data, and extracts spatiotemporal features through convolutional layers to obtain meteorological feature embeddings; the power branch is used to input time-series power data sequences from standardized time-series input data, and obtains power feature embeddings through fully connected layers and time-series convolutional layers; the auxiliary feature branch is used to input time features and device status features, and obtains auxiliary feature embeddings through transformation by fully connected layers; the fusion layer is used to perform weighted fusion using a cross-attention mechanism to generate multimodal conditional embeddings; The multimodal conditional embedding is represented as: ; ; ; ; In the formula, For multimodal conditional embedding; These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; , , These are meteorological feature embedding, power feature embedding, and auxiliary feature embedding, respectively. Indicates feature splicing; For the embedded dimension.

[0008] A further improvement of the technical solution of the present invention is that, in the reverse denoising process of the conditional diffusion model prediction module, the multimodal condition embedding is mapped to a key vector and a value vector, the noise sample of the current diffusion step is mapped to a query vector, and the dependency relationship between the condition and the noise sample is captured by cross attention calculation. The mapping expression is: ; ; ; ; In the formula, These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; For the first Noise samples from the diffusion step; For multimodal conditional embedding; For the embedded dimension.

[0009] A further improvement of the technical solution of the present invention is that the meteorological physical constraints include: energy conservation constraints, wind speed field spatial continuity constraints, and irradiance diurnal rationality constraints.

[0010] A further improvement of the technical solution of the present invention is that the training process of the meteorological probability prediction model includes: a pre-training stage and a fine-tuning stage; the pre-training stage is used to learn the general fluid dynamics and atmospheric physical laws of the meteorological probability prediction model; the fine-tuning stage is used to fine-tune the pre-trained meteorological probability prediction model using a local fine-tuning dataset. In the fine-tuning phase, the corrected meteorological grid data is spliced ​​with the measured power data of the target power station and auxiliary data to form a localized fine-tuning dataset; a joint loss function combining noise prediction loss and power deviation loss is used to calculate the loss and update the model parameters, and training stops after the preset conditions are met.

[0011] In a second aspect, the present invention provides a meteorological probability prediction system based on a physical constraint and conditional diffusion model, comprising: The historical data acquisition unit is used to acquire historical data for the time to be predicted; wherein, the historical data includes meteorological data, power data of new energy power plants and auxiliary data for a preset historical time period; the auxiliary data includes time characteristics and equipment status characteristics; The prediction result acquisition unit is used to make predictions based on historical data of the time to be predicted, using a trained meteorological probability prediction model, and obtain prediction results. The meteorological probability prediction model includes: a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module. The data preprocessing module inputs historical data and performs cleaning, normalization, and feature construction to obtain standardized time-series input data. The multimodal pre-trained encoder module inputs the standardized time-series input data and extracts features separately, using a cross-attention mechanism to weightedly fuse the extracted multimodal features to generate a multimodal conditional embedding. The conditional diffusion model prediction module, guided by the multimodal conditional embedding, performs forward noise addition and backward noise reduction processes to generate a multi-set probability prediction sequence for future meteorological elements. The uncertainty quantification module performs statistical analysis on the multi-set probability prediction sequence, calculates the prediction mean and standard deviation step-by-step, constructs confidence intervals based on the 3σ criterion, and outputs the calculated prediction mean, prediction standard deviation, and corresponding confidence intervals as the prediction results. In the reverse denoising process of the conditional diffusion model prediction module, meteorological physical constraints are introduced for gradient guidance.

[0012] A further improvement of the technical solution of this invention is that the multimodal pre-trained encoder module includes: a meteorological branch, a power branch, an auxiliary feature branch, and a fusion layer; wherein, the meteorological branch is used to input time-series meteorological data sequences from standardized time-series input data, and extracts spatiotemporal features through convolutional layers to obtain meteorological feature embeddings; the power branch is used to input time-series power data sequences from standardized time-series input data, and obtains power feature embeddings through fully connected layers and time-series convolutional layers; the auxiliary feature branch is used to input time features and device status features, and obtains auxiliary feature embeddings through transformation by fully connected layers; the fusion layer is used to perform weighted fusion using a cross-attention mechanism to generate multimodal conditional embeddings; The multimodal conditional embedding is represented as: ; ; ; ; In the formula, For multimodal conditional embedding; These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; , , These are meteorological feature embedding, power feature embedding, and auxiliary feature embedding, respectively. Indicates feature splicing; For the embedded dimension.

[0013] A further improvement of the technical solution of the present invention is that, in the reverse denoising process of the conditional diffusion model prediction module, the multimodal condition embedding is mapped to a key vector and a value vector, the noise sample of the current diffusion step is mapped to a query vector, and the dependency relationship between the condition and the noise sample is captured by cross attention calculation. The mapping expression is: ; ; ; ; In the formula, These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; For the first Noise samples from the diffusion step; For multimodal conditional embedding; For the embedded dimension.

[0014] A further improvement of the technical solution of the present invention is that the meteorological physical constraints include: energy conservation constraints, wind speed field spatial continuity constraints, and irradiance diurnal rationality constraints.

[0015] A further improvement of the technical solution of the present invention is that the training process of the meteorological probability prediction model includes: a pre-training stage and a fine-tuning stage; the pre-training stage is used to learn the general fluid dynamics and atmospheric physical laws of the meteorological probability prediction model; the fine-tuning stage is used to fine-tune the pre-trained meteorological probability prediction model using a local fine-tuning dataset. In the fine-tuning phase, the corrected meteorological grid data is spliced ​​with the measured power data of the target power station and auxiliary data to form a localized fine-tuning dataset; a joint loss function combining noise prediction loss and power deviation loss is used to calculate the loss and update the model parameters, and training stops after the preset conditions are met.

[0016] In a third aspect, the present invention provides an electronic device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the computer program to implement the meteorological probability prediction method based on a physical constraint and conditional diffusion model as described in any one of the first aspects of the present invention.

[0017] In a fourth aspect, the present invention provides a non-transitory computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the meteorological probability prediction method based on a physical constraint and conditional diffusion model as described in any one of the first aspects of the present invention.

[0018] In a fifth aspect, the present invention provides a computer program product comprising computer instructions which, when executed by a processor, implement the steps of the meteorological probability prediction method based on a physical constraint and conditional diffusion model as described in any one of the first aspects of the present invention.

[0019] The present invention has the following beneficial effects: This invention provides a meteorological probability prediction method based on a physical constraint and conditional diffusion model. Specifically, it is a high-resolution regional meteorological element probability prediction method based on a physical constraint-guided and conditional diffusion model. The physical constraint-guided conditional diffusion model eliminates physics illusion samples and improves prediction interpretability. It is adaptable to high-resolution regional scenarios and can handle complex terrain and local microclimate features. Specifically, addressing the problem that general probability diffusion models lack physical constraints and are prone to generating physics illusion samples, this invention introduces a physical constraint-guided mechanism in the reverse denoising inference stage of the diffusion model, which significantly improves the physical consistency and interpretability of the prediction results. Addressing the problem that existing models lack scale adaptability and are difficult to adapt to complex high-resolution regional terrain and microclimate, this invention sets up a multimodal pre-trained encoder module. Through regional spatiotemporal coding and a conditional cross-attention architecture, it can accurately capture fine-grained features such as terrain boundaries and local meteorological abrupt changes in high-resolution scenarios of 1km to 9km, solving the deficiency of global low-resolution models in adapting to complex regional scenarios and enhancing the adaptability to regional microclimate.

[0020] In the preferred embodiment of the present invention, when introducing a physical constraint guidance mechanism, meteorological physical laws and the energy conservation relationship are used as constraints to force the generated results to conform to physical priors, which can effectively eliminate abnormal samples that violate common sense, such as high nighttime irradiance and spatially discontinuous wind fields.

[0021] Currently, data fusion is difficult, and training solely based on reanalysis data is insufficient to correct systematic biases within the region and cannot fully utilize sparse but high-precision ground observation data to improve local forecast accuracy. To address these issues, the preferred embodiment of this invention employs a two-stage transfer learning strategy that combines pre-training with measured fine-tuning. This strategy first learns universal atmospheric laws and then calibrates the model using sparse, high-precision measured data, effectively correcting regional biases and achieving high-precision local forecasts even with small sample sizes. Attached Figure Description

[0022] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0023] Figure 1 This is a flowchart illustrating a meteorological probability prediction method based on a physical constraint and conditional diffusion model, as described in an embodiment of the present invention. Figure 2 This is a schematic diagram of the principle framework of a meteorological probability prediction method based on a physical constraint and conditional diffusion model in a specific embodiment of the present invention. Figure 3 This is a schematic diagram comparing the reconstruction effects of the autoencoder in an embodiment of the present invention; Figure 4 This is a schematic diagram of the spatiotemporal trajectory verification of the multimodal condition-guided diffusion model in an embodiment of the present invention; Figure 5 This is a schematic diagram illustrating uncertainty quantification and confidence interval visualization in an embodiment of the present invention; Figure 6 This is a schematic diagram of a meteorological probability prediction system based on a physical constraint and conditional diffusion model in an embodiment of the present invention. Detailed Implementation

[0024] The specific embodiments of the present invention will be further described in detail below with reference to the accompanying drawings. Obviously, the described embodiments are only a part of the embodiments of the present invention, and not all of them. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without creative effort are within the scope of protection of the present invention.

[0025] Existing numerical weather prediction (NWP) methods are based on atmospheric hydrodynamics and thermodynamic equations, using supercomputers to perform complex numerical simulations and solutions of atmospheric physical processes. Specifically, they utilize global or regional meteorological observation data as initial conditions, and after data assimilation, integrate to calculate the spatiotemporal evolution of meteorological elements (such as wind speed, irradiance, and temperature) at future times. Their core logic is deterministic deduction based on physical mechanisms, providing a large-scale meteorological background field with strong physical consistency. However, NWP methods have limitations: although the physical mechanisms are clear, the computational cost is extremely high, and the update frequency is typically low (e.g., once every 6 or 12 hours), making it difficult to meet the high timeliness requirements of new energy power forecasting; furthermore, the spatial resolution of this method is relatively coarse (typically at the 10km~25km level), making it difficult to capture micro-meteorological characteristics under complex terrain within a region; more importantly, NWP is essentially a deterministic system, and a single run cannot quantify the uncertainty of the prediction results unless a large amount of resources are spent running multi-member ensemble forecasts, which is often uneconomical for commercial applications.

[0026] Existing deterministic deep learning methods mainly include architectures such as convolutional neural networks, long short-term memory networks, and Transformers. These methods aim to minimize the mean squared error (MSE) or mean absolute error (MAE) between predicted and actual values. By learning the nonlinear mapping relationship between a large amount of historical meteorological data and measured data, they output a single predicted value for future moments (point prediction). This method is computationally fast and possesses powerful feature extraction capabilities, and is currently widely used in short-term forecasting. However, existing deterministic deep learning methods have drawbacks: these models are limited by the regression mean characteristic of the MSE loss function, tending to output smooth average predictions. This results in insufficient prediction capabilities for extreme weather events (such as sudden cloud cover for solar power and hill-climbing events for wind power) and high-frequency fluctuation details (i.e., the "smoothing effect"). Furthermore, as point prediction models, their output is only a single value, failing to provide confidence intervals or probability distributions for the prediction results, making it impossible for grid dispatchers to assess prediction risks. In addition, the purely data-driven "black box" nature of these models means they lack physical constraints, making it easy to output predictions that violate physical laws in scenarios not covered by training data.

[0027] Existing general generative modeling methods utilize generative adversarial networks or standard probabilistic diffusion models to attempt to learn the latent probability distribution of meteorological data. By introducing random noise and learning a denoising process, they generate diverse meteorological field samples. These methods aim to address the problems of vague predictions and lack of texture detail in deterministic models, generating high-resolution meteorological images and providing a certain degree of ensemble forecasting capability. However, existing general generative modeling methods have shortcomings: while possessing probabilistic generation capabilities, they exhibit significant limitations when directly applied to high-precision regional forecasting. Specifically, general models lack explicit physical constraint mechanisms, relying purely on data distribution fitting, which easily leads to inconsistencies between meteorological elements (such as mismatches between wind speed and pressure fields) or "illusion" samples that violate energy conservation, resulting in unreliable predictions. Furthermore, existing generative models are mostly designed for global scales or natural images, making it difficult to effectively integrate regional multimodal data (such as numerical forecasts, measured data, static topography, etc.). When faced with limited measured data samples, the models struggle to converge or exhibit poor generalization ability, failing to correct regional systematic biases.

[0028] To address the drawbacks of numerical weather prediction, such as high computational cost, low resolution, and difficulty in quantifying uncertainty, as well as the smoothing effect and inability to assess risk inherent in deterministic deep learning models, this invention proposes a prediction method based on a conditional diffusion probability model. By introducing a conditional cross-attention mechanism, it uses numerical weather prediction as a guiding condition and leverages the random sampling characteristics of the diffusion model to generate a high-resolution set of probability distributions of meteorological elements. This method ensures computational efficiency while achieving accurate quantification of future meteorological / power uncertainties, providing rich decision-making information, including confidence intervals, for power dispatching.

[0029] To address the shortcomings of general generative models, such as the lack of physical constraints and the tendency to generate samples that violate physical laws, this invention provides a sampling inference mechanism guided by physical constraints. In the inference stage of model reverse denoising, a gradient guiding term based on physical conversion laws (such as wind speed-power curves and irradiance conversion equations) is explicitly introduced to force the generated trajectory to converge with the theoretical physical curve. Through this "physical plug-in" approach, outlier prediction points that violate physical common sense are eliminated, significantly improving the physical consistency, interpretability, and credibility of the probability prediction results in engineering applications.

[0030] Furthermore, to address the shortcomings of existing models in adapting to regional microclimate characteristics and poor generalization due to insufficient measured data samples, this invention proposes a two-stage transfer learning strategy based on physical pre-training combined with measured fine-tuning. This strategy utilizes long-term reanalysis data (such as ERA5) to allow the model to pre-learn universal laws of atmospheric dynamics, and then uses sparse, high-precision measured data to fine-tune the model. Combined with a regional spatiotemporal encoder containing a high-frequency detail preservation mechanism, this method can effectively correct regional systematic biases and still achieve high-precision prediction of local microclimate elements even with limited measured data.

[0031] Please see Figure 1 The present invention provides a meteorological probability prediction method based on a physical constraint and conditional diffusion model, comprising the following steps: Step 1: Obtain historical data for the time to be predicted; wherein, the historical data includes meteorological data, power data of new energy power plants, and auxiliary data for a preset historical time period; the auxiliary data includes time characteristics and equipment status characteristics.

[0032] In a specific exemplary technical solution, meteorological data may include: irradiance, wind speed, wind direction, temperature, and humidity; power data may include: historical output power of new energy power plants, which needs to be aligned with the time sequence of meteorological data; in auxiliary data, time characteristics may include time, date, and season, and equipment status characteristics may include photovoltaic panel cleanliness and wind turbine operating parameters.

[0033] Step 2: Based on historical data of the time to be predicted, use the trained meteorological probability prediction model to make a prediction and obtain the prediction result.

[0034] In this embodiment of the invention, the meteorological probability prediction model includes: a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module; wherein, The data preprocessing module is used to input historical data and perform cleaning, normalization, and feature construction to obtain standardized time-series input data. In a specific exemplary technical solution, cleaning can be achieved based on outlier removal and linear interpolation to fill missing values, normalization can be achieved using Max-Min normalization, and feature construction can build time-series features and cross features. The multimodal pre-trained encoder module is used to input standardized time-series input data and extract features separately. A cross-attention mechanism is used to weightedly fuse the extracted multimodal features to generate multimodal conditional embeddings. In a specific exemplary technical solution, the multimodal pre-trained encoder module includes: a meteorological branch for obtaining meteorological feature embeddings, a power branch for obtaining power feature embeddings, an auxiliary feature branch for obtaining auxiliary feature embeddings, and a fusion layer. In the fusion layer, a cross-attention mechanism is used for weighted fusion, with the power feature embedding as the query vector, and the concatenation result of the meteorological feature embedding and the auxiliary feature embedding is the key vector and value vector. The conditional diffusion model prediction module is used to generate a multi-set probability prediction sequence of future meteorological elements by performing forward denoising and reverse denoising processes guided by multimodal conditional embedding. In the reverse denoising process, meteorological physical constraints are introduced for gradient guidance. In a specific exemplary technical solution, the meteorological physical constraints include: energy conservation constraints, wind speed field spatial continuity constraints, and irradiance diurnal rationality constraints. Furthermore, in the reverse denoising process, the multimodal conditional embedding is mapped to key vectors and value vectors, and the noise samples of the current diffusion step are mapped to query vectors. The dependency relationship between conditions and noise samples is captured by cross-attention calculation. The uncertainty quantification module is used to perform statistical analysis on multi-set probability prediction sequences, calculate the prediction mean and standard deviation step by step, construct confidence intervals based on the 3σ criterion, and output the calculated prediction mean, prediction standard deviation and corresponding confidence intervals as prediction results.

[0035] Please see Figure 2 The present invention provides a meteorological probability prediction method based on physical constraints and conditional diffusion models. Specifically, it is based on the CoDiCast conditional diffusion model architecture, which includes: a data preprocessing module, a multimodal pre-trained encoder module, a measured data fine-tuning module, a conditional diffusion model prediction module, an uncertainty quantification module, and an output module. The modules work together to achieve end-to-end prediction of new energy power.

[0036] In this embodiment of the invention, the data preprocessing module is used to clean, normalize, and construct features from the input multi-source data, providing high-quality data for subsequent modeling; wherein, The input multi-source data specifically includes: Meteorological data includes: irradiance, wind speed, wind direction, temperature, and humidity; among which, the spatiotemporal resolution can be adjusted according to the forecast scenario, for example, short-term forecasts are 15 minutes / step, and medium-term forecasts are 1 hour / step; Power data includes: historical output power of new energy power plants; among which, the historical output power of new energy power plants needs to be aligned with the time series of meteorological data; Auxiliary data includes: time characteristics (such as time, date, season, etc.) and equipment status characteristics (such as the cleanliness of photovoltaic panels, wind turbine operating parameters, etc.).

[0037] In this embodiment of the invention, the specific steps for cleaning, normalization, and feature construction in the data preprocessing module are as follows: During the cleaning process, 3 σ The criteria remove outliers from power and meteorological data and fill in missing values ​​using linear interpolation to complete the cleaning process. During the normalization process, Max-Min normalization is applied to all numerical features, scaling them to the [0,1] interval. The formula is as follows: ;in, x These are the original eigenvalues. 、 These are the maximum and minimum values ​​of the feature, respectively. During feature construction, time-series features (such as the 24-hour power moving average and the rate of change of meteorological elements) and cross features (such as the irradiance-temperature product term) are constructed to improve the expressive power of the model input.

[0038] In this embodiment of the invention, the multimodal pre-trained encoder module is used to convert preprocessed multi-source heterogeneous data into a unified latent embedding to integrate key information from dimensions such as meteorology, power, and time, providing precise guidance for the conditional diffusion process; wherein, a multi-branch convolutional autoencoder is used, including a meteorological branch, a power branch, and an auxiliary feature branch.

[0039] In a specific exemplary technical solution, the specific structure of the multimodal pre-trained encoder is explained as follows: In the meteorology branch, the input is a time-series meteorological data sequence, with the following shape: , For time step, For spatial grid resolution, The number of meteorological variables is used; spatiotemporal features are extracted through 4 convolutional layers (number of filters 32→128→256→512, kernel size 3×3, stride 1, padding=1), and the meteorological feature embedding is output, with the shape being... , For the embedded dimension; In the power branch, the input is a historical power sequence with the following shape: , The power feature is embedded in the form of either the number of power plants or the power output per plant. This is achieved through two fully connected layers (256 → 512 neurons) and one temporal convolutional layer (capturing temporal power dependencies). The output power feature is shaped as follows: ; In the auxiliary feature branch, the inputs are time features and device status features, with the shape being... , The auxiliary feature number is converted into an auxiliary feature embedding through a single fully connected layer (from 128 to 512 neurons), with the shape being... ; In the fusion layer, cross-attention weighted fusion is used, with power feature embedding as the query ( The concatenation result of meteorological feature embedding and auxiliary feature embedding is Key ( ) and Value ( The formula is: ; ; ; ; in, For multimodal conditional embedding; These are the query vector, key vector, and value vector, respectively. , , These are embedded for meteorological, power, and auxiliary features, respectively. , , For learnable projection matrices, dimension ; Indicates feature splicing, .

[0040] In this embodiment of the invention, the pre-training process of the multimodal pre-trained encoder module is as follows: (1) Training objective: To minimize the reconstruction loss, train the encoder and decoder of the autoencoder. The decoder reconstructs the original multi-source data through deconvolutional layers and fully connected layers, and reconstructs the loss function. Represented as: ; in, The original input data, To reconstruct data for the decoder, For the desired operation.

[0041] (2) Parameter constraints: After pre-training, all parameters of the encoder (convolutional layer weights, attention projection matrix, etc.) are fixed. During the inference stage, they are only used for feature embedding generation and the parameters are not updated.

[0042] (3) Output specifications: Multimodal latent embedding ( , , (For historical time steps).

[0043] In this embodiment of the invention, the conditional diffusion model prediction module uses latent embedding as a condition to generate a probability distribution of future power through forward diffusion noise addition and reverse denoising processes. Specifically, Gaussian noise is added to the real power sequence through the forward diffusion process, and then the future power sequence is recovered through the reverse denoising process using multimodal conditional embedding as a condition. Uncertainty modeling is achieved by utilizing the probabilistic characteristics of the diffusion model.

[0044] In a specific exemplary technical solution, the forward diffusion process includes the following parts: (1) Input: Real power sequence at future time points , To predict the time step; (2) Process: In Gaussian noise is gradually added in each diffusion step, the 1st... The diffusion sample of the step is: ; in, It is Gaussian noise. The unit covariance matrix; , For the first The single-step decay coefficient; , For noise scheduling parameters (using linear scheduling, ); (3) Output: Final diffusion sample It is approximately pure noise.

[0045] In a specific exemplary technical solution, the inverse conditional denoising process includes the following parts: (1) Input: Initial noise Multimodal conditional embedding (From a pre-trained encoder); (2) Denoising Network: The architecture of "cross-attention combined with U-Net" is adopted, and the specific design is as follows: Cross-attention blocks: embedding multimodal conditions Mapped to Key ( ) and Value ( ), to the noise sample of the current diffusion step Mapped to Query ( The dependency between the capture conditions and the noisy samples is calculated using cross-attention, as shown in the formula: ; ; ; ; in, , , For learnable projection matrices, .

[0046] U-Net architecture: consists of 4 downsampling layers and 4 upsampling layers; where... Downsampling: MaxPooling (step size 2) is used to reduce feature dimensionality. Each layer contains 2 ResNet blocks (to improve gradient propagation) and 1 GroupNormalization layer (number of groups = 8). The number of channels is 64→128→256→512 respectively. Upsampling: Nearest interpolation (scaling factor 2) is used to restore the feature dimension, and the corresponding layer features from the downsampling stage are concatenated through skip connections to preserve fine-grained information; Output layer: 1×1 convolutional layer, which maps features to noise predictions. .

[0047] (3) Noise reduction update: The first The formula for updating the denoised samples in step 1 is: ; in, For sampling noise, The standard deviation of noise (by (Calculated) (4) Multi-step prediction and set generation.

[0048] Multi-step prediction: Employing an autoregressive mechanism, the prediction results from the previous step are used to predict the outcome of the previous step. As input conditions, they are fused with historical multimodal conditions to predict the next power level. until completion Step prediction.

[0049] Set generation: Inference phase, fixed input conditions (multimodal conditional embedding) ),generate Individual initial noises (quantity can be changed as needed) The results were obtained through reverse denoising processes. A power prediction sequence (i.e., ensemble prediction results).

[0050] In a specific exemplary technical solution, the model training configuration is as follows: Loss function: Noise prediction loss, minimizing the MSE of the model's predicted noise and the actual added noise: ; Optimizer: Adam optimizer, learning rate The decay steps are 10,000, and the decay rate is 0.95. Training parameters: Batch size 256, training epochs 800, number of diffusion steps .

[0051] In this embodiment of the invention, the uncertainty quantification module calculates the prediction mean and standard deviation of the set of prediction sequences generated by the conditional diffusion model prediction module through statistical analysis, and generates probability intervals based on the 3σ criterion, thereby quantifying the uncertainty risk of new energy power fluctuations and supporting power grid dispatching decisions.

[0052] Set sequence statistics: For each set of predicted sequences, the mean (as the final point prediction value) and standard deviation (as a measure of uncertainty) are calculated step-by-step: ; ; in, for The predicted mean power at time t, for The standard deviation of the prediction at time. For the first A set sequence in The predicted value at any given time.

[0053] 3σ probability interval generation: Based on the normal distribution assumption, the 3σ interval covers a 99.73% confidence level. The interval calculation formula is as follows: ; This range can effectively capture extreme power fluctuation scenarios and provide a risk boundary reference for power grid dispatching.

[0054] In this embodiment of the invention, the output module outputs the power prediction value (mean) and uncertainty range for future time periods, providing decision support for power grid dispatch. This includes the following: (1) Point prediction results: future Multiple ensemble predictions of renewable energy power at each time step (mean) ); (2) Uncertainty results: the standard deviation of the forecast at each time step and the 3σ probability interval: ; (3) Visualization results: power prediction curve, uncertainty interval filling plot, risk level classification (based on standard deviation size, divided into low, medium and high risk).

[0055] In the improved technical solution of this invention, measured fine-tuning is a key step in adapting to local microclimate characteristics and correcting data biases. The core objective is to calibrate the model using localized measured data, solve the systematic bias problem of ERA5 reanalysis data in specific regions, and improve the model's predictive adaptability to target new energy power plants (photovoltaic / wind power). The specific steps are as follows: (1) Data collection and screening: Data source: Short-time series measured data from meteorological stations (including the power station's own meteorological station and national meteorological observation stations) within a 50km radius of the target power station were collected, with a time span of 1 to 5 years. The data types were strictly aligned with ERA5 meteorological elements (including 6 core elements such as 2m air temperature, 10m wind speed, 10m wind direction, and net surface radiation). At the same time, measured power data of the target power station were collected simultaneously (aligned with the meteorological data time series, 6 hours / step, matching the native time step of CoDiCast).

[0056] Data screening: The 3σ criterion is used to remove outliers (such as extreme wind speeds and abnormal temperatures) from the measured meteorological data, and missing values ​​are filled in by linear interpolation (ensuring that the missing data rate of a single station is ≤3%). For the measured power data, abnormal output values ​​caused by non-meteorological factors such as equipment failure and maintenance shutdown are removed, and power records under normal power generation conditions are retained to ensure the authenticity and validity of the data.

[0057] (2) Measured data grid mapping: Grid alignment standard: Based on a spatial resolution of 0.1°×0.1°, determine the target grid coordinates where the target power station is located, and construct a spatial grid system consistent with the ERA5 data.

[0058] Interpolation mapping method: For scattered measured station data, Kriging interpolation (preferred choice to adapt to the spatial continuity characteristics of meteorological elements) or inverse distance weighted (IDW) interpolation method is used to map the single-point measured meteorological data to each grid cell of the target grid, generating "measured meteorological grid data" that is completely consistent with the ERA5 data format (format: , For time step, (For grid dimensions), for grid cells without actual station coverage, meteorological data from the corresponding ERA5 grid are directly used to fill the grid cells to ensure grid data integrity.

[0059] (3) ERA5 system bias correction: Deviation analysis: Calculate the element-by-element and time-step deviation values ​​between the measured meteorological grid data and the corresponding ERA5 grid data (deviation = measured value - ERA5 value), statistically analyze the spatiotemporal distribution characteristics of the deviation (e.g., significant deviation in summer temperature and concentrated deviation in winter wind speed in a certain region), and identify the systematic deviation type of ERA5 data in the target region (e.g., overall higher, lower, or seasonal deviation).

[0060] Deviation Correction Model: A linear deviation correction function is constructed. Based on the statistical results of the deviation between measured and ERA5 data, correction coefficients are fitted grid-by-grid and meteorological element-by-element. The formula is as follows: ; in, This is the corrected ERA5 data. This is the original ERA5 data. The historical mean deviation , These are correction coefficients obtained through least squares fitting (adapting to the deviation characteristics of different elements); after correction, the mean deviation between the measured data and the corrected ERA5 data is ensured to be ≤5%, significantly reducing the impact of systematic bias.

[0061] (4) Model fine-tuning training: Fine-tuning dataset construction: The corrected ERA5 meteorological grid data is spliced ​​with the measured power data of the target power plant to form a "localized fine-tuning dataset", which is divided into a fine-tuning training set and a fine-tuning validation set in a 7:3 ratio (to avoid data leakage in terms of time sequence, and to ensure that the fine-tuning validation set is a continuous period after the fine-tuning training set).

[0062] Fine-tuning strategy: Load the parameters of the completed conditional diffusion model (freeze the parameters of the pre-trained encoder and U-Net core layer, and only unfreeze some parameters of the output decoding layer and cross-attention layer), take "the combination of corrected ERA5 meteorological data and measured power data" as input, use the Adam optimizer (adjust the learning rate to 5e-5, which is lower than the initial training learning rate to avoid damaging the performance of the existing model), keep the batch size at 256, and set the fine-tuning training rounds to 100-150 rounds.

[0063] Fine-tuning loss function: A joint loss function of "noise prediction loss + power deviation loss" is adopted, and the formula is as follows: ; in, This is the original noise prediction loss of CoDiCast (ensuring that the core characteristics of the diffusion model remain unchanged). The MSE loss between measured and predicted power (enhancing the model's adaptation to local power-meteorological relationships).

[0064] Validation of fine-tuning effects and termination conditions. Validation metrics: Based on the fine-tuned validation set, evaluate the core performance of the model after fine-tuning: power prediction accuracy (RMSE decreases compared to before fine-tuning); 3σ confidence interval coverage (≥99.5%); local microclimate adaptability (e.g., prediction error decreases compared to before fine-tuning under typical local climate scenarios such as high temperature and strong winds).

[0065] Termination conditions: When the RMSE of the fine-tuning validation set does not decrease for 10 consecutive rounds and the 3σ interval coverage is stable above 99.5%, stop fine-tuning and save the final fine-tuned model parameters; if overfitting occurs during fine-tuning (the RMSE of the training set continues to decrease but the RMSE of the validation set increases), the early stopping strategy is adopted to terminate the process in advance and save the optimal model parameters.

[0066] In a specific exemplary technical solution, model training includes the following steps: Step 1: Data preparation, dividing the data into training set (80% of historical data), validation set (10%), and test set (10%), and completing preprocessing; Step 2: Pre-train the multimodal encoder, using reconstruction loss to train until the validation set loss converges, and save the encoder parameters; Step 3: Train the conditional diffusion model, using the output of the pre-trained encoder as the conditional input, minimizing the noise prediction loss, and employing the Adam optimizer (learning rate...). (10,000 decay steps, 0.95 decay rate), batch size 256, training epochs 800; Step 4: Model tuning. Based on the prediction accuracy (RMSE) and uncertainty quantification effect (the proportion of actual power falling within the confidence interval) on the validation set, adjust the number of diffusion steps. (Finally set to 1000), Embedding Dimension Hyperparameters, etc.

[0067] Model inference includes the following steps: Step 1: Input historical data for the time to be predicted (such as weather and power data for the previous 24 hours), and generate model input through the data preprocessing module; Step 2: Input the preprocessed data into the pre-trained encoder to generate multimodal conditional embeddings. ; Step 3: Generate An initial noise is obtained through an inverse conditional denoising process. A power prediction sequence; Step 4: Calculate the predicted mean, standard deviation, and confidence interval using the uncertainty quantification module; Step 5: Output the prediction results and uncertainty information to support scheduling decisions.

[0068] To address the challenge of training large-scale deep learning models with short-series measured data from newly constructed sites or specific regions, this invention proposes a two-stage transfer learning strategy combining physical pre-training and measured fine-tuning. This strategy utilizes long-series ERA5 reanalysis data to allow the model to pre-learn universal laws of atmospheric dynamics, and then corrects regional systematic biases using sparse, high-precision measured data. This method not only solves the model convergence problem under small sample sizes but also effectively captures and adapts to the unique microclimate characteristics of the target region (such as the perturbation of wind speed by local topography), significantly improving the model's generalization ability and local prediction accuracy.

[0069] Compared to traditional deterministic point prediction models, this invention is based on a conditional diffusion probability model, which can output meteorological / power ensemble forecasts containing rich statistical information. It generates multiple possible future scenarios through a single inference, providing not only high-precision prediction mean, but also accurate quantification of the uncertainty of the prediction results (such as outputting P10 and P90 confidence intervals), and intuitively displaying the probability of extreme weather events (such as photovoltaic cloud obstruction and wind power peak rise).

[0070] The specific application schemes of this invention are as follows: 1. Data Layer: (1) Data source and variable selection: ERA5 Variables (Input Channels): ssrd (Surface solar radiation downwards): Shortwave radiation downwards from the Earth's surface (corresponding to photovoltaic irradiance); among them, the radiation of ERA5 is a cumulative value and needs to be differentially processed to become an hourly average.

[0071] t2m (2m temperature): Temperature at 2 meters (affects photovoltaic panel efficiency and wind turbine density).

[0072] u10 (10m u-component of wind): 10-meter meridional wind speed.

[0073] v10 (10m v-component of wind): 10-meter zonal wind speed.

[0074] sp (Surface pressure): Surface air pressure (used to help calculate air density).

[0075] tcc (Total cloud cover): Total cloud cover (crucial for photovoltaic forecasting).

[0076] Static Channels: DEM: Digital Elevation Model (local terrain has a significant impact on wind speed).

[0077] Land-Sea Mask: A protective covering for both land and sea.

[0078] (2) Spatiotemporal settings: Time resolution: 1 hour.

[0079] Spatial resolution: Based on the size of the province, the latitude and longitude grid is clipped and interpolated to a fixed value. Spatial resolution adopts (Approximately 9km).

[0080] Boundary treatment: Zero fill is used at the boundary.

[0081] 2. Input / output format Define the data flow pattern of the model, and select the time window as: predicting the next 12 hours from the past 12 hours.

[0082] Conditional input tensor: Input to Encoder.

[0083] shape: Using Batch=32, the past 12 hours, a 96x96 grid, and 6 meteorological variables; among them, and Merge into channel dimension To adapt to standard 2D-CNN.

[0084] Predicted target tensor: The object to be denoised using the diffusion model.

[0085] shape: .

[0086] Each prediction forecasts the state for the next hour (autoregressive rolling prediction).

[0087] 3. Encoder Module Because it is a local area and actual measurement data has been incorporated, the encoder needs to enhance its ability to extract "high-frequency fluctuations".

[0088] enter: (Historical ERA5 data combined with interpolated measured data).

[0089] Residual connections: Add residual blocks to the Encoder to prevent deep networks from losing local high-frequency details (cloud shading in photovoltaics, gusts in wind power).

[0090] Location encoding: Since local areas lack implicit information on global latitude and longitude, it is recommended to explicitly add normalized Lat / Lon grids as two additional channels to the input channels to tell the model "this is a mountainous area, and that is a plain".

[0091] Output: Conditional embedding vector . 4. Conditional diffusion module Backbone network: U-Net.

[0092] Cross attention: Query (Q): The noisy image at the current time step.

[0093] Key (K) / Value (V): The output of the Encoder .

[0094] Function: To enable the model to generate future wind speed / irradiance distributions by weighting based on historical trends provided by the Encoder (such as cloud movement direction and cold front passage trends).

[0095] Temporal embedding: number of embedding diffusion steps Add embeddings of "hours in days" and "months in years".

[0096] 5. Training Strategy Module A two-stage training method was adopted.

[0097] Phase 1: Physical Pre-training Data: Long-term (past 10 years) ERA5 data.

[0098] Objective: To enable the model to learn universal physical laws such as atmospheric dynamics equations, cloud dissipation patterns, and the influence of topography on wind speed.

[0099] Phase Two: Actual Measurement and Fine-tuning Data: Short-term (past 3 years) measured data are used.

[0100] Processing: The scattered measured station data are mapped onto the same grid as ERA5 using Kriging interpolation or IDW interpolation. For areas without stations, ERA5 data is used to fill in the gaps.

[0101] Objective: To correct the systematic bias of ERA5 and make the model adapt to local microclimate characteristics.

[0102] Please see Figures 3 to 5 , Figure 3 The encoder evaluation results are shown, from Figure 3As can be seen, for a task of "autoencoder / feature extractor," the encoder almost achieves lossless compression. The number of ensemble predictions was chosen to be N=10. The ensemble prediction results for wind speed and the corresponding probability prediction results are as follows: Figure 4 and Figure 5 As shown, it can be seen that the true value of green is always enveloped in the orange shadow. The fact that the probability estimate of the model is within the range indicates that the model's probability estimate is reliable.

[0103] The following are embodiments of the apparatus of the present invention, which can be used to execute embodiments of the method of the present invention. For details not disclosed in the apparatus embodiments, please refer to the embodiments of the method of the present invention.

[0104] Please see Figure 6 In this embodiment of the invention, a meteorological probability prediction system based on a physical constraint and conditional diffusion model is provided, comprising: The historical data acquisition unit is used to acquire historical data for the time to be predicted; wherein, the historical data includes meteorological data, power data of new energy power plants and auxiliary data for a preset historical time period; the auxiliary data includes time characteristics and equipment status characteristics; The prediction result acquisition unit is used to make predictions based on historical data of the time to be predicted, using a trained meteorological probability prediction model, and obtain prediction results. The meteorological probability prediction model includes: a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module. The data preprocessing module inputs historical data and performs cleaning, normalization, and feature construction to obtain standardized time-series input data. The multimodal pre-trained encoder module inputs the standardized time-series input data and extracts features separately, using a cross-attention mechanism to weightedly fuse the extracted multimodal features to generate a multimodal conditional embedding. The conditional diffusion model prediction module, guided by the multimodal conditional embedding, performs forward noise addition and backward noise reduction processes to generate a multi-set probability prediction sequence for future meteorological elements. The uncertainty quantification module performs statistical analysis on the multi-set probability prediction sequence, calculates the prediction mean and standard deviation step-by-step, constructs confidence intervals based on the 3σ criterion, and outputs the calculated prediction mean, prediction standard deviation, and corresponding confidence intervals as the prediction results. In the reverse denoising process of the conditional diffusion model prediction module, meteorological physical constraints are introduced for gradient guidance.

[0105] In one embodiment of the present invention, a computer device is provided, comprising a processor and a memory. The memory stores a computer program, which includes program instructions. The processor executes the program instructions stored in the memory. The processor may be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), field-programmable gate arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. It is the computing and control core of the terminal, suitable for implementing one or more instructions, specifically suitable for loading and executing one or more instructions from a computer storage medium to achieve a corresponding method flow or corresponding function. The processor described in this embodiment of the present invention can be used to execute the operation of a meteorological probability prediction method based on a physical constraint and conditional diffusion model.

[0106] In one embodiment of the present invention, a storage medium is provided, specifically a computer-readable storage medium (Memory), which is a memory device in a computer device used to store programs and data. It is understood that the computer-readable storage medium here can include both the built-in storage medium in the computer device and extended storage media supported by the computer device. The computer-readable storage medium provides storage space that stores the operating system of the terminal. Furthermore, the storage space also stores one or more instructions suitable for loading and execution by a processor. These instructions can be one or more computer programs (including program code). It should be noted that the computer-readable storage medium here can be high-speed RAM (Random Access Memory) or non-volatile memory, such as at least one disk storage device. The processor can load and execute one or more instructions stored in the computer-readable storage medium to implement the corresponding steps of the meteorological probability prediction method based on the physical constraints and conditional diffusion model in the above embodiments.

[0107] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, optical storage, etc.) containing computer-usable program code.

[0108] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.

[0109] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.

[0110] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.

[0111] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A meteorological probability prediction method based on physical constraints and conditional diffusion models, characterized in that, include: Acquire historical data for the time to be predicted; wherein, the historical data includes meteorological data, power data of new energy power plants, and auxiliary data for a preset historical time period; the auxiliary data includes time characteristics and equipment status characteristics; Based on historical data of the time to be predicted, a trained meteorological probability prediction model is used to make a prediction and obtain the prediction result. The meteorological probability prediction model includes: a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module. The data preprocessing module inputs historical data and performs cleaning, normalization, and feature construction to obtain standardized time-series input data. The multimodal pre-trained encoder module inputs the standardized time-series input data and extracts features separately, using a cross-attention mechanism to weightedly fuse the extracted multimodal features to generate a multimodal conditional embedding. The conditional diffusion model prediction module, guided by the multimodal conditional embedding, performs forward noise addition and backward noise reduction processes to generate a multi-set probability prediction sequence for future meteorological elements. The uncertainty quantification module performs statistical analysis on the multi-set probability prediction sequence, calculates the prediction mean and standard deviation step-by-step, constructs confidence intervals based on the 3σ criterion, and outputs the calculated prediction mean, prediction standard deviation, and corresponding confidence intervals as the prediction results. In the reverse denoising process of the conditional diffusion model prediction module, meteorological physical constraints are introduced for gradient guidance.

2. The meteorological probability prediction method based on a physical constraint and conditional diffusion model according to claim 1, characterized in that, The multimodal pre-trained encoder module includes: a meteorological branch, a power branch, an auxiliary feature branch, and a fusion layer. The meteorological branch is used to input time-series meteorological data sequences from standardized time-series input data, extracting spatiotemporal features through convolutional layers to obtain meteorological feature embeddings. The power branch is used to input time-series power data sequences from standardized time-series input data, obtaining power feature embeddings through fully connected layers and time-series convolutional layers. The auxiliary feature branch is used to input time features and device status features, transforming them through fully connected layers to obtain auxiliary feature embeddings. The fusion layer uses a cross-attention mechanism for weighted fusion to generate multimodal conditional embeddings. The multimodal conditional embedding is represented as: ; ; ; ; In the formula, For multimodal conditional embedding; These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; , , These are meteorological feature embedding, power feature embedding, and auxiliary feature embedding, respectively. Indicates feature splicing; For the embedded dimension.

3. The meteorological probability prediction method based on a physical constraint and conditional diffusion model according to claim 1, characterized in that, In the reverse denoising process of the conditional diffusion model prediction module, the multimodal conditional embedding is mapped to key vectors and value vectors, and the noise samples of the current diffusion step are mapped to query vectors. The dependency relationship between the conditions and the noise samples is captured by cross-attention calculation. The mapping expression is: ; ; ; ; In the formula, These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; For the first Noise samples from the diffusion step; For multimodal conditional embedding; For the embedded dimension.

4. The meteorological probability prediction method based on a physical constraint and conditional diffusion model according to claim 1, characterized in that, The meteorological and physical constraints include: energy conservation constraints, wind speed field spatial continuity constraints, and irradiance diurnal rationality constraints.

5. The meteorological probability prediction method based on a physical constraint and conditional diffusion model according to claim 1, characterized in that, The training process of the meteorological probability prediction model includes a pre-training stage and a fine-tuning stage. The pre-training stage is used to learn the general fluid dynamics and atmospheric physical laws of the meteorological probability prediction model. The fine-tuning stage is used to fine-tune the pre-trained meteorological probability prediction model using a local fine-tuning dataset. In the fine-tuning phase, the corrected meteorological grid data is spliced ​​with the measured power data of the target power station and auxiliary data to form a localized fine-tuning dataset; a joint loss function combining noise prediction loss and power deviation loss is used to calculate the loss and update the model parameters, and training stops after the preset conditions are met.

6. A meteorological probability prediction system based on a physical constraint and conditional diffusion model, characterized in that, include: The historical data acquisition unit is used to acquire historical data for the time to be predicted; wherein, the historical data includes meteorological data, power data of new energy power plants, and auxiliary data for a preset historical time period; the auxiliary data includes time characteristics and equipment status characteristics; The prediction result acquisition unit is used to make predictions based on historical data of the time to be predicted, using a trained meteorological probability prediction model, and obtain prediction results. The meteorological probability prediction model includes: a data preprocessing module, a multimodal pre-trained encoder module, a conditional diffusion model prediction module, and an uncertainty quantification module. The data preprocessing module inputs historical data and performs cleaning, normalization, and feature construction to obtain standardized time-series input data. The multimodal pre-trained encoder module inputs the standardized time-series input data and extracts features separately, using a cross-attention mechanism to weightedly fuse the extracted multimodal features to generate a multimodal conditional embedding. The conditional diffusion model prediction module, guided by the multimodal conditional embedding, performs forward noise addition and backward noise reduction processes to generate a multi-set probability prediction sequence for future meteorological elements. The uncertainty quantification module performs statistical analysis on the multi-set probability prediction sequence, calculates the prediction mean and standard deviation step-by-step, constructs confidence intervals based on the 3σ criterion, and outputs the calculated prediction mean, prediction standard deviation, and corresponding confidence intervals as the prediction results. In the reverse denoising process of the conditional diffusion model prediction module, meteorological physical constraints are introduced for gradient guidance.

7. A meteorological probability prediction system based on a physical constraint and conditional diffusion model according to claim 6, characterized in that, The multimodal pre-trained encoder module includes: a meteorological branch, a power branch, an auxiliary feature branch, and a fusion layer. The meteorological branch is used to input time-series meteorological data sequences from standardized time-series input data, extracting spatiotemporal features through convolutional layers to obtain meteorological feature embeddings. The power branch is used to input time-series power data sequences from standardized time-series input data, obtaining power feature embeddings through fully connected layers and time-series convolutional layers. The auxiliary feature branch is used to input time features and device status features, transforming them through fully connected layers to obtain auxiliary feature embeddings. The fusion layer uses a cross-attention mechanism for weighted fusion to generate multimodal conditional embeddings. The multimodal conditional embedding is represented as: ; ; ; ; In the formula, For multimodal conditional embedding; These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; , , These are meteorological feature embedding, power feature embedding, and auxiliary feature embedding, respectively. Indicates feature splicing; For the embedded dimension.

8. A meteorological probability prediction system based on a physical constraint and conditional diffusion model according to claim 6, characterized in that, In the reverse denoising process of the conditional diffusion model prediction module, the multimodal conditional embedding is mapped to key vectors and value vectors, and the noise samples of the current diffusion step are mapped to query vectors. The dependency relationship between the conditions and the noise samples is captured by cross-attention calculation. The mapping expression is: ; ; ; ; In the formula, These are the query vector, key vector, and value vector, respectively. , , The learnable projection matrix has a dimension of . ; For the first Noise samples from the diffusion step; For multimodal conditional embedding; For the embedded dimension.

9. A meteorological probability prediction system based on a physical constraint and conditional diffusion model according to claim 6, characterized in that, The meteorological and physical constraints include: energy conservation constraints, wind speed field spatial continuity constraints, and irradiance diurnal rationality constraints.

10. A meteorological probability prediction system based on a physical constraint and conditional diffusion model according to claim 6, characterized in that, The training process of the meteorological probability prediction model includes a pre-training stage and a fine-tuning stage. The pre-training stage is used to learn the general fluid dynamics and atmospheric physical laws of the meteorological probability prediction model. The fine-tuning stage is used to fine-tune the pre-trained meteorological probability prediction model using a local fine-tuning dataset. In the fine-tuning phase, the corrected meteorological grid data is spliced ​​with the measured power data of the target power station and auxiliary data to form a localized fine-tuning dataset; a joint loss function combining noise prediction loss and power deviation loss is used to calculate the loss and update the model parameters, and training stops after the preset conditions are met.

11. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the meteorological probability prediction method based on the physical constraint and conditional diffusion model as described in any one of claims 1 to 5.

12. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the meteorological probability prediction method based on the physical constraint and conditional diffusion model as described in any one of claims 1 to 5.

13. A computer program product, characterized in that, It includes computer instructions, which, when executed by a processor, implement the steps of the meteorological probability prediction method based on a physical constraint and conditional diffusion model as described in any one of claims 1 to 5.