New energy photovoltaic power station power generation prediction method and system
By introducing attention mechanism and gating unit graph convolution networks in the power prediction of power generation of new energy photovoltaic power plants, the problems of selection complexity and model complexity are solved in the historical similarity, and the accuracy of prediction and model flexibility are improved.
Patent Information
- Application Number
- CN202411446886.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-16
- Publication Date
- 2025-04-04
AI Technical Summary
The existing deep learning methods have the complexity of selecting historical similar days in the target prediction day and the problem that graph convolutional networks need to redesign the network architecture when adding long and short-term memory.
By introducing an attention mechanism to calculate attention coefficients for sample data, a learnable adjacency matrix is constructed, and gated units are introduced in the graph convolutional network to dynamically update the attention coefficient and edge weights, enhancing the model's expression ability and ability to capture long and short-term memory.
It improves the accuracy of power prediction of power generation of new energy photovoltaic power stations, simplifies the acquisition of historical data information, reduces model complexity, and improves the accuracy of prediction tasks.
Smart Images

Figure CN119765252A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of graph convolutional neural networks, and in particular to a method and system for predicting power generation of a new energy photovoltaic power station. Background Art
[0002] Since renewable energy generation is affected by weather and is intermittent, random, and volatile, in order to improve the utilization efficiency of renewable energy and optimize the dispatch of power systems, in recent years, the application of deep learning in renewable energy generation power forecasting has received widespread attention. Researchers use deep learning models, such as recurrent neural networks (RNN), long short-term memory networks (LSTM), and convolutional neural networks (CNN), combined with historical power generation data, meteorological data, and other multi-source information, to accurately predict renewable energy generation power. These models can better capture time series and spatiotemporal characteristics, improve prediction accuracy, and provide important support for the dispatch and operation of renewable energy.
[0003] Graph convolutional networks have attracted much attention in recent years. They are a neural network model specifically designed to process graph data. Since graph structured data is widely used in social networks, bioinformatics, recommendation systems and other fields, the rise of graph convolutional networks fills the gap in traditional neural networks in processing unstructured data. Graph convolutional networks can effectively capture the complex relationships and global structural information between nodes, providing new ideas and tools for the analysis and prediction of graph data. Applying graph convolutional networks to the prediction of renewable energy power generation can model unstructured data and effectively capture the relationship between nodes in topological graph data. It can also solve the problem of feature and model mismatch caused by the application of traditional deep learning models such as convolutional neural networks. Some studies have used relatively complex methods to select historical similar days for the target prediction day. By introducing an attention mechanism into the graph convolution operation, weights can be dynamically assigned to the neighbors of each node, the relationship between nodes can be captured more flexibly, and the information of more important nodes, i.e., similar node information, can be obtained. At the same time, the expression ability and flexibility of the model can be further enhanced. In addition, graph convolutional networks lack the ability to capture long and short-term memory. When processing photovoltaic power generation time series data, long and short-term memory needs to be added to enhance the model. Most existing studies choose to connect to long and short-term memory networks. However, the use of long and short-term memory networks will increase the complexity of the model and require the network architecture to be redesigned to adapt to the input and output of long and short-term memory networks.
[0004] The existing deep learning methods used in the prediction of power generation of new energy photovoltaic power stations have the following problems: (1) The method of selecting related historical similar days for the target prediction day to obtain historical data information is relatively complicated; (2) When adding long-term and short-term memory to the graph convolutional network, the traditional recurrent neural network needs to redesign the network architecture to adapt to the input and output. It can be seen that the application of graph convolutional networks in the prediction of power generation of new energy needs further research and development. Summary of the invention
[0005] The technical problem to be solved by the present invention is how to improve the accuracy of power generation prediction of new energy photovoltaic power stations.
[0006] The present invention solves the above technical problems through the following technical solutions: A method for predicting the power generation of a new energy photovoltaic power station, comprising the following steps:
[0007] Step 1: construct weather characteristic data of the sample set based on meteorological conditions, and preprocess the weather characteristic data to obtain sample set characteristic data H;
[0008] Step 2: Consider each sample in the sample set as a node in the topological graph, calculate the attention coefficient between the node features of every two nodes based on the sample set feature data H, use the attention coefficient between the connected nodes as the edge weight, build a topological graph for each node, and obtain the adjacency matrix A;
[0009] Step 3: Add self-loops to the adjacency matrix A to obtain the matrix Pair Matrix The edge weight information learned in the smoothing process is used to obtain the adjacency matrix The sample set feature data H and the adjacency matrix The input is fed into the graph convolutional network with the gated unit. After multiple iterations of training, when the loss function is minimized, the training is stopped to obtain a trained graph convolutional network.
[0010] Step 4: Input the target node to be predicted into the trained graph convolutional network to obtain the power generation power of the target node.
[0011] Beneficial effects: By designing and introducing an attention mechanism to calculate the attention coefficient for sample data and construct a learnable adjacency matrix, similar historical data can obtain higher attention weights. It aims to model the relationship between spatiotemporal data in a simple, easy and effective way, and pass messages to the nodes in the topological graph through multi-layer graph convolutional network layers. During the training process, the learnable attention coefficient is updated, and the neighbor features are acquired and aggregated to update the features of the target node. The effective data information of historical samples is integrated for the target node. At the same time, the long and short-term memory is captured through the gating signal to enhance the performance of the graph convolution model and improve the accuracy of the prediction task.
[0012] Preferably, the meteorological conditions in step one include: precipitation predicted by the weather forecast and natural environment data, and the natural environment data includes surface irradiance, temperature, humidity and wind speed.
[0013] Preferably, the calculation formula of the attention coefficient between the node features of every two nodes in step 2 is:
[0014] att ij=Linear([Wh i ||Wh j ]) (1)
[0015] In formula (1), att ij represents the attention coefficient between the node features of the connected nodes i and j, h i represents the node feature of the i-th node, h j represents the node feature of the j-th node, Linear represents the fully connected layer, and W represents the learnable weight matrix.
[0016] Beneficial effect: By using the similarity coefficient, i.e., the attention coefficient, as the edge weight of the topological graph, the connection relationship between nodes can be automatically learned and optimized. When transmitting messages, the target node can pay more attention to the neighboring nodes with large attention weights and capture more effective information.
[0017] Preferably, the adjacency matrix in step 3 is The calculation process is:
[0018]
[0019] In formula (2), A represents the adjacency matrix, I represents the diagonal matrix, and Softmax represents the normalization operation.
[0020]
[0021] Preferably, in step 3, the sample set feature data H and the adjacency matrix The computational process of the graph convolutional network inputted with the gating signal includes:
[0022] 3.1. Combine the sample set feature data H and the adjacency matrix Input into the multi-layer graph neural network to pass the message to the sample set feature data H, and the calculation formula is:
[0023]
[0024] In formula (3), M l represents the node information updated by graph convolution, l represents the lth layer network, σ is the nonlinear activation function, H l-1 represents the output of the l-1th layer, W l is the weight parameter matrix of the lth layer;
[0025] 3.2. Update the node information M obtained through graph convolution l Input the gated unit and get the output H of the lth layer l , the calculation formula is:
[0026]
[0027] In formula (4), V l is the trainable parameter matrix of the lth layer, c represents the bias term, represents the activation function, Denotes the Hadamard product.
[0028] Beneficial effects: The present invention introduces a gating mechanism, redesigns the calculation of the graph convolution layer, and directly applies the gating mechanism to the graph convolution operation process, without the need to stack deep learning models and additional loop structures. At the same time, the gated information calculation structure is simpler, does not include designs such as update gates and reset gates, and only includes an input gate, has low computational overhead, and can be better integrated into the model. It enhances model performance through simple calculations. On the one hand, it dynamically selects and amplifies features to better capture local information. On the other hand, it fuses local and global information on different graph convolution layers to better handle long-distance dependencies. In addition, introducing the gating mechanism into the graph convolution layer calculation can maintain the distinguishability of node features, thereby alleviating the over-smoothing problem to a certain extent, while directly connecting a recurrent neural network after the graph convolution model to capture long short-term memory cannot help the over-smoothing problem in the graph convolution operation.
[0029] The present invention also provides a new energy photovoltaic power station power generation prediction system, comprising:
[0030] A data preprocessing module is used to construct weather characteristic data of a sample set based on meteorological conditions, and preprocess the weather characteristic data to obtain sample set characteristic data H;
[0031] The adjacency matrix construction module is used to regard each sample in the sample set as a node in the topological graph, calculate the attention coefficient between the node features of every two nodes based on the sample set feature data H, use the attention coefficient between the connected nodes as the edge weight, construct a topological graph for each node, and obtain the adjacency matrix A;
[0032] The training module is used to add self-loops to the adjacency matrix A to obtain the matrix Pair Matrix The edge weight information learned in the smoothing process is used to obtain the adjacency matrix The sample set feature data H and the adjacency matrix The input is fed into the graph convolutional network with the gated unit. After multiple iterations of training, when the loss function is minimized, the training is stopped to obtain a trained graph convolutional network.
[0033] The prediction module is used to input the target node to be predicted into the trained graph convolutional network to obtain the power generation power of the target node.
[0034] Preferably, the meteorological conditions in the data preprocessing module include: precipitation predicted by the weather forecast and natural environment data, and the natural environment data includes surface irradiance, temperature, humidity and wind speed.
[0035] Preferably, the calculation formula for the attention coefficient between the node features of every two nodes in the adjacency matrix construction module is:
[0036] att ij =Linear([Wh i ||Wh j ]) (1)
[0037] In formula (1), att ij represents the attention coefficient between the node features of the connected nodes i and j, h i represents the node feature of the i-th node, h j represents the node feature of the j-th node, Linear represents the fully connected layer, and W represents the learnable weight matrix.
[0038] Preferably, the adjacency matrix in the training module The calculation process is:
[0039]
[0040] In formula (2), A represents the adjacency matrix, I represents the diagonal matrix, and Softmax represents the normalization operation.
[0041]
[0042] Preferably, in the training module, the sample set feature data H and the adjacency matrix The computational process of the graph convolutional network inputted with the gating signal includes:
[0043] 3.1. Combine the sample set feature data H and the adjacency matrix Input into the multi-layer graph neural network to pass the message to the sample set feature data H, and the calculation formula is:
[0044]
[0045] In formula (3), M l represents the node information updated by graph convolution, l represents the lth layer network, σ is the nonlinear activation function, H l-1 represents the output of the l-1th layer, W l is the weight parameter matrix of the lth layer;
[0046] 3.2. Update the node information M obtained through graph convolution l Input the gated unit and get the output H of the lth layerl , the calculation formula is:
[0047]
[0048] In formula (4), V l is the trainable parameter matrix of the lth layer, c represents the bias term, represents the activation function, Denotes the Hadamard product. BRIEF DESCRIPTION OF THE DRAWINGS
[0049] Figure 1 A flow chart of a method for predicting power generation of a new energy photovoltaic power station provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0050] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the technical solution of the present invention is clearly and completely described below in combination with specific embodiments and with reference to the accompanying drawings. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0051] Example 1
[0052] like Figure 1 As shown, this embodiment provides a method for predicting the power generation of a new energy photovoltaic power station, comprising the following steps:
[0053] Step 1: construct weather characteristic data of the sample set based on meteorological conditions, and preprocess the weather characteristic data to obtain the sample set characteristic data H; meteorological conditions include: precipitation predicted by weather forecasts and natural environment data, and the natural environment data includes surface irradiance, temperature, humidity and wind speed.
[0054] Step 2: Consider each sample in the sample set as a node in the topological graph, calculate the attention coefficient between the node features of every two nodes based on the sample set feature data H, use the attention coefficient between the connected nodes as the edge weight, build a topological graph for each node, and obtain the adjacency matrix A;
[0055] The calculation formula of the attention coefficient between the node features of every two nodes is:
[0056] att ij =Linear([Wh i ||Wh j ]) (1)
[0057] In formula (1), att ijrepresents the attention coefficient between the node features of the connected nodes i and j, h i represents the node feature of the i-th node, h j represents the node feature of the j-th node, Linear represents the fully connected layer, and W represents the learnable weight matrix.
[0058] By introducing an attention mechanism into the graph convolution operation, the present invention can dynamically assign weights to the neighbors of each node, more flexibly capture the relationship between nodes, obtain the information of more important nodes, that is, similar node information, and further enhance the expressiveness and flexibility of the model.
[0059] Step 3: Add self-loops to the adjacency matrix A to obtain the matrix Pair Matrix The edge weight information learned in the smoothing process is used to obtain the adjacency matrix The sample set feature data H and the adjacency matrix The input is fed into the graph convolutional network with the gated unit. After multiple iterations of training, when the loss function is minimized, the training is stopped to obtain a trained graph convolutional network.
[0060] Adjacency Matrix The calculation process is:
[0061]
[0062] In formula (2), A represents the adjacency matrix, I represents the diagonal matrix, and Softmax represents the normalization operation.
[0063]
[0064] The sample set feature data H and the adjacency matrix The computational process of the graph convolutional network inputted with the gating signal includes:
[0065] 3.1. Combine the sample set feature data H and the adjacency matrix Input into the multi-layer graph neural network to pass the message to the sample set feature data H, and the calculation formula is:
[0066]
[0067] In formula (3), M l represents the node information updated by graph convolution, l represents the lth layer network, σ is the nonlinear activation function, H l-1 represents the output of the l-1th layer, W l is the weight parameter matrix of the lth layer;
[0068] 3.2. Update the node information M obtained through graph convolution lInput the gated unit and get the output H of the lth layer l , the calculation formula is:
[0069]
[0070] In formula (4), V l is the trainable parameter matrix of the lth layer, c represents the bias term, represents the activation function, Denotes the Hadamard product.
[0071] The present invention adds a dropout layer with a rate of 0.6 after each graph convolutional network layer, and the node features of the last layer are softmaxed to obtain the final prediction result. The number of hidden nodes in the middle layer of the graph convolutional network layer is set to 16, the feature dimension of the last layer output node is 1, and the feature value is the prediction result.
[0072] The early-stop method is used for iteration in the iterative training process. The learning rate of the model is set to 0.005 and the maximum number of iterations is 10000. During the training process, the validation set result is used as the stopping criterion. If the validation set loss does not decrease within 100 epochs, the training is stopped and the model with the smallest validation set loss is saved as the test model. The training process uses 10 groups of random divisions to generate training sets. Each group is trained and tested once, and the average accuracy of 10 trainings is used as the test result.
[0073] Step 4: Input the target node to be predicted into the trained graph convolutional network to obtain the power generation power of the target node.
[0074] The present invention starts from two perspectives: in order to better obtain historical data for prediction on the target prediction day, and to design an overall end-to-end graph convolutional network for new energy photovoltaic power generation prediction. By designing and introducing an attention mechanism to calculate the attention coefficient for sample data, a learnable adjacency matrix is constructed, so that similar historical data obtains a higher attention weight. The invention aims to model the relationship between spatiotemporal data in a simple, easy and effective way, pass messages to nodes in the topological graph through multi-layer graph convolutional network layers, and update the learnable attention coefficient during the training process. The neighbor features are acquired in a focused manner and aggregated to update the features of the target node, and the effective data information of the historical samples is integrated for the target node. At the same time, the long and short-term memory is captured through the gating signal to enhance the performance of the graph convolutional model and improve the accuracy of the prediction task.
[0075] Example 2
[0076] The present invention also provides a new energy photovoltaic power station power generation prediction system, comprising:
[0077] The data preprocessing module is used to construct the weather characteristic data of the sample set based on the meteorological conditions, and preprocess the weather characteristic data to obtain the sample set characteristic data H; the precipitation predicted by the weather forecast and the natural environment data, the natural environment data including surface irradiance, temperature, humidity and wind speed.
[0078] The adjacency matrix construction module is used to regard each sample in the sample set as a node in the topological graph, calculate the attention coefficient between the node features of every two nodes based on the sample set feature data H, use the attention coefficient between the connected nodes as the edge weight, construct a topological graph for each node, and obtain the adjacency matrix A;
[0079] The calculation formula of the attention coefficient between the node features of every two nodes is:
[0080] att ij =Linear([Wh i ||Wh j ]) (1)
[0081] In formula (1), att ij represents the attention coefficient between the node features of the connected nodes i and j, h i represents the node feature of the i-th node, h j represents the node feature of the j-th node, Linear represents the fully connected layer, and W represents the learnable weight matrix.
[0082] The training module is used to add self-loops to the adjacency matrix A to obtain the matrix Pair Matrix The edge weight information learned in the smoothing process is used to obtain the adjacency matrix The sample set feature data H and the adjacency matrix The input is fed into the graph convolutional network with the gated unit. After multiple iterations of training, when the loss function is minimized, the training is stopped to obtain a trained graph convolutional network.
[0083] Adjacency Matrix The calculation process is:
[0084]
[0085] In formula (2), A represents the adjacency matrix, I represents the diagonal matrix, and Softmax represents the normalization operation.
[0086]
[0087] The sample set feature data H and the adjacency matrix The computational process of the graph convolutional network inputted with the gating signal includes:
[0088] 3.1. Combine the sample set feature data H and the adjacency matrix Input into the multi-layer graph neural network to pass the message to the sample set feature data H, and the calculation formula is:
[0089]
[0090] In formula (3), M l represents the node information updated by graph convolution, l represents the lth layer network, σ is the nonlinear activation function, H l-1 represents the output of the l-1th layer, W l is the weight parameter matrix of the lth layer;
[0091] 3.2. Update the node information M obtained through graph convolution l Input the gated unit and get the output H of the lth layer l , the calculation formula is:
[0092]
[0093] In formula (4), V l is the trainable parameter matrix of the lth layer, c represents the bias term, represents the activation function, Denotes the Hadamard product.
[0094] The prediction module is used to input the target node to be predicted into the trained graph convolutional network to obtain the power generation power of the target node.
[0095] The above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit the same. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present invention.
Claims
1. A method for predicting power generation of a new energy photovoltaic power station, characterized in that: The following steps are involved: Step 1: construct weather characteristic data of the sample set based on meteorological conditions, and preprocess the weather characteristic data to obtain sample set characteristic data H; Step 2: Consider each sample in the sample set as a node in the topological graph, calculate the attention coefficient between the node features of every two nodes based on the sample set feature data H, use the attention coefficient between the connected nodes as the edge weight, build a topological graph for each node, and obtain the adjacency matrix A; Step 3: Add self-loops to the adjacency matrix A to obtain the matrix Pair Matrix The edge weight information learned in the smoothing process is used to obtain the adjacency matrix The sample set feature data H and the adjacency matrix The input is fed into the graph convolutional network with the gated unit. After multiple iterations of training, when the loss function is minimized, the training is stopped to obtain a trained graph convolutional network. Step 4: Input the target node to be predicted into the trained graph convolutional network to obtain the power generation power of the target node.
2. The method for predicting power generation of a new energy photovoltaic power station according to claim 1, characterized in that: The meteorological conditions in step 1 include: precipitation predicted by the weather forecast and natural environment data, and the natural environment data includes surface irradiance, temperature, humidity and wind speed.
3. The method for predicting power generation of a new energy photovoltaic power station according to claim 1, characterized in that: The calculation formula of the attention coefficient between the node features of every two nodes in step 2 is: att ij =Linear([Wh i ||Wh j ]) (1) In formula (1), att ij represents the attention coefficient between the node features of the connected nodes i and j, h i represents the node feature of the i-th node, h j represents the node feature of the j-th node, Linear represents the fully connected layer, and W represents the learnable weight matrix.
4. The method for predicting power generation of a new energy photovoltaic power station according to claim 1, characterized in that: The adjacency matrix in step 3 The calculation process is: In formula (2), A represents the adjacency matrix, I represents the diagonal matrix, and Softmax represents the normalization operation.
5. The method for predicting power generation of a new energy photovoltaic power station according to claim 1, characterized in that: In step 3, the sample set feature data H and the adjacency matrix The computational process of the graph convolutional network inputted with the gating signal includes: 3.
1. Combine the sample set feature data H and the adjacency matrix Input into the multi-layer graph neural network to pass the message to the sample set feature data H, and the calculation formula is: In formula (3), M l represents the node information updated by graph convolution, l represents the lth layer network, σ is the nonlinear activation function, H l-1 represents the output of the l-1th layer, W l is the weight parameter matrix of the lth layer; 3.
2. Update the node information M obtained through graph convolution l Input the gated unit and get the output H of the lth layer l , the calculation formula is: In formula (4), V l is the trainable parameter matrix of the lth layer, c represents the bias term, represents the activation function, Denotes the Hadamard product.
6. New energy photovoltaic power station power generation prediction system, characterized by: include: A data preprocessing module is used to construct weather characteristic data of a sample set based on meteorological conditions, and preprocess the weather characteristic data to obtain sample set characteristic data H; The adjacency matrix construction module is used to regard each sample in the sample set as a node in the topological graph, calculate the attention coefficient between the node features of every two nodes based on the sample set feature data H, use the attention coefficient between the connected nodes as the edge weight, construct a topological graph for each node, and obtain the adjacency matrix A; The training module is used to add self-loops to the adjacency matrix A to obtain the matrix Pair Matrix The edge weight information learned in the smoothing process is used to obtain the adjacency matrix The sample set feature data H and the adjacency matrix The input is fed into the graph convolutional network with the gated unit. After multiple iterations of training, when the loss function is minimized, the training is stopped to obtain a trained graph convolutional network. The prediction module is used to input the target node to be predicted into the trained graph convolutional network to obtain the power generation power of the target node.
7. The new energy photovoltaic power station power generation prediction system according to claim 6 is characterized by: The meteorological conditions in the data preprocessing module include: precipitation predicted by the weather forecast and natural environment data, and the natural environment data includes surface irradiance, temperature, humidity and wind speed.
8. The new energy photovoltaic power station power generation prediction system according to claim 6 is characterized by: The calculation formula of the attention coefficient between the node features of every two nodes in the adjacency matrix building module is: att ij =Linear([Wh i ||Wh j ]) (1) In formula (1), att ij represents the attention coefficient between the node features of the connected nodes i and j, h i represents the node feature of the i-th node, h j represents the node feature of the j-th node, Linear represents the fully connected layer, and W represents the learnable weight matrix.
9. The new energy photovoltaic power station power generation prediction system according to claim 6 is characterized by: The adjacency matrix in the training module The calculation process is: In formula (2), A represents the adjacency matrix, I represents the diagonal matrix, and Softmax represents the normalization operation.
10. The new energy photovoltaic power station power generation prediction system according to claim 6, characterized in that: In the training module, the sample set feature data H and the adjacency matrix The computational process of the graph convolutional network inputted with the gating signal includes: 3.
1. Combine the sample set feature data H and the adjacency matrix Input into the multi-layer graph neural network to pass the message to the sample set feature data H, and the calculation formula is: In formula (3), M l represents the node information updated by graph convolution, l represents the lth layer network, σ is the nonlinear activation function, H l-1 represents the output of the l-1th layer, W l is the weight parameter matrix of the lth layer; 3.
2. Update the node information M obtained through graph convolution l Input the gated unit and get the output H of the lth layer l , the calculation formula is: In formula (4), V l is the trainable parameter matrix of the lth layer, c represents the bias term, represents the activation function, Denotes the Hadamard product.
Citation Information
Cited By
New energy photovoltaic power real-time monitoring and prediction system based on Internet of Things
CN120090560A
Method and system for realizing network topology state monitoring based on IP probe
CN120498965A
Photovoltaic power generation prediction method and system based on uncertainty graph convolution
CN121052461A