A Photovoltaic Output Prediction Method and System Based on an Improved MTGNN Model
By improving the MTGNN model, using timestamp features and adaptive graph learning modules, the problem of intimate timing connection in photovoltaic output prediction is solved, and the prediction accuracy and generalization ability of the model are improved, especially the tracking ability of non-stationary data.
Patent Information
- Application Number
- CN202510352138.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-25
- Publication Date
- 2025-07-04
- Estimated Expiration
- 2045-03-25
AI Technical Summary
The existing technology fails to effectively utilize the timestamp characteristics of photovoltaic data, resulting in a poorly linked timing of photovoltaic output prediction, affecting the prediction accuracy and model generalization ability.
Using the improved MTGNN model, the adaptive adjacency matrix and graph structure are established by extracting and normalizing the timestamp characteristics of photovoltaic output data, and combining the adaptive graph learning module, the time convolution module of the screening attention mechanism, and the adaptive adjacency matrix and graph structure are established to improve the data timing connection and information integration capabilities.
The accuracy of photovoltaic output prediction and the generalization ability of the model, especially the tracking ability of non-stationary data, enhance the accuracy of the prediction.
Smart Images

Figure CN119864807B_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of photovoltaic prediction, and more specifically, relates to a photovoltaic output prediction method and system based on an improved MTGNN model. Background Art
[0002] Photovoltaic power generation, as a relatively mature new energy power generation method, plays a key role in carbon emission reduction. However, the photovoltaic output is closely related to conditions such as light intensity and weather, and has strong randomness and intermittency. In order to ensure the safe operation of the power system, accurately predicting the photovoltaic output is of great significance for analyzing the new energy carrying capacity of the distribution network.
[0003] CN117081049A proposes a short-term power intelligent prediction method for photovoltaic power plants based on a multi-variable time series graph neural network (Time-Extrapolator Multivariate Time Series Forecasting With Graph Neural Networks, TXP-MTGNN) model optimized by a time extrapolation convolution module. The method includes: preprocessing missing data and abnormal data in active power data and meteorological factor data to obtain target active power data and target meteorological factor data; constructing a data set for the TXP-MTGNN photovoltaic power plant short-term power prediction model according to the target active power data and the target meteorological factor data; constructing a TXP-MTGNN photovoltaic power plant short-term power prediction model, and inputting the training data set into the TXP-MTGNN photovoltaic power plant short-term power prediction model for training; inputting the verification data set into the first prediction model to obtain a first prediction result and verifying the accuracy rate of the first prediction result; performing a complement value processing on the second prediction result according to the characteristics of the photovoltaic power plant. However, photovoltaic data usually contains year-month-day-hour-minute-second timestamps, and this patent does not consider the characteristics of timestamps, which will result in insufficient tightness of the photovoltaic data time series connection. Summary of the Invention
[0004] To solve the deficiencies existing in the prior art, the present invention provides a photovoltaic output prediction method and system for multi-data time series based on an improved and optimized multi-variable time series graph neural network.
[0005] The present invention adopts the following technical solutions.
[0006] The first aspect of the present invention proposes a photovoltaic output prediction method based on an improved MTGNN model, including:
[0007] Collect historical PV output data and corresponding PV output characteristic data, extract the timestamp features of the PV output characteristic data, normalize them, and then splice them with the corresponding PV output characteristic data to obtain a PV feature dataset with an extended time dimension and perform normalization; use these PV feature datasets to train an improved MTGNN model, which includes adding an adaptive graph learning module, a temporal convolutional module, and a graph convolutional module with a screening attention mechanism introduced; obtain the corresponding PV feature dataset by real-time acquiring PV output characteristic data, input it into the adaptive graph learning module, and establish an adaptive adjacency matrix by calculating the mutual information matrix; perform 1*1 convolution on the PV feature dataset and then input it into the temporal convolutional module to output the initial graph structure and node features transformed from the PV feature dataset as the original state information, and input the original state information and the adaptive adjacency matrix into the graph convolutional module with the screening attention mechanism introduced to output the predicted PV output data.
[0008] Preferably, the PV output characteristic data includes humidity, component temperature, global radiation, direct radiation, diffuse radiation, ambient temperature, and air pressure.
[0009] Preferably, extracting features from the timestamp of the PV output characteristic data is specifically:
[0010] Extract the timestamp of the PV output characteristic data into five features: minutes per hour, hours per day, days per week, days per month, and days per year, and normalize them all to the range of [-1, 0];
[0011] The normalization formula is:
[0012]
[0013] In the formula: represents the s-th feature extracted from the timestamp, s = {1, 2, 3, 4, 5}, , , , , respectively represent the five features of minutes per hour, hours per day, days per week, days per month, and days per year extracted; represents the data corresponding to the s-th feature extracted from the timestamp, represents the maximum value of the data corresponding to the s-th feature extracted from the timestamp, , , , , are 60, 7, 24, 30, and 365 respectively.
[0014] Preferably, the normalized photovoltaic feature dataset is input into an adaptive graph learning module, and an adaptive adjacency matrix is established by calculating the mutual information matrix, specifically as follows:
[0015] Each data in the photovoltaic feature dataset is regarded as a node, and the mutual information between every two data is regarded as an edge, thus transforming the photovoltaic feature dataset into a graph form;
[0016] The formula for mutual information is:
[0017]
[0018] In the formula: and are two data in the photovoltaic feature dataset, represents the mutual information between data and data , respectively represent the probability distributions of data and data , p ( x,y ) represents the joint probability distribution of data and data ;
[0019] Calculate the mutual information values between every two data in the photovoltaic feature dataset to obtain the mutual information matrix M Im ; The element in the p-th row and q-th column of matrix M Im is the mutual information between the p-th element and the q-th element of the photovoltaic feature dataset;
[0020] According to the mutual information, calculate the connection relationship between every two nodes of the graph transformed from the photovoltaic feature dataset, and form the connection relationship into an adaptive adjacency matrix as follows:
[0021]
[0022] In the formula: and are the initialized embedding features; and represent the weight matrices obtained from the node embedding features; and are the model parameters; α is the parameter controlling the saturation rate of the activation function tanh; relu and tanh are activation functions; represents the Hadamard product; is the mutual information matrix calculated by every two data from each other.
[0023] Preferably, the graph convolution module is divided into an information transmission part and an information selection part. In the information transmission part, the hidden information of each layer is obtained, and an attention mechanism is added to filter the hidden information. In the information selection part, the hidden information of each layer is concatenated;
[0024] The hidden information of each layer is obtained in the information transmission part, and the formula is:
[0025]
[0026]
[0027]
[0028] In the formula: represents the hidden information of the k-th layer calculated without adding the attention mechanism, represents the learnable weight matrix, β is the set hyperparameter, k represents the number of transmission layers of the graph convolution module, σ represents the sigmoid activation function, represents the original state information, represents the hidden information of the k-1 layer, represents the degree matrix, represents the adjacency matrix, represents the identity matrix, A ij represents the element in the i-th row and j-th column of represents the element in the i-th row and i-th column of
[0029] Preferably, the addition of the attention mechanism to filter the hidden information is specifically as follows:
[0030] The proportional coefficient is calculated through the softmax activation function:
[0031]
[0032] In the formula: softmax is the activation function for normalization;
[0033] The proportional coefficient is subjected to the Hadamard product operation with the hidden state information of the k-1 layer, and then through the sigmoid activation function, the output hidden state information of the k-th layer is obtained, and the formula is:
[0034]
[0035] In the formula: is the ratio coefficient, H (k)is the output hidden state of the k-th layer selected by the attention mechanism, H (k-1) represents the output hidden state of the (k - 1)-th layer.
[0036] Preferably, the information selection part splices the output state information of each layer, specifically:
[0037]
[0038] In the formula: H (k-1) represents the output hidden state of the (k - 1)-th layer, H (0) is equal to the original state information H in , H out represents the result output by the graph convolution module, represents splicing, W out is the weight matrix of the photovoltaic prediction result and the output hidden state, and this weight matrix is continuously updated during the propagation process.
[0039] Preferably, the temporal convolution module uses dilated convolution. After the photovoltaic feature dataset is processed by 1*1 convolution and then convolved through the filters of the temporal convolution module to obtain the data temporal features, the data temporal features are filtered and screened by the tanh and sigmoid activation functions respectively, and the filtered results are passed to the graph convolution module after a Hadamard product operation.
[0040] Preferably, the convolution through the filters of the temporal convolution module is specifically:
[0041] Iterative calculations are performed through filters in the temporal convolution module. Four filters are used, namely filters with convolutions of 1*2, 1*3, 1*6, and 1*7; the initial dilation factor of the iteration is set to 1 and the dilation factor of each layer increases exponentially, with the exponent being a and a > 1, the convolution kernel size is q, and the receptive field of the dilated convolution in the n-th layer iteration is:
[0042]
[0043] The formula for convolution is:
[0044]
[0045] In the formula: represents the input sequence of the l n-th layer of the temporal convolution module, represents the filter with a convolution size of 1× h n, h ={2,3,6,7}; represents the l n-th layer after convolution with a size of 1× hThe th element of the output sequence of the filter; is the dilation coefficient; represents the u-th element of the convolution kernel, represents the th element;
[0046] Truncate the outputs of all filters to the same length according to the largest filter and concatenate them in the channel dimension. The formula is expressed as:
[0047]
[0048] In the formula: represents the l input of the
[0049] -1 layer, * represents convolution, and concat represents the concatenation operation.
[0050] Collection module: used to collect historical photovoltaic output data and obtain its corresponding photovoltaic output feature data; obtain the photovoltaic output feature data and its corresponding timestamp in real time;
[0051] The timestamp feature extraction module is used to: extract features from the timestamps of the photovoltaic output feature data, normalize the extracted timestamp features and concatenate them with the corresponding photovoltaic output feature data to obtain an extended photovoltaic feature dataset in the time dimension, and normalize each photovoltaic feature dataset;
[0052] Model construction module: used to use all photovoltaic feature datasets and their corresponding historical photovoltaic output data as the training set and input them into the improved MTGNN model for training. The improved MTGNN model includes an adaptive graph learning module, a temporal convolution module, and a graph convolution module with a screening attention mechanism introduced;
[0053] Prediction module: used to obtain the corresponding normalized photovoltaic feature dataset; input it into the adaptive graph learning module, establish an adaptive adjacency matrix by calculating the mutual information matrix; after performing 1*1 convolution on the photovoltaic feature dataset, input it into the temporal convolution module to capture the temporal periodicity of the data and output the original state information, and input the original state information and the adaptive adjacency matrix into the graph convolution module with a screening attention mechanism introduced to output the predicted photovoltaic output data.
[0054] The beneficial effects of the present invention are as follows. Compared with the prior art, (1) the present invention extracts timestamps as five features and splices them with the original features, supplementing the time series features, making the time series connection of the photovoltaic feature data closer, effectively improving the prediction accuracy, and enhancing the generalization ability of the model.
[0055] (2) Based on the normalized timestamp features, the present invention constructs a graph structure and introduces a mutual information matrix in the graph learning module to establish an adaptive adjacency matrix under different influence relationships between data. The present invention uses an asymmetric form of the adaptive adjacency matrix to improve the difference in the influence degree between different data. The screening attention mechanism is used to make the model pay more attention to the output of the graph convolution hidden layer, enhancing the information integration ability and having better tracking ability for non-stationary data. Brief Description of the Drawings
[0056] Figure 1 Schematic diagram for extracting timestamp features;
[0057] Figure 2 Frame diagram of the graph convolution module;
[0058] Figure 3 Frame diagram of the multi-data time series model of the improved and optimized multi-variable time series graph neural network. Detailed Embodiment
[0059] To make the objectives, technical solutions, and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below in conjunction with the accompanying drawings in the embodiments of the present invention. The embodiments described in this application are only a part of the embodiments of the present invention, not all of them. Based on the spirit of the present invention, all other embodiments obtained by those of ordinary skill in the art without creative efforts shall fall within the protection scope of the present invention.
[0060] Embodiment 1 of the present invention proposes a photovoltaic output power prediction method based on an improved MTGNN model, including:
[0061] Collect historical photovoltaic output power data, obtain its corresponding photovoltaic output power feature data, extract features from the timestamps of the photovoltaic output power feature data, splice the extracted timestamp features with the corresponding photovoltaic output power feature data after normalization to obtain a photovoltaic feature dataset with an extended time dimension, and normalize each photovoltaic feature dataset;
[0062] Use these photovoltaic feature datasets to train an improved MTGNN model, which includes an increased adaptive graph learning module, a time convolution module, and a graph convolution module introducing a screening attention mechanism;
[0063] Obtain the photovoltaic output power feature data in real time to obtain the corresponding normalized photovoltaic feature dataset;
[0064] Input it into the adaptive graph learning module, and establish an adaptive adjacency matrix by calculating the mutual information matrix;
[0065] Perform 1*1 convolution on the photovoltaic feature dataset and input it into the temporal convolution module to output the original state information, which is the initial graph structure and node features transformed from the photovoltaic feature dataset. Input the original state information and the adaptive adjacency matrix into the graph convolution module introducing a screening attention mechanism to output the predicted photovoltaic power generation data.
[0066] Preferably, the photovoltaic power generation feature data includes humidity, component temperature, total radiation, direct radiation, diffuse radiation, ambient temperature, and air pressure.
[0067] Preferably, extracting features from the timestamps of the photovoltaic power generation feature data specifically includes:
[0068] Extract the timestamps of the photovoltaic power generation feature data into five features: minutes per hour, hours per day, days per week, days per month, and days per year, and all normalize them to the range of [-1, 0];
[0069] The normalization formula is:
[0070]
[0071] In the formula: represents the s-th feature extracted from the timestamp, s = {1, 2, 3, 4, 5}, , , , , respectively represent the five features of minutes per hour, hours per day, days per week, days per month, and days per year extracted; represents the data corresponding to the s-th feature extracted from the timestamp, represents the maximum value of the data corresponding to the s-th feature extracted from the timestamp, , , , , are 60, 7, 24, 30, and 365 respectively.
[0072] As Figure 1 shown, splice the extracted timestamp features with the original photovoltaic power generation feature data to obtain the photovoltaic feature dataset:
[0073]
[0074] In the formula: X represents the photovoltaic power generation feature data; Xnew Represents a photovoltaic feature dataset; concat is a concatenation operation.
[0075] Specifically, in this embodiment, data from a certain photovoltaic power station in the northwest of China is selected. The power station has an environmental acquisition system. The time range of the data used for training the model of the present invention is from January 1, 2019 to June 5, 2019, and the data sampling time interval is 15 minutes. 80% is selected as the training set, 10% as the validation set, and 10% as the test set.
[0076] Preferably, the normalized photovoltaic feature dataset is input into an adaptive graph learning module, and an adaptive adjacency matrix is established by calculating the mutual information matrix. Specifically:
[0077] Each data in the photovoltaic feature dataset is used as a node, and the mutual information between two data is used as an edge, converting the photovoltaic feature dataset into a graph form;
[0078] The mutual information calculation formula is:
[0079]
[0080] In the formula: and are two data in the photovoltaic feature dataset, represents data and data 's mutual information, respectively represent the probability distributions of data and data , p ( x,y ) represents the joint probability distribution of data and data ;
[0081] Calculate the mutual information values between every two data in the photovoltaic feature dataset to obtain the mutual information matrix M Im ; The element in the p-th row and q-th column of matrix M Im is the mutual information between the p-th element and the q-th element of the photovoltaic feature dataset;
[0082] According to the mutual information, calculate the connection relationship between every two nodes of the graph transformed from the photovoltaic feature dataset, and form the connection relationship into an adaptive adjacency matrix as:
[0083]
[0084] In the formula: and are initialized embedding features; and Denotes the weight matrix obtained from the node embedding features; and are model parameters; α is a parameter that controls the saturation rate of the activation function tanh; relu and tanh are activation functions; Denotes the Hadamard product; is the mutual information matrix calculated by mutual calculation of every two data.
[0085] Preferably, as Figure 2 shown, the graph convolution module is divided into an information transmission part and an information selection part. In the information transmission part, the hidden information of each layer is obtained, and an attention mechanism is added to screen the hidden information. In the information selection part, the hidden information of each layer is concatenated;
[0086] The hidden information of each layer is obtained in the information transmission part, and the formula is:
[0087]
[0088]
[0089]
[0090] In the formula: Denotes the hidden information of the k-th layer calculated without adding the attention mechanism, Denotes the learnable weight matrix, β is the set hyperparameter, k Denotes the number of transmission layers of the graph convolution module, σ denotes the sigmoid activation function, Denotes the original state information, Denotes the hidden information of the k-1 layer, Denotes the degree matrix, Denotes the adjacency matrix, Denotes the identity matrix, A ij Denotes the i-th row and j-th element of Denotes the i-th row and i-th element of
[0091] Preferably, the addition of the attention mechanism to screen the hidden information is specifically:
[0092] Calculate the proportionality coefficient through the softmax activation function:
[0093]
[0094] In the formula: softmax is the activation function for normalization;
[0095] Perform a Hadamard product operation on the proportionality coefficient and the hidden state information of the (k - 1)th layer, and then pass it through the sigmoid activation function to obtain the output hidden state information of the kth layer. The formula is:
[0096]
[0097] In the formula: is the ratio coefficient, H (k) is the output hidden state of the kth layer screened by the attention mechanism, H (k-1) represents the output hidden state of the (k - 1)th layer.
[0098] Preferably, the information selection part concatenates the output state information of each layer. Specifically:
[0099]
[0100] In the formula: H (k-1) represents the output hidden state of the (k - 1)th layer, H (0) is equal to the original state information H in , H out represents the result output by the graph convolution module, represents concatenation, W out is the weight matrix of the photovoltaic prediction result and the output hidden state, and this weight matrix is continuously updated during the propagation process.
[0101] Preferably, the temporal convolution module uses dilated convolution. After the photovoltaic feature dataset is processed by 1*1 convolution and then convolved through the filters of the temporal convolution module to obtain the data temporal features, the data temporal features are filtered and screened by the tanh and sigmoid activation functions respectively. After performing a Hadamard product operation on the screened results, they are passed to the graph convolution module.
[0102] Preferably, the convolution through the filters of the temporal convolution module is specifically:
[0103] In the temporal convolution module, iterative calculations are performed through the filters. Four types of filters are used, namely filters with convolutions of 1*2, 1*3, 1*6, and 1*7; the initial dilation factor of the iteration is set to 1 and the dilation factor of each layer increases exponentially, with the exponent being a and a > 1, and the convolution kernel size is q. The receptive field of the dilated convolution in the nth layer of iteration is:
[0104]
[0105] The formula for convolution is:
[0106]
[0107] In the formula: represents the input sequence of the l th layer of the time convolution module, represents a filter with a convolution size of 1× h ; h ={2, 3, 6, 7}; represents the l th element of the output sequence of the h th layer after passing through a filter with a convolution size of 1× ; is the dilation coefficient; represents the th element of the convolution kernel, and represents the interval of the dilated convolution, and represents the th element of
[0108] Truncate the outputs of all filters to the same length according to the largest filter and concatenate them in the channel dimension. The formula is expressed as:
[0109]
[0110] In the formula: represents the input of the l -1th layer, * represents convolution, and concat represents the concatenation operation.
[0111] Embodiment 2 of the present invention proposes a photovoltaic output prediction system based on an improved MTGNN model using the method described in Embodiment 1 of the present invention, including a collection module, a timestamp feature extraction module, a model construction module, and a prediction module, characterized in that:
[0112] Collection module: used to collect historical photovoltaic output data and obtain its corresponding photovoltaic output feature data; obtain the photovoltaic output feature data and its corresponding timestamp in real time;
[0113] The timestamp feature extraction module is used to: extract features from the timestamps of the photovoltaic output feature data, normalize the extracted timestamp features and concatenate them with the corresponding photovoltaic output feature data to obtain a photovoltaic feature dataset with an extended time dimension, and normalize each photovoltaic feature dataset;
[0114] Model construction module: used to use all photovoltaic feature datasets and the corresponding historical photovoltaic output data as a training set and input them into the improved MTGNN model for training. The improved MTGNN model includes an adaptive graph learning module, a time convolution module, and a graph convolution module introducing a screening attention mechanism;
[0115] Prediction module: used to obtain the corresponding normalized photovoltaic feature dataset; input it into the adaptive graph learning module, establish an adaptive adjacency matrix by calculating the mutual information matrix; after performing 1*1 convolution on the photovoltaic feature dataset, input it into the temporal convolution module to capture the temporal periodicity of the data and output the original state information, and input the original state information and the adaptive adjacency matrix into the graph convolution module introducing a screening attention mechanism to output the predicted photovoltaic output data.
[0116] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit them. Although the present invention has been described in detail with reference to the above embodiments, those of ordinary skill in the art should understand that: the specific implementation manners of the present invention can still be modified or equivalently replaced, and any modification or equivalent replacement without departing from the spirit and scope of the present invention shall be covered by the protection scope of the claims of the present invention.
Claims
1. A photovoltaic output prediction method based on an improved MTGNN model, characterized in that, Including: Collect historical PV output data and corresponding PV output feature data, extract the timestamp features of the PV output feature data, normalize them, and then splice them with the corresponding PV output feature data to obtain a PV feature dataset with an extended time dimension and normalize it; Use these PV feature datasets to train an improved MTGNN model, which includes adding an adaptive graph learning module, a temporal convolutional module, and a graph convolutional module with a screening attention mechanism; Obtain the corresponding PV feature dataset by real-time acquiring PV output feature data, input it into the adaptive graph learning module, and establish an adaptive adjacency matrix by calculating the mutual information matrix; Adaptive adjacency matrix is as follows: Wherein: and are initialization embedding features; and represent the weight matrix obtained from the node embedding features; and are model parameters; α is a parameter for controlling the saturation rate of the activation function tanh; relu and tanh are activation functions; represents the Hadamard product; is the mutual information matrix calculated from each pair of data; After performing 1*1 convolution on the PV feature dataset, input it into the temporal convolutional module to output the initial graph structure and node features transformed from the PV feature dataset as the original state information. Input the original state information and the adaptive adjacency matrix into the graph convolutional module with a screening attention mechanism to output the predicted PV output data.
2. The photovoltaic output prediction method based on the improved MTGNN model according to claim 1, characterized in that, Including: The PV output feature data includes humidity, component temperature, global radiation, direct radiation, diffuse radiation, ambient temperature, and air pressure.
3. A photovoltaic output power prediction method based on an improved MTGNN model according to claim 2, characterized in that, Including: Extract features from the timestamp of the PV output feature data, specifically: Extract the timestamp of the PV output feature data into five features: minutes per hour, hours per day, days per week, days per month, and days per year, and normalize them all to the range of [-1, 0]; The normalization formula is: Wherein: represents the s-th feature extracted from the timestamp, where s = {1, 2, 3, 4, 5}, , , , , respectively represent five features of the minutes per hour, hours per day, days per week, days per month, and days per year extracted; represents the data corresponding to the s-th feature extracted from the timestamp, represents the maximum value of the data corresponding to the s-th feature extracted from the timestamp, , , , , are 60, 7, 24, 30, and 365 respectively.
4. A photovoltaic output prediction method based on an improved MTGNN model according to claim 1, characterized in that, Including: Calculate the mutual information matrix, specifically: Take each data in the PV feature dataset as a node, and the mutual information between two data as an edge, transforming the PV feature dataset into a graph form; The mutual information calculation formula is: Where: and are two data in the photovoltaic feature dataset, represents the mutual information of data and data ; respectively represent the probability distributions of data and data ; p ( x, y ) represents the joint probability distribution of data and data . Calculate the mutual information values between all pairs of data in the photovoltaic feature dataset to obtain a mutual information matrix M Im ; The matrix M Im The element in the p-th row and q-th column of is the mutual information between the p-th element and the q-th element of the photovoltaic feature dataset.
5. A photovoltaic output power prediction method based on an improved MTGNN model according to claim 4, characterized in that, Including: The graph convolutional module is divided into an information propagation part and an information selection part. In the information propagation part, obtain the hidden information of each layer and add an attention mechanism to screen the hidden information. In the information selection part, splice the hidden information of each layer; The formula for obtaining the hidden information of each layer in the information propagation part is: Wherein: represents the hidden information of the k-th layer calculated without adding the attention mechanism, represents the learnable weight matrix, β is the set hyperparameter, k represents the number of transfer layers of the graph convolution module, and σ represents the sigmoid activation function, represents the original state information, represents the hidden information of the (k - 1)-th layer, represents the degree matrix, represents the adjacency matrix, represents the identity matrix, A ij represents the element in the i-th row and j-th column of represents the element in the i-th row and i-th column of 6. The photovoltaic output power prediction method based on the improved MTGNN model according to claim 5, characterized in that, Including: The specific method of adding an attention mechanism to screen the hidden information is: Calculate the proportionality coefficient through the softmax activation function: In the formula: softmax is the activation function for normalization; Perform the Hadamard product operation on the proportionality coefficient and the hidden state information of the (k - 1)th layer, and then pass it through the sigmoid activation function to obtain the output hidden state information of the kth layer. The formula is: Wherein: is the ratio coefficient, H (k) is the output hidden state of the k-th layer screened by the attention mechanism, H (k-1) represents the output hidden state of the (k - 1)-th layer.
7. A photovoltaic output power prediction method based on an improved MTGNN model according to claim 6, characterized in that, Including: The specific method of the information selection part splicing the output state information of each layer is: Where: H (k-1) represents the output hidden state of the (k - 1)-th layer, and H (0) is equal to the original state information H in , H out represents the result output by the graph convolution module, represents concatenation, and W out is the weight matrix of the photovoltaic prediction result and the output hidden state, and this weight matrix is continuously updated during the propagation process.
8. A photovoltaic output power prediction method based on an improved MTGNN model according to claim 1, characterized in that, Including: The temporal convolutional module uses dilated convolution. After the PV feature dataset is processed by 1*1 convolution and then convolved through the filter of the temporal convolutional module to obtain the data time features, the data time features are filtered and screened by the tanh and sigmoid activation functions respectively. After performing a Hadamard product operation on the screened results, it is passed to the graph convolutional module.
9. A photovoltaic output prediction method based on an improved MTGNN model according to claim 8, characterized in that, Including: The specific method of convolving through the filter of the temporal convolutional module is: In the temporal convolution module, iterative calculations are performed through filters. Four types of filters are used, namely filters with convolutions of 1*2, 1*3, 1*6, and 1*7; the initial dilation factor of the iteration is set to 1 and the dilation factor of each layer increases exponentially, with the exponent being a and a > 1, the convolution kernel size is q, and the receptive field of the dilated convolution in the nth layer iteration is: The formula for convolution is: In the formula: represents the input sequence of the l -th layer of the temporal convolution module, represents a filter with a convolution size of 1× h ; h ={2, 3, 6, 7}; represents the l -th element of the output sequence of the h -th layer after passing through a filter with a convolution size of 1× ; is the dilation coefficient; represents the u -th element of the convolution kernel, represents the spacing of the dilated convolution, represents the -th element of; All filter outputs are truncated to the same length according to the largest filter and concatenated in the channel dimension, which is expressed by the formula: Wherein: represents the input of the l -1 layer, * represents convolution, and concat represents the concatenation operation.
10. A photovoltaic output power prediction system based on an improved MTGNN model using the method according to any one of claims 1-9, comprising an acquisition module, a timestamp feature extraction module, a model construction module, and a prediction module, characterized in that: The acquisition module: is used to acquire historical photovoltaic output power data and obtain its corresponding photovoltaic output power feature data; and to acquire in real time the photovoltaic output power feature data and its corresponding timestamp; The timestamp feature extraction module is used to: extract features from the timestamps of the photovoltaic output power feature data, normalize the extracted timestamp features, and concatenate them with the corresponding photovoltaic output power feature data to obtain a photovoltaic feature data set with an extended time dimension, and normalize each photovoltaic feature data set; The model construction module: is used to use all photovoltaic feature data sets and their corresponding historical photovoltaic output power data as a training set and input them into the improved MTGNN model for training. The improved MTGNN model includes an adaptive graph learning module, a temporal convolution module, and a graph convolution module introducing a screening attention mechanism; The prediction module: is used to obtain the corresponding normalized photovoltaic feature data set; input it into the adaptive graph learning module, establish an adaptive adjacency matrix by calculating the mutual information matrix; after performing 1*1 convolution on the photovoltaic feature data set, input it into the temporal convolution module to capture the temporal periodicity of the data and output the original state information, and input the original state information and the adaptive adjacency matrix into the graph convolution module introducing a screening attention mechanism to output the predicted photovoltaic output power data.
Citation Information
Patent Citations
Photovoltaic generating capacity prediction system and method based on attention and deep learning
CN116070799A
Photovoltaic power station short-term power intelligent prediction method based on TXP-MTGNN neural network model
CN117081049A
Small-area photovoltaic power prediction method based on double-layer directed graph and terminal
CN118690162A