Wind power probability distribution prediction method and device based on quantum fusion diffusion condition variation, computer equipment and medium
Through the quantum fusion diffusion condition variation method, combined with a variety of quantum computing and deep learning technologies, the wind farm data is decomposed and predicted, solving the problem of imbalance in the calculation complexity and accuracy in the prediction of wind farm power probability distribution, and achieving efficient and accurate wind power power prediction and optimization scheduling strategies.
Patent Information
- Application Number
- CN202510666435.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-22
- Publication Date
- 2025-08-15
AI Technical Summary
The existing wind farm power probability distribution prediction methods have problems with imbalance in computational complexity and prediction accuracy, and the potential of quantum computing in generating prediction models has not been fully utilized.
The quantum fusion diffusion condition variation method is adopted to predict wind power and probability distribution prediction by performing average mode adaptive complete ensemble of wind power power data by the historical wind speed, wind direction, temperature, humidity, pressure and wind power power data of the wind farm.
It improves the accuracy and efficiency of wind power prediction, optimizes the calculation complexity of the prediction model, reduces energy consumption, and promotes the efficient utilization of wind power energy and overall power generation efficiency.
Smart Images

Figure CN120494579A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the fields of quantum computing, machine learning, artificial intelligence and new energy prediction, and involves a method of combining quantum computing with deep machine learning models and artificial intelligence, which is suitable for predicting the future probability distribution of wind farms in power systems. Background Art
[0002] Existing wind farm power probability distribution prediction methods have the problem of imbalance between computational complexity and prediction accuracy, or the problem of ignoring the potential of quantum computing in generating prediction models. Summary of the Invention
[0003] Based on this, it is necessary to provide a quantum fusion diffusion conditional variational wind power probability distribution prediction method, device, computer equipment, computer-readable storage medium and computer program product to address the above technical problems.
[0004] In a first aspect, the present application provides a method for predicting wind power probability distribution based on quantum fusion diffusion conditional variation. The method comprises:
[0005] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are taken as input, and the input is decomposed according to the mean mode adaptive complete ensemble empirical mode decomposition method to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method;
[0006] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power is predicted according to the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method;
[0007] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism. The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is obtained;
[0008] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as input. The probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
[0009] In a second aspect, the present application also provides a device for predicting wind power probability distribution based on quantum fusion diffusion conditional variation. The device comprises:
[0010] A data decomposition module is used to take the historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm as input, decompose the input according to the mean mode adaptive complete ensemble empirical mode decomposition method, and obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method;
[0011] The first parallel prediction module is used to take the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method as input, and perform wind power prediction based on the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method;
[0012] The second parallel prediction module is used to take the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method as input, and perform wind power prediction based on the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism to obtain the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism;
[0013] The probability distribution prediction module is used to take as input the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism, and predict the probability distribution of wind power based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
[0014] In a third aspect, the present application further provides a computer device. The computer device includes a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the following steps are performed:
[0015] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are taken as input, and the input is decomposed according to the mean mode adaptive complete ensemble empirical mode decomposition method to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method;
[0016] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power is predicted according to the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method;
[0017] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism. The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is obtained;
[0018] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as input. The probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
[0019] In a fourth aspect, the present application further provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the following steps:
[0020] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are taken as input, and the input is decomposed according to the mean mode adaptive complete ensemble empirical mode decomposition method to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method;
[0021] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power is predicted according to the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method;
[0022] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism. The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is obtained;
[0023] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as input. The probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
[0024] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program that, when executed by a processor, implements the following steps:
[0025] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are taken as input, and the input is decomposed according to the mean mode adaptive complete ensemble empirical mode decomposition method to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method;
[0026] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power is predicted according to the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method;
[0027] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism. The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is obtained;
[0028] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as input. The probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
[0029] The above-mentioned quantum fusion diffusion conditional variational wind power probability distribution prediction method, device, computer equipment, storage medium and computer program product, by taking the historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm as input, decomposing the input according to the mean mode adaptive complete set empirical mode decomposition method, and obtaining the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method; taking the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method as input, and predicting wind power according to the quantum generation diffusion method, and obtaining the wind power value predicted by the quantum generation diffusion method; taking the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method as input, and performing a quantum bidirectional recurrent gate based on the dual-stage attention mechanism The wind power is predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is obtained; the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as input, and the probability distribution of wind power is predicted according to the Transformer conditional variational autoencoder to obtain the probability distribution of wind power of the wind farm; the high-frequency noise in the historical data of the wind farm can be filtered out to improve the function and effect of data quality, improve the function and effect of prediction efficiency, reduce the energy consumption of prediction work, improve the prediction accuracy, optimize the scheduling strategy, and improve the overall power generation efficiency of the wind farm. It has the function and effect of accurately predicting power distribution and promoting the efficient use of wind power energy. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] Figure 1 It is a prediction framework diagram of the method of the present invention.
[0031] Figure 2 FIG. 1 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0032] In order to make the purpose, technical solutions and advantages of this application more clear, the following further describes this application in detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain this application and are not intended to limit this application.
[0033] In one embodiment, Figure 1As shown, a method for predicting wind power probability distribution based on quantum fusion diffusion conditional variation is provided. This embodiment uses the method applied to a terminal as an example. It is understandable that the method can also be applied to a server, or to a system including a terminal and a server, and implemented through the interaction between the terminal and the server. In this embodiment, the method includes the following steps:
[0034] Step (1) takes the historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm as input, decomposes the input according to the mean mode adaptive complete ensemble empirical mode decomposition method, and obtains the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method.
[0035] In step (1.1), white noise is added to the historical wind speed, wind direction, temperature, humidity, pressure, and wind power data of the wind farm to obtain the data sequence to be decomposed.
[0036] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are ;
[0037] The obtained data sequence to be decomposed is ; ; In the formula, the variable is the number of times white noise is added, , is the maximum number of times white noise is added; is the signal-to-noise ratio of the first decomposition of the empirical mode decomposition; is the zero mean unit variance added White noise; An operator representing the first modal component after empirical mode decomposition.
[0038] In step (1.2), the data sequence to be decomposed is subjected to empirical mode decomposition to obtain the first-stage residues and first-stage modal components of the average mode adaptive complete set empirical mode decomposition.
[0039] The first-stage residuals of the average mode adaptive complete set empirical mode decomposition are obtained for: ; The first stage modal components of the average mode adaptive complete set empirical mode decomposition obtained for: Where, represents the local mean function; The operator symbol representing the overall average; Represents the data sequence to be decomposed The value after local averaging operation; Indicates that for each data sequence to be decomposed The local average operation is performed, and then the overall average is calculated and the sum is calculated.
[0040] Step (1.3) is to perform empirical mode decomposition on the first stage residues of the mean mode adaptive complete set empirical mode decomposition to obtain the second stage residues and second stage modal components of the mean mode adaptive complete set empirical mode decomposition, and so on to obtain the second stage residues and second stage modal components of the mean mode adaptive complete set empirical mode decomposition. Stage residues and The stage modal components are used to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete ensemble empirical mode decomposition method.
[0041] The second-stage residue of the average mode adaptive complete set empirical mode decomposition is obtained as ;
[0042] The second stage modal components of the average mode adaptive complete set empirical mode decomposition are obtained for: Where, is the signal-to-noise ratio of the second stage of the mean mode adaptive complete ensemble empirical mode decomposition; represents the sum of the overall average after the local average operation of the data sequence to be decomposed in the second stage of the average mode adaptive complete set empirical mode decomposition; is the operator for the second-stage modal components of the mean modal adaptive complete ensemble empirical mode decomposition;
[0043] The average mode adaptive complete set empirical mode decomposition is obtained Phase residues for: ;
[0044] The average mode adaptive complete set empirical mode decomposition is obtained Phase modal component for: Where, and They are the average mode adaptive complete set empirical mode decomposition Stage and The signal-to-noise ratio of the stage; and They are the average mode adaptive complete set empirical mode decomposition Stage and stage residues; is the first step of the mean mode adaptive complete ensemble empirical mode decomposition Operators for phase modal components;
[0045] The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method is obtained for: ;in, is the first step of the mean mode adaptive complete ensemble empirical mode decomposition Phase modal components, is the first step of the mean mode adaptive complete ensemble empirical mode decomposition Phase residues.
[0046] The mean mode adaptive complete ensemble empirical mode decomposition method can filter out high-frequency noise in wind farm historical data and improve the function and effect of data quality.
[0047] In step (2), the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and wind power is predicted according to the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method.
[0048] Step (2.1), historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method Add noise to the data and get the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method with noise. , satisfying the given Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment hour, Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment Obey the mean , the variance is Gaussian distribution ,in, is the identity matrix, is The intensity of the Gaussian noise at time t.
[0049] Step (2.2), continuous use parameterized quantum circuit pair Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment Denoising, that is , and then perform quantum measurement to obtain the wind power value predicted by the quantum generation diffusion method ,in, are the parameters of the quantum denoising circuit, and They are time 0 and Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment and The quantum state data, and They are 1 moment and The denoising operator at the moment, is the quantum measurement operator, yes The conjugate transpose of .
[0050] Among them, parameterized quantum circuits include:
[0051] A quantum register consisting of multiple quantum bits;
[0052] At least one parameterized quantum gate layer, wherein the parameterized quantum gate layer comprises a plurality of single-qubit rotation gates and / or multi-qubit entanglement gates, wherein the single-qubit rotation gate comprises a rotation gate Rx( ), rotating door Ry around the Y axis ( ) or rotating door Rz around the Z axis ( ), the rotation angle To parameterize the trainable parameters of quantum circuits, i.e. the parameters of quantum denoising circuits;
[0053] At least one non-parametric quantum gate layer, wherein the non-parametric quantum gate layer includes fixed quantum gates, and the fixed quantum gates include at least one of a Hadamard gate, a Pauli-X gate, a Pauli-Y gate, a Pauli-Z gate, a CNOT gate, and a SWAP gate;
[0054] The measurement layer is configured to measure some or all of the quantum bits in the quantum register to obtain classical output.
[0055] The quantum generation diffusion method has the function and effect of improving prediction efficiency and reducing the energy consumption of prediction work.
[0056] In step (3), the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism to obtain the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism.
[0057] In step (3.1), the historical wind speed, wind direction, temperature, humidity, pressure, and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input and sequentially input into the self-attention mechanism and the bidirectional gated recurrent unit for prediction, thereby obtaining the wind power value predicted by the self-attention mechanism and the bidirectional gated recurrent unit.
[0058] Specifically: the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method are As input, it is input into the self-attention mechanism and the bidirectional gated recurrent unit for prediction, and the wind power value predicted by the self-attention mechanism and the bidirectional gated recurrent unit is obtained. This is the first stage of the quantum bidirectional recurrent gated unit method based on a two-stage attention mechanism.
[0059] The wind power value predicted by the self-attention mechanism and bidirectional gated recurrent unit for ,in, Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the self-attention mechanism is used to complete the empirical mode decomposition method of the average mode adaptive set The prediction results, is a bidirectional gated recurrent unit pair prediction results.
[0060] Among them, the self-attention mechanism includes:
[0061] Query matrix, key matrix and value matrix, used to perform linear transformation on the input sequence;
[0062] an attention score calculation unit configured to generate an attention score by calculating a dot product of a query matrix and a key matrix;
[0063] a scaling unit configured to scale the attention score, wherein the scaling factor is the square root of the dimension of the key matrix;
[0064] a masking unit that optionally applies a mask to prevent attention to specific locations in the sequence;
[0065] A normalization unit, configured to apply a softmax function to the scaled attention scores to generate attention weights;
[0066] A weighted summation unit is configured to perform weighted summation on the value matrix according to the attention weight to generate a context representation.
[0067] Among them, the bidirectional gated recurrent unit includes:
[0068] a forward gated recurrent unit layer configured to process an input sequence in time order, the forward gated recurrent unit layer comprising a plurality of gated recurrent units, each gated recurrent unit comprising a reset gate, an update gate, and a candidate hidden state calculation unit;
[0069] a reverse gated recurrent unit layer configured to process an input sequence in reverse time order, the reverse gated recurrent unit layer comprising a plurality of gated recurrent units, each gated recurrent unit comprising a reset gate, an update gate, and a candidate hidden state calculation unit;
[0070] The reset gate is configured to control the degree of influence of the hidden state of the previous time step on the current candidate hidden state;
[0071] The update gate is configured to control the update ratio of the hidden state of the previous time step and the current candidate hidden state to the current hidden state;
[0072] The output fusion layer is configured to concatenate or weightedly combine the hidden states of the forward gated recurrent unit layer and the backward gated recurrent unit layer at the same time step to generate an output of the bidirectional gated recurrent unit.
[0073] In step (3.2), a variational quantum circuit is used to encode the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, and the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the variational quantum circuit encoding are obtained; the wind power value predicted by the self-attention mechanism and the bidirectional gated recurrent unit and the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the variational quantum circuit encoding are input into the bidirectional gated recurrent unit for prediction, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the dual-stage attention mechanism is obtained.
[0074] Specifically, the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method is used by variational quantum line pairs Encode and obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after variational quantum line encoding ; The wind power value predicted by the self-attention mechanism and the bidirectional gated recurrent unit Historical wind speed, wind direction, temperature, humidity, pressure and wind power data encoded with variational quantum lines Input into the bidirectional gated recurrent unit for prediction, and obtain the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism . That is, the second stage of the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism.
[0075] The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism for ,in, Wind power values predicted by the self-attention mechanism and bidirectional gated recurrent unit Historical wind speed, wind direction, temperature, humidity, pressure and wind power data encoded with variational quantum lines The concatenated matrix, is a bidirectional gated recurrent unit pair prediction results.
[0076] Among them, the variational quantum circuit includes:
[0077] a qubit register, comprising at least one qubit for storing a quantum state;
[0078] The parameterized quantum gate layer includes at least one parameterized quantum gate, wherein the parameterized quantum gate includes a rotation gate RX around the X axis ( ), rotating door RY around the Y axis ( ), rotating door RZ around the Z axis ( ), wherein Trainable parameters for variational quantum circuits;
[0079] a non-parametric quantum gate layer, comprising at least one fixed quantum gate, wherein the fixed quantum gate comprises at least one of an X gate, a Y gate, a Z gate, a Hadamard gate, and a controlled NOT gate;
[0080] a measurement module, configured to measure the qubits in the qubit register and output a classical measurement result;
[0081] A classical-quantum interaction interface, configured to input the trainable parameter θ into the parameterized quantum gate layer and transmit the measurement result to the classical optimization module;
[0082] A classical optimization module configured to calculate a loss function based on the measurement results and update the trainable parameters by gradient descent, a heuristic algorithm, or an automatic differentiation mechanism .
[0083] Parameterized quantum circuits (PQC) and variational quantum circuits (VQC) are highly similar in nature. Both refer to quantum circuits composed of quantum gates with adjustable parameters and are widely used in quantum machine learning and quantum optimization. The main differences between the two lie in their technical focus and application scenario descriptions. Parameterized quantum circuits (PQC) tend to describe underlying technologies and are often found in literature on quantum algorithm design or hardware implementation, emphasizing the parameterized structure of the circuit itself. Variational quantum circuits (VQC) tend to describe application frameworks and are often found in quantum machine learning or quantum-classical hybrid computing scenarios, emphasizing their integration with classical optimization. Classical optimization modules, such as gradient descent and the Adam optimizer, are often explicitly included to form a closed loop from quantum forward propagation to classical backpropagation.
[0084] The quantum bidirectional recurrent gated unit method based on the dual-stage attention mechanism has the function and effect of improving prediction accuracy, optimizing scheduling strategies, and improving the overall power generation efficiency of wind farms.
[0085] In step (4), the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as inputs, and the probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
[0086] Specifically: the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method are , the wind power value predicted by the quantum generation diffusion method The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism As input, the probability distribution of wind power is predicted according to the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm .
[0087] In step (4.1), the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method are used as input and input into the Transformer to predict the wind power of the wind farm, thereby obtaining the wind power of the wind farm predicted by the Transformer.
[0088] Specifically, the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method are used As input, it is input into Transformer to predict the wind power of the wind farm, and the wind power of the wind farm predicted by Transformer is obtained. .
[0089] Among them, Transformer includes encoder and decoder;
[0090] The encoder includes multiple encoder layers, each encoder layer includes a multi-head self-attention mechanism and a feedforward neural network;
[0091] The decoder includes multiple decoder layers, each decoder layer includes a multi-head self-attention mechanism, an encoder-decoder attention mechanism and a feedforward neural network;
[0092] The multi-head self-attention mechanism includes multiple parallel attention heads, each of which performs a linear transformation on the input through the query matrix, key matrix and value matrix, and calculates the attention weight;
[0093] The encoder-decoder attention mechanism allows the decoder to pay attention to the output of the encoder;
[0094] The feedforward neural network includes two linear transformation layers and a nonlinear activation function;
[0095] The encoder and decoder also include residual connections and layer normalization operations.
[0096] In step (4.2), the wind power of the wind farm predicted by Transformer, the wind power value predicted by the quantum generation diffusion method, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are input into the conditional variational autoencoder to predict the probability distribution of wind power, and the probability distribution of wind power of the wind farm is obtained.
[0097] Specifically: Transformer predicts the wind power of the wind farm , the wind power value predicted by the quantum generation diffusion method The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism As input, the probability distribution of wind power is input into the conditional variational autoencoder to obtain the wind power of the wind farm predicted by the given Transformer. , the wind power value predicted by the quantum generation diffusion method The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism Spliced Matrix When the wind power of the wind farm obeys the mean value of the wind power predicted by the conditional variational autoencoder , variance is the wind power variance predicted by the conditional variational autoencoder Gaussian distribution , that is, the probability distribution of wind power of the wind farm is obtained.
[0098] Among them, the conditional variational autoencoder includes:
[0099] an encoder module comprising an input layer, at least one hidden layer, and a parameter generation layer, wherein the input layer is configured to receive input data and conditional information, and the parameter generation layer is configured to output a mean vector and a logarithmic variance vector of a latent space;
[0100] a reparameterization unit configured to generate latent variables based on the mean vector and the log-variance vector;
[0101] a decoder module comprising a latent variable input layer, a condition information input layer, at least one fusion layer, and an output layer, wherein the fusion layer is configured to perform feature fusion of the latent variable and the condition information;
[0102] wherein at least one layer in the encoder module and / or the decoder module adopts any one of a conditional batch normalization layer, a gating mechanism layer, or an attention mechanism layer, wherein the conditional batch normalization layer is configured to adjust a normalization parameter based on the condition information, the gating mechanism layer is configured to control information flow based on the condition information, and the attention mechanism layer is configured to calculate a weight distribution of input features based on the condition information;
[0103] At least one layer in the encoder module and / or decoder module adopts a residual connection structure or a skip connection structure to enhance feature transfer.
[0104] The Transformer conditional variational autoencoder has the function and effect of accurately predicting power distribution and promoting the efficient utilization of wind power energy.
[0105] The obtained probability distribution of wind power of the wind farm is input into the robust economic dispatch system of the interconnected power system for robust economic dispatch, which can ensure that the interconnected power system can operate safely and stably even when there is a large wind power prediction error.
[0106] The present invention has the following advantages and effects compared to the prior art:
[0107] (1) The existing wind power probability distribution prediction method based on neural network quantile regression cannot balance the computational complexity and prediction accuracy, while the present invention can balance the computational complexity and prediction accuracy.
[0108] (2) Compared with the existing technology that only uses deep learning to predict the probability distribution of wind farm power, the present invention can integrate quantum computing and deep learning networks and successfully solve the problem of predicting the probability distribution of wind farm power.
[0109] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 2 As shown. The computer device includes a processor, memory, an input / output interface, a communication interface, a display unit, and an input device. The processor, memory, and input / output interface are connected via a system bus, and the communication interface, display unit, and input device are connected to the system bus via the input / output interface. The processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and internal memory. The non-volatile storage medium stores an operating system and computer programs. The internal memory provides an environment for the operation of the operating system and computer programs in the non-volatile storage medium. The input / output interface of the computer device is used to exchange information between the processor and external devices. The communication interface of the computer device is used to communicate with external terminals via wired or wireless means, and the wireless means can be achieved via Wi-Fi, mobile cellular networks, NFC (near-field communication), or other technologies. When executed by the processor, the computer program implements a method for predicting wind power probability distribution using quantum fusion diffusion conditional variation. The display unit of the computer device is used to produce a visually visible image and can be a display screen, a projection device, or a virtual reality imaging device. The display screen can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a button, trackball or touchpad set on the computer device casing, or an external keyboard, touchpad or mouse.
[0110] Those skilled in the art will understand that Figure 2 The structure given is merely a block diagram of a portion of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than shown in the figure, or combine certain components, or have a different component arrangement.
[0111] In one embodiment, a computer device is further provided, including a memory and a processor. The memory stores a computer program, and the processor implements the steps in the above method embodiments when executing the computer program.
[0112] In one embodiment, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps in the above-mentioned method embodiments are implemented.
[0113] In one embodiment, a computer program product is provided, including a computer program, which implements the steps in the above method embodiments when executed by a processor.
[0114] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties, and the collection, use and processing of relevant data must comply with the relevant laws, regulations and standards of relevant countries and regions.
[0115] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the above-mentioned embodiments. In particular, any reference to memory, database, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The databases involved in the various embodiments provided herein may include at least one of a relational database and a non-relational database. Non-relational databases may include, but are not limited to, distributed databases based on blockchains. The processors involved in the various embodiments provided herein may be, but are not limited to, general-purpose processors, central processing units (CPUs), graphics processing units (GPUs), digital signal processors (DSPs), programmable logic devices (PLDs), data processing logic devices based on quantum computing, and the like.
[0116] The technical features of the above embodiments can be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0117] The above-described embodiments merely represent several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present application. It should be noted that a person of ordinary skill in the art may make various modifications and improvements without departing from the spirit of the present application, and these modifications and improvements fall within the scope of protection of the present application. Therefore, the scope of protection of the present application shall be determined by the appended claims.
Claims
1. A quantum fusion diffusion conditional variational wind power probability distribution prediction method, characterized by: The method comprises: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are taken as input, and the input is decomposed according to the mean mode adaptive complete ensemble empirical mode decomposition method to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method; The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power is predicted according to the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method; The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and the wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism. The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is obtained; The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as input. The probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
2. The method for predicting wind power probability distribution based on quantum fusion diffusion conditional variation according to claim 1 is characterized in that: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm are taken as input, and the input is decomposed according to the mean mode adaptive complete ensemble empirical mode decomposition method to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method as follows: Add white noise to the historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm to obtain the data sequence to be decomposed; Performing empirical mode decomposition on the data sequence to be decomposed to obtain the first-stage residues and the first-stage modal components of the average mode adaptive complete set empirical mode decomposition; The first-stage residues of the mean mode adaptive complete set empirical mode decomposition are subjected to empirical mode decomposition to obtain the second-stage residues and second-stage modal components of the mean mode adaptive complete set empirical mode decomposition. Similarly, the second-stage residues and second-stage modal components of the mean mode adaptive complete set empirical mode decomposition are obtained. Stage residues and The stage modal components are used to obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete ensemble empirical mode decomposition method.
3. The method for predicting wind power probability distribution based on quantum fusion diffusion conditional variation according to claim 1 is characterized in that: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and wind power is predicted according to the quantum generation diffusion method. The wind power value predicted by the quantum generation diffusion method is: Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method Add noise to the data and get the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method with noise. , satisfying the given Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment hour, Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment The mean is , the variance is Gaussian distribution ,in, is the identity matrix, is The intensity of the Gaussian noise at time t; Continuous adoption parameterized quantum circuit pair Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment Denoising, that is , and then perform quantum measurement to obtain the wind power value predicted by the quantum generation diffusion method ,in, are the parameters of the quantum denoising circuit, and They are time 0 and Historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the noisy average mode adaptive complete set empirical mode decomposition method at the moment and The quantum state data, and They are 1 moment and The denoising operator at the moment, is the quantum measurement operator, yes The conjugate transpose of Among them, parameterized quantum circuits include: A quantum register consisting of multiple quantum bits; At least one parameterized quantum gate layer, wherein the parameterized quantum gate layer comprises a plurality of single-qubit rotation gates and / or multi-qubit entanglement gates, wherein the single-qubit rotation gate comprises a rotation gate Rx( ), rotating door Ry around the Y axis ( ) or rotating door Rz around the Z axis ( ), the rotation angle To parameterize the trainable parameters of quantum circuits, i.e. the parameters of quantum denoising circuits; At least one non-parametric quantum gate layer, wherein the non-parametric quantum gate layer includes fixed quantum gates, and the fixed quantum gates include at least one of a Hadamard gate, a Pauli-X gate, a Pauli-Y gate, a Pauli-Z gate, a CNOT gate, and a SWAP gate; The measurement layer is configured to measure some or all of the quantum bits in the quantum register to obtain classical output.
4. The method for predicting wind power probability distribution based on quantum fusion diffusion conditional variation according to claim 1 is characterized in that: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input, and wind power prediction is performed according to the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism. The wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism is: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input and sequentially input into the self-attention mechanism and bidirectional gated recurrent unit for prediction, and the wind power value predicted by the self-attention mechanism and bidirectional gated recurrent unit is obtained; A variational quantum circuit is used to encode the historical wind speed, wind direction, temperature, humidity, pressure, and wind power data after the mean mode adaptive complete set empirical mode decomposition method, and the historical wind speed, wind direction, temperature, humidity, pressure, and wind power data after the variational quantum circuit encoding are obtained; the wind power value predicted by the self-attention mechanism and the bidirectional gated recurrent unit and the historical wind speed, wind direction, temperature, humidity, pressure, and wind power data after the variational quantum circuit encoding are input into the bidirectional gated recurrent unit for prediction, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the dual-stage attention mechanism is obtained; Among them, the self-attention mechanism includes: Query matrix, key matrix and value matrix, used to perform linear transformation on the input sequence; an attention score calculation unit configured to generate an attention score by calculating a dot product of a query matrix and a key matrix; a scaling unit configured to scale the attention score, wherein the scaling factor is the square root of the dimension of the key matrix; a masking unit that optionally applies a mask to prevent attention to specific locations in the sequence; A normalization unit, configured to apply a softmax function to the scaled attention scores to generate attention weights; a weighted summation unit configured to perform weighted summation on the value matrix according to the attention weights to generate a context representation; Among them, the bidirectional gated recurrent unit includes: a forward gated recurrent unit layer configured to process an input sequence in time order, the forward gated recurrent unit layer comprising a plurality of gated recurrent units, each gated recurrent unit comprising a reset gate, an update gate, and a candidate hidden state calculation unit; a reverse gated recurrent unit layer configured to process an input sequence in reverse time order, the reverse gated recurrent unit layer comprising a plurality of gated recurrent units, each gated recurrent unit comprising a reset gate, an update gate, and a candidate hidden state calculation unit; The reset gate is configured to control the degree of influence of the hidden state of the previous time step on the current candidate hidden state; The update gate is configured to control the update ratio of the hidden state of the previous time step and the current candidate hidden state to the current hidden state; an output fusion layer configured to concatenate or weightedly combine the hidden states of the forward gated recurrent unit layer and the backward gated recurrent unit layer at the same time step to generate an output of the bidirectional gated recurrent unit; Among them, the variational quantum circuit includes: a qubit register, comprising at least one qubit for storing a quantum state; The parameterized quantum gate layer includes at least one parameterized quantum gate, wherein the parameterized quantum gate includes a rotation gate RX around the X axis ( ), rotating door RY around the Y axis ( ), rotating door RZ around the Z axis ( ), wherein Trainable parameters for variational quantum circuits; a non-parametric quantum gate layer, comprising at least one fixed quantum gate, wherein the fixed quantum gate comprises at least one of an X gate, a Y gate, a Z gate, a Hadamard gate, and a controlled NOT gate; a measurement module, configured to measure the qubits in the qubit register and output a classical measurement result; A classical-quantum interaction interface, configured to input the trainable parameter θ into the parameterized quantum gate layer and transmit the measurement result to the classical optimization module; A classical optimization module configured to calculate a loss function based on the measurement results and update the trainable parameters by gradient descent, a heuristic algorithm, or an automatic differentiation mechanism .
5. The method for predicting wind power probability distribution based on quantum fusion diffusion conditional variation according to claim 1 is characterized in that: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are used as inputs, and the probability distribution of wind power is predicted based on the Transformer conditional variational autoencoder. The probability distribution of wind power of the wind farm is obtained as follows: The historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method are used as input and input into the Transformer to predict the wind power of the wind farm, and the wind power predicted by the Transformer is obtained; The wind power of the wind farm predicted by Transformer, the wind power value predicted by the quantum generation diffusion method, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism are input into the conditional variational autoencoder to predict the probability distribution of wind power, and the probability distribution of wind power of the wind farm is obtained; Among them, Transformer includes encoder and decoder; The encoder includes multiple encoder layers, each encoder layer includes a multi-head self-attention mechanism and a feedforward neural network; The decoder includes multiple decoder layers, each decoder layer includes a multi-head self-attention mechanism, an encoder-decoder attention mechanism and a feedforward neural network; The multi-head self-attention mechanism includes multiple parallel attention heads, each of which performs a linear transformation on the input through the query matrix, key matrix and value matrix, and calculates the attention weight; The encoder-decoder attention mechanism allows the decoder to pay attention to the output of the encoder; The feedforward neural network includes two linear transformation layers and a nonlinear activation function; The encoder and decoder also include residual connections and layer normalization operations; Among them, the conditional variational autoencoder includes: an encoder module comprising an input layer, at least one hidden layer, and a parameter generation layer, wherein the input layer is configured to receive input data and conditional information, and the parameter generation layer is configured to output a mean vector and a logarithmic variance vector of a latent space; a reparameterization unit configured to generate latent variables based on the mean vector and the log-variance vector; a decoder module comprising a latent variable input layer, a condition information input layer, at least one fusion layer, and an output layer, wherein the fusion layer is configured to perform feature fusion of the latent variable and the condition information; wherein at least one layer in the encoder module and / or the decoder module adopts any one of a conditional batch normalization layer, a gating mechanism layer, or an attention mechanism layer, wherein the conditional batch normalization layer is configured to adjust a normalization parameter based on the condition information, the gating mechanism layer is configured to control information flow based on the condition information, and the attention mechanism layer is configured to calculate a weight distribution of input features based on the condition information; At least one layer in the encoder module and / or decoder module adopts a residual connection structure or a skip connection structure to enhance feature transfer.
6. A quantum fusion diffusion conditional variational wind power probability distribution prediction device, characterized in that: The device comprises: A data decomposition module is used to take the historical wind speed, wind direction, temperature, humidity, pressure and wind power data of the wind farm as input, decompose the input according to the mean mode adaptive complete ensemble empirical mode decomposition method, and obtain the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete ensemble empirical mode decomposition method; The first parallel prediction module is used to take the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the average mode adaptive complete set empirical mode decomposition method as input, and perform wind power prediction based on the quantum generation diffusion method to obtain the wind power value predicted by the quantum generation diffusion method; The second parallel prediction module is used to take the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method as input, and perform wind power prediction based on the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism to obtain the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism; The probability distribution prediction module is used to take as input the historical wind speed, wind direction, temperature, humidity, pressure and wind power data after the mean mode adaptive complete set empirical mode decomposition method, the wind power value predicted by the quantum generation diffusion method, and the wind power value predicted by the quantum bidirectional recurrent gated unit method based on the two-stage attention mechanism, and predict the probability distribution of wind power based on the Transformer conditional variational autoencoder to obtain the probability distribution of wind power in the wind farm.
7. A computer device comprising a memory and a processor, wherein the memory stores a computer program, wherein: When the processor executes the computer program, the steps of the wind power probability distribution prediction method based on quantum fusion diffusion conditional variation as described in any one of claims 1 to 5 are implemented.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the wind power probability distribution prediction method based on quantum fusion diffusion conditional variation as claimed in any one of claims 1 to 5 are implemented.