Low-carbon power generation scheduling method based on graph attention network and sequence model
Through the method based on the graph attention network and sequence model, a two-part diagram of power generation scheduling is constructed and features are extracted. Combined with self-supervised learning, the efficiency and accuracy of the existing low-carbon power generation scheduling method in high-dimensional constrained space is solved, and more efficient low-carbon power generation scheduling is achieved.
Patent Information
- Application Number
- CN202510009598.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-01-03
- Publication Date
- 2025-05-06
- Estimated Expiration
- 2045-01-03
AI Technical Summary
The existing low-carbon power generation scheduling methods are costly to calculate, and the convergence and efficiency under high-dimensional constraint space still need to be greatly improved, and it is impossible to ensure that the global optimal solution is found.
A low-carbon power generation scheduling method based on graph attention network and sequence model is adopted. By constructing a two-part graph of power generation scheduling, structural features and dependency characteristics are extracted, and a self-supervised method is used to alternately perform graph attention network and long-term memory network learning, and the target model is obtained to predict the power generation of the generator set.
It improves the generalization ability of the model when dealing with complex power generation scheduling constraints, can more comprehensively reflect the carbon emission characteristics of multi-energy systems, and improves scheduling efficiency and accuracy.
Smart Images

Figure CN119940812A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of power generation scheduling, and in particular to a low-carbon power generation scheduling method based on a graph attention network and a sequence model. Background Art
[0002] The goal of low-carbon power generation scheduling is to develop the optimal unit power generation strategy to achieve the goal of low-carbon power generation while meeting the power demand and minimizing the carbon emissions generated during the power generation process. The information that needs to be considered includes the carbon emission coefficient of the generator set, the actual output power in each period, the upper and lower power limits, the total power range of the power station, and the overall power demand of the system, etc. The characteristic parameters of each generator set. However, due to the uncertainty and volatility of renewable energy processing, the coupling and coordinated scheduling of multiple energy systems, and the contradiction between carbon emission constraints and economic goals, low-carbon power generation scheduling is difficult to achieve.
[0003] Common low-carbon power generation scheduling methods are mainly aimed at thermal power generation. Since its goal is to achieve system stability and economy, its objective function is centered on fuel cost, but does not take into account the carbon emissions generated by renewable energy such as wind, hydropower, and solar energy in the power grid system, and ignores the integrated control of multiple energy sources.
[0004] If the integrated dispatch of multiple energy sources is to be considered, the heuristic algorithm and reinforcement learning (Reinforcement Learning) method can be used to combine the automatic decision-making capabilities of heuristic search and reinforcement learning to solve the complex optimization problems in low-carbon power generation dispatch. For example, a comprehensive energy system model is established with system economy, environmental protection and output imbalance as the optimization objectives, and the particle concentration evaluation operator is introduced to improve the particle swarm algorithm to solve the model; or a dynamic economic dispatch model with the goal of minimizing the economic cost of distribution network operation is solved using deep reinforcement learning.
[0005] However, since heuristic algorithms mainly rely on heuristic rules or experience for search, and reinforcement learning usually requires a lot of interactive training, not only is the computational cost high, but the convergence and efficiency in high-dimensional constraint spaces still need to be greatly improved, and there is no guarantee that the global optimal solution will be found.
[0006] The above contents are only used to assist in understanding the technical solution of the present application and do not constitute an admission that the above contents are prior art. Summary of the invention
[0007] The main purpose of this application is to provide a low-carbon power generation scheduling method based on graph attention network and sequence model, aiming to solve the technical problems that the commonly used low-carbon power generation scheduling method not only has high computational cost, but also has the need to significantly improve its convergence and efficiency in high-dimensional constraint space, and cannot guarantee the finding of the global optimal solution.
[0008] To achieve the above objectives, this application proposes a low-carbon power generation scheduling method based on a graph attention network and a sequence model, the method comprising:
[0009] Obtaining the power generation of each power generation type of power generation unit in the power generation system, and obtaining the power generation limit of each power generation unit in the power generation system, the power generation limit of each power plant, and the power generation limit of the power generation end;
[0010] The power generation of each of the generator sets is used as the carbon emission decision variable of the carbon emission evaluation calculation formula, and corresponding power constraints are constructed based on the power generation limit of the generator set, the power generation limit of the power plant and the power generation limit of the power generation end, respectively, and the power generation constraints include a first power generation constraint, a second power generation constraint and a third power generation constraint;
[0011] constructing a power generation scheduling bipartite graph according to the carbon emission decision variables and the power generation constraint, and using the carbon emission evaluation calculation formula and the power generation constraint as sequence data;
[0012] Based on the graph attention network, the structural features of the power generation scheduling bipartite graph are extracted, and based on the long short-term memory network, the dependency relationship features between the sequence data are extracted;
[0013] The structural features are transferred to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and the dependency features are transferred to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning to obtain a target model;
[0014] The test set data is input into the target model to obtain the predicted data of the power generation of each of the generator sets.
[0015] In one embodiment, the steps of constructing a bipartite graph for power generation scheduling according to the carbon emission decision variables and the power generation constraint, and using the carbon emission evaluation calculation formula and the power generation constraint as sequence data include:
[0016] Combining the carbon emission evaluation calculation formula and the power generation constraint to construct a low-carbon power generation scheduling problem;
[0017] Encode the low-carbon power generation scheduling problem to obtain the power generation scheduling bipartite graph, wherein the power generation scheduling bipartite graph includes a carbon emission decision variable node, a power generation constraint node, and an edge connecting the carbon emission decision variable node and the power generation constraint node;
[0018] A target vector is formed based on the carbon emission evaluation calculation formula, and a constraint vector is formed based on the first power generation constraint, the second power generation constraint and the third power generation constraint. The sequence data includes the target vector and the constraint vector.
[0019] In one embodiment, the step of extracting the structural features of the power generation scheduling bipartite graph based on the graph attention network includes:
[0020] capturing the influence of the carbon emission decision variable on the power generation constraint according to the first level message transmission from the carbon emission decision variable node to the power generation constraint node;
[0021] Determining the reaction of the power generation constraint to the carbon emission decision variable according to the second level message transmission from the power generation constraint node to the carbon emission decision variable node;
[0022] Based on the influence of the carbon emission decision variables on the power generation constraint and the reaction of the power generation constraint on the carbon emission decision variables, the structural characteristics of the power generation scheduling bipartite graph are obtained.
[0023] In one embodiment, the step of extracting dependency features between the sequence data in the sequence data based on the long short-term memory network includes:
[0024] Passing the target vector and the constraint vector to the long short-term memory network to determine the candidate memory state and the gating value of the output gate;
[0025] Obtaining a hidden state according to the candidate memory state and the gating value of the output gate;
[0026] The dependency characteristic is determined based on the hidden state.
[0027] In one embodiment, the steps of transferring the structural features to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and transferring the dependency features to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning, further include:
[0028] Incorporating the power generation constraint into the carbon emission evaluation calculation formula in the form of a penalty term to obtain the first self-supervisory loss function; and
[0029] Determine to minimize the difference between the current dual estimate and the predicted dual variable, and construct the second self-supervised loss function based on the difference.
[0030] In one embodiment, the steps of transferring the structural features to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and transferring the dependency features to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning to obtain the target model include:
[0031] Passing the structural features to the graph attention network to obtain predicted carbon emission decision variables;
[0032] Passing the predicted carbon emission decision variable to the first self-supervised loss function, and optimizing the model parameters of the graph attention network by a gradient descent method to obtain an updated graph attention network; and,
[0033] Passing the dependency feature to the long short-term memory network to obtain the predicted dual variable;
[0034] Passing the predicted dual variable to the second self-supervised loss function, and updating the model parameters of the long short-term memory network through gradients to obtain an updated long short-term memory network;
[0035] Based on the updated graph attention network and the updated long short-term memory network, the target model is obtained.
[0036] In one embodiment, the step of inputting the test set data into the target model to obtain the prediction data of the power generation of each of the generator sets includes:
[0037] Inputting the test set data into the target model for forward propagation calculation;
[0038] The data output by the target model is subjected to inverse normalization processing to obtain predicted data of power generation of each of the generator sets.
[0039] In one embodiment, the power generation types include fossil fuel power generation, nuclear power generation and renewable energy power generation; the carbon emission evaluation calculation formula is composed of the fossil fuel power generation carbon emission calculation formula, the nuclear power generation carbon emission calculation formula and the renewable energy power generation carbon emission calculation formula; the step of using the power generation of each of the generator sets as the carbon emission decision variable of the carbon emission evaluation calculation formula includes:
[0040] The power generation of the fossil fuel power generation generator set is used as the carbon emission decision variable of the fossil fuel power generation carbon emission calculation formula;
[0041] The power generation of the nuclear power generation unit is used as the carbon emission decision variable of the nuclear power generation carbon emission calculation formula;
[0042] The power generation of the generator set generated by the renewable energy power generation is used as the carbon emission decision variable of the carbon emission calculation formula of the renewable energy power generation.
[0043] In addition, to achieve the above-mentioned objectives, the present application also proposes a low-carbon power generation scheduling device, which includes: a memory, a processor, and a computer program stored on the memory and executable on the processor, and the computer program is configured to implement the steps of a low-carbon power generation scheduling method based on a graph attention network and a sequence model as described above.
[0044] In addition, to achieve the above-mentioned purpose, the present application also proposes a storage medium, which is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by the processor, the steps of a low-carbon power generation scheduling method based on a graph attention network and a sequence model as described above are implemented.
[0045] One or more technical solutions proposed in this application have at least the following technical effects:
[0046] By incorporating multiple energy types into the carbon emission assessment formula and considering three different power generation constraints, the carbon emission characteristics of the multi-energy system can be more comprehensively reflected. Through the construction of the power generation scheduling bipartite graph, the GAT model is used to extract the structural characteristics of the power generation scheduling bipartite graph, and the LSTM model is used to extract the dependency characteristics between sequence data, effectively capturing the dependency between the carbon emission calculation formula, the power generation constraint sequence and the carbon emission decision variables. By introducing the self-supervision method into low-carbon power generation scheduling, the graph attention network learning and long short-term memory network learning are performed alternately to improve the generalization ability of the model in dealing with complex power generation scheduling constraint problems. BRIEF DESCRIPTION OF THE DRAWINGS
[0047] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present application and, together with the description, serve to explain the principles of the present application.
[0048] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.
[0049] Figure 1 A flowchart of an embodiment of a low-carbon power generation scheduling method based on a graph attention network and a sequence model of the present application;
[0050] Figure 2 This application proposes a low-carbon power generation scheduling method based on graph attention network and sequence model. Figure 1 A schematic diagram of an embodiment;
[0051] Figure 3 This is a flow chart of step S400 of an embodiment of a low-carbon power generation scheduling method based on a graph attention network and a sequence model of the present application;
[0052] Figure 4 A schematic diagram of an embodiment of a bipartite graph attention network two-level message transmission of a low-carbon power generation scheduling method based on a graph attention network and a sequence model in the present application;
[0053] Figure 5 This is a flow chart of another embodiment of step S400 of a low-carbon power generation scheduling method based on a graph attention network and a sequence model of the present application;
[0054] Figure 6 This is a framework diagram of an embodiment of an LSTM model of a low-carbon power generation scheduling method based on a graph attention network and a sequence model in this application;
[0055] Figure 7 A carbon emission coefficient table of each power generation unit in an example of a low-carbon power generation scheduling method based on a graph attention network and a sequence model in this application;
[0056] Figure 8 A feature vector table of message transmission from the carbon emission decision variable side to the power generation constraint side in an example of a low-carbon power generation scheduling method based on a graph attention network and a sequence model in this application;
[0057] Fig. 9 A feature vector table of message transmission from the power generation constraint side to the carbon emission decision variable side for an example of a low-carbon power generation scheduling method based on a graph attention network and a sequence model in this application;
[0058] Fig.10 This is a schematic diagram of the device structure of the hardware operating environment involved in a low-carbon power generation scheduling method based on a graph attention network and a sequence model in an embodiment of the present application.
[0059] The purpose, features and advantages of this application will be further described in conjunction with the embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION
[0060] It should be understood that the specific embodiments described herein are only used to explain the technical solutions of the present application and are not used to limit the present application.
[0061] In order to better understand the technical solution of the present application, a detailed description will be given below in conjunction with the accompanying drawings and specific implementation methods.
[0062] Based on this, the embodiment of the present application provides a low-carbon power generation scheduling method based on a graph attention network and a sequence model, referring to Figure 1 , Figure 1 This is a flow chart of an embodiment of a low-carbon power generation scheduling method based on a graph attention network and a sequence model of the present application.
[0063] In this embodiment, the low-carbon power generation scheduling method based on graph attention network and sequence model includes steps S100 to S600:
[0064] Step S100: obtaining the power generation of each type of power generation unit in the power generation system, and obtaining the power generation limit of each power generation unit in the power generation system, the power generation limit of each power plant, and the power generation limit of the power generation end.
[0065] In this embodiment, the types of power generation include, but are not limited to, fossil fuel power generation, nuclear power generation, and renewable energy power generation, depending on the energy source. Fossil fuel power generation mainly refers to thermal power generation, while renewable energy power generation includes solar energy, wind energy, hydropower, geothermal energy, biomass energy, and ocean energy including tidal energy, wave energy, and ocean current energy.
[0066] Step S200: Use the power generation of each of the generator sets as the carbon emission decision variable in the carbon emission assessment calculation formula, and construct corresponding power generation constraints based on the power generation limit of the generator set, the power generation limit of the power plant and the power generation limit of the power generation end, respectively. The power generation constraints include a first power generation constraint, a second power generation constraint and a third power generation constraint.
[0067] In this embodiment, since the carbon emission characteristics of different power generation modes are different, and the power generation of the generator set directly affects the carbon emission, the present invention uses the power generation of each type of generator set as the carbon emission decision variable.
[0068] For example, using P A,a,t P represents the actual power generation of the ath thermal power generating unit in a certain period of time t; B,b,t P represents the actual power generation of the bth nuclear power generating unit in a certain period of time t; C,c,t P represents the actual power generation of the cth solar power generator in a certain period of time t; D,d,t P represents the actual power generation of the dth wind turbine generator set in a certain period of time t; M,e,t P represents the actual power generation of the e-th hydropower generator unit in a certain period of time t; N,f,t P represents the actual power generation of the fth geothermal generator unit in a certain period of time t;Q,g,t P represents the actual power generation of the g-th ocean energy generator set in a certain period of time t; R,h,t It represents the actual power generation of the hth biomass generator set in a certain period of time t.
[0069] Understandably, the above P A,a,t , P B,b,t , P C,c,t , P D,d,t , P M,e,t , P N,f,t , P Q,g,t and P R,h,t The unit is kWh.
[0070] It should be noted that the above-mentioned carbon emissions assessment calculation formula includes but is not limited to the accumulation of the carbon emissions calculation formula for thermal power generation, the carbon emissions calculation formula for renewable energy power generation and the carbon emissions calculation formula for nuclear power generation.
[0071] Optionally, the power generation of the thermal power generation unit is used as the carbon emission decision variable of the thermal power generation carbon emission calculation formula; the power generation of the nuclear power generation unit is used as the carbon emission decision variable of the nuclear power generation carbon emission calculation formula; the power generation of the renewable energy power generation unit is used as the carbon emission decision variable of the renewable energy power generation carbon emission calculation formula.
[0072] As an optional implementation method, the calculation formula for carbon emissions from thermal power generation is defined as:
[0073] in, is the carbon emission of the ath thermal power generating unit, in grams (g); α a , β a , γ a ,δ a and ε a They are the carbon emission coefficients specific to the ath thermal power generating unit, in grams per kilowatt-hour (g / kWh).
[0074] Understandably, when thermal power generating units are under low load conditions, the carbon emission intensity per unit of power generation is relatively high due to the reduction in combustion efficiency; on the contrary, under high load conditions, due to the positive effect of scale effect, the carbon emission intensity per unit of power generation will be reduced. In other words, during the operation of thermal power generating units, as the load increases, the carbon emissions per unit of power generation do not show a linear growth. Therefore, this nonlinear relationship can be described by a quadratic function. At the same time, under unconventional operating conditions such as deep peak regulation, the carbon emissions of thermal power generating units may change significantly. For example, in old thermal power units, when the power approaches the upper limit of the unit, the carbon emissions are no longer linear or increase gently.
[0075] Therefore, by introducing an index to better capture the nonlinear characteristics of thermal power generating units under unconventional operating conditions, and by superimposing two different forms of functions to better match the actual operating data of thermal power generating units, the accuracy of carbon emissions estimation is improved.
[0076] As another optional implementation, the solar power generation carbon emission calculation formula is defined as:
[0077] in, is the carbon emission of the cth solar power generator set, in grams (g), θ c is the carbon emission coefficient specific to the cth solar power generator set, expressed in grams per kilowatt-hour (g / kWh).
[0078] Understandably, renewable energy and nuclear power generation do not directly rely on the combustion of fuel to generate energy, but their manufacturing, transportation and maintenance during their life cycle still produce certain carbon emissions. Taking solar power generation as an example, the process of manufacturing solar panels and other equipment, the use of heavy machinery and transportation vehicles involved in the construction of power generation facilities, and the transportation and maintenance of equipment during the maintenance phase may all generate carbon emissions. Therefore, the carbon emissions of renewable energy and nuclear power generation are directly proportional to the actual power generation, that is, the higher the power generation, the corresponding increase in overall carbon emissions.
[0079] Therefore, the carbon emission calculation formula for renewable energy power generation and nuclear power generation is similar to the carbon emission calculation formula for solar power generation, and can be adjusted through the corresponding carbon emission coefficients.
[0080] For example, it is assumed that the carbon emission assessment calculation formula is:
[0081]
[0082] Among them, a v , b v 、c v d v 、e v 、f v , g v and h v are the number of thermal, nuclear, solar, wind, hydro, geothermal, ocean and biomass generating units, ∈ b , μ d , τ e , ω g and hThese are the carbon emission coefficients specific to each nuclear, wind, hydro, geothermal, ocean and biomass power generating unit, expressed in grams per kilowatt-hour (g / kWh).
[0083] In this embodiment, the power generation of the generator set i in time period t is expressed as P U,i,t (1≤i≤n). Among them, U∈{A,B,C,D,M,N,Q,R} represents the energy type; n=a v +b v +c v +d v +e v +f v +g v +h v , represents the total number of all generator sets in the above power generation system.
[0084] The total power generation of power plant k in time period t is P U,k,t It is composed of the sum of the outputs of all its generator sets, namely:
[0085]
[0086] Where r represents the number of power plants, k (1≤k≤r) represents the specific power plant number, and J k ={1,2,…,s} represents the set of generator sets in power plant k, and s represents the number of generator sets in power plant k.
[0087] Optionally, the first power generation constraint constructed based on the power generation limit of the power generation unit, that is, the power generation output constraint of the power generation unit It can be expressed as, in, and are the minimum and maximum power generation corresponding to the i-th generator set in time period t. The purpose of this is to ensure that the power generation P corresponding to the generator set i U,i,t , within the maximum and minimum power generation capacity of generator set i.
[0088] The second power generation constraint constructed based on the power generation limit of the power plant, that is, the total power generation output constraint of the power plant It can be expressed as, in, and are the minimum and maximum total power generation of the kth power plant in time period t. The purpose of this is to ensure that the total power generation of power plant k, P U,k,t , within the maximum and minimum power generation capacity of power plant k.
[0089] The third generation constraint based on the generation capacity limit at the generation end is the power balance constraint. It can be expressed as, in, It is the minimum total power generation that all generators must achieve in a certain period of time t. The purpose of this is to ensure that in any given period of time, the total power generation of all generators at least meets the power demand.
[0090] Step S300: constructing a power generation scheduling bipartite graph according to the carbon emission decision variables and the power generation constraint, and using the carbon emission evaluation calculation formula and the power generation constraint as sequence data.
[0091] Optionally, step S300 includes constructing a low-carbon power generation scheduling problem in combination with the carbon emission decision variables and the power generation constraint; then, encoding the low-carbon power generation scheduling problem to obtain a power generation scheduling bipartite graph with nodes and edges. It should be noted that the nodes of the above-mentioned power generation scheduling bipartite graph include carbon emission decision variable nodes and power generation constraint nodes; the edges of the power generation scheduling bipartite graph refer to the edges formed by connecting the carbon emission decision variable nodes and the power generation constraint nodes. And, based on the carbon emission evaluation calculation formula, a target vector is formed, and based on the first power generation constraint, the second power generation constraint and the third power generation constraint, a constraint vector is formed. It can be understood that the above-mentioned sequence data includes the target vector and the constraint vector.
[0092] In this embodiment, the carbon emission evaluation formula F(P U,i,t ), Generator output constraints Total power output constraints of power plants and power balance constraints Constructing the Low-Carbon Generation Dispatch Problem Among them, p * =(P U,1,t ,P U,2,t ,……,P U,i,t ). It can be understood that the goal of solving this optimization problem is to reduce the total carbon emissions as much as possible while satisfying the constraints. Under the premise of minimizing F X (p * ).in, represents the matrix that determines the parameters of the low-carbon generation scheduling problem instance, represents the low-carbon generation dispatch constraint, |·| represents the number of elements in the collection, and the instance parameter determines the function F X and specific form.
[0093] Specifically, firstly, the power generation output constraint of the generator set is and the total power output constraint of the power plant Each interval constraint in is decomposed into two independent one-sided inequalities, and then the decomposed one-sided inequalities and power balance constraints are combined. It is uniformly expressed as less than or equal to 0. The carbon emission evaluation calculation formula F(P U,i,t ) is constructed into the target vector x 0 , construct all the above one-sided inequalities into constraint vectors x 1 ,x 2 ,……,x m-1 ,x m , each vector has a dimension of n+1, where n is the number of carbon emission decision variables and the additional 1 is a constant term. U,i,t ) and each one-sided inequality, if the weight of a carbon emission decision variable is not 0, the corresponding vector is matched to the weight. In particular, when the power generation of a thermal power generation unit is used as a carbon emission decision variable, the corresponding vector position is filled with the sum of the carbon emission weights unique to the thermal power generation unit.
[0094] The target vector x 0 and the constraint vector x 1 ,x 2 ,……,x m-1 ,x m The matrix X contains the instantiation parameters of the low-carbon power generation scheduling problem in a certain time period t. By collecting the instantiation parameter matrix of a certain area in T' time periods, a complete electric carbon data set is formed. Divide Z into training set and test set in the ratio of 8:2.
[0095] Optionally, Z is normalized and the original carbon data in the carbon data set Z is converted to values between 0 and 1 using Min-Max Scaling to ensure that the carbon data are processed on the same scale and improve the stability and generalization ability of the model. Based on the maximum value in each instantiation parameter matrix and minimum value Each value s in the instantiation parameter matrix is normalized to obtain s', that is,
[0096] For further information, see Figure 2 In constructing the above low-carbon power generation scheduling problem Afterwards, the low-carbon power generation scheduling problem Encoded as a bipartite graph of generation scheduling with nodes and edges in, and are two non-intersecting sets of nodes. Represents the entire node set.
[0097] Optionally, first divide the nodes of the bipartite graph into two non - overlapping sets: carbon emission decision variables and power generation constraints. That is, the power generation scheduling bipartite graph The node set V of includes the set of carbon emission decision variables and and
[0098] Among them, the power generation scheduling bipartite graph On one side, it contains n carbon emission decision variable nodes. Among them, for the j - th (0 ≤ j < n) carbon emission decision variable node, the feature vector In the j - th (0 ≤ j < n + 1) position, the value is represented as x 0 [j], and all other positions are 0. Use to represent the carbon emission decision variable node feature matrix. On the other side of the power generation scheduling bipartite graph it contains m power generation constraint nodes. Among them, for the i - th (0 < i ≤ m) power generation constraint node, the feature vector is Use to represent the power generation constraint feature matrix.
[0099] Then, create an edge between the j - th carbon emission decision variable node and the i - th power generation constraint node. If the j - th carbon emission decision variable has a non - zero weight in the i - th power generation constraint, then create an edge between the nodes and
[0100] The purpose of this is to highlight the interaction between power generation constraints and carbon emission decision variables in the low - carbon power generation scheduling problem, and facilitate the extraction of key features through the message - passing mechanism of the graph structure.
[0101] Step S400: Based on the graph attention network, extract the structural features of the power generation scheduling bipartite graph, and based on the long short - term memory network, extract the dependency relationship features between the sequence data.
[0102] In this embodiment, a bipartite graph attention network (Graph Attention Network, GAT) is used for two - level message passing to extract the structural features of power generation scheduling. On the one hand, it improves the effectiveness of capturing the complex relationship between carbon emission decision variables and power generation constraints. On the other hand, it improves the prediction ability and optimization effect of the model.
[0103] Optionally, please refer to Figure 3 to Figure 4 The step of extracting the structural features of the power generation scheduling bipartite graph based on the graph attention network includes steps S411 to S413:
[0104] Step S411: capturing the influence of the carbon emission decision variable on the power generation constraint according to the first-level message transmission from the carbon emission decision variable node to the power generation constraint node;
[0105] Step S412: determining the reaction of the power generation constraint to the carbon emission decision variable according to the second level message transmission from the power generation constraint node to the carbon emission decision variable node;
[0106] Step S413: Based on the influence of the carbon emission decision variable on the power generation constraint and the reaction of the power generation constraint on the carbon emission decision variable, the structural characteristics of the power generation scheduling bipartite graph are obtained.
[0107] Specifically, each power generation constraint node is updated according to the information of the carbon emission decision variable node directly connected to it, according to the formula The first level of message passing is performed from the carbon emission decision variable node to the power generation constraint node to capture the impact of the carbon emission decision variable on the power generation constraint. is the neighbor of the ith node, is the weight matrix of the carbon emission decision variable node, is the attention coefficient between power generation constraint node i and carbon emission decision variable node j, and σ is the activation function. According to the formula Execute the second level message passing from the power generation constraint node to the carbon emission decision variable node to determine the reaction of the power generation constraint to the carbon emission decision variable. Represents the weight matrix of the power generation constraint node.
[0108] It should be noted that the graph attention network can comprehensively consider the impact of carbon emission decision variables on power generation constraints and the reaction of power generation constraints on carbon emission decision variables, and learn how to adjust and optimize each carbon emission decision variable while satisfying the power generation constraints to obtain updated carbon emission decision variables.
[0109] In this embodiment, the above attention coefficient It can capture which carbon emission decision variables have a greater impact on a certain power generation constraint or which power generation constraint has a stronger constraint on a certain carbon emission decision variable, which is obtained through learning by the graph attention network. Among them, the training process aims to minimize the loss function of the network, including multiple iterative calculations of input features and parameter optimization, so that the attention coefficient accurately reflects the relationship between nodes. The calculation formula of the attention coefficient is:
[0110]
[0111] in, is a learnable parameter vector, defined as a set of weights of the graph attention network, which is usually initialized to a random value; ∥ represents the concatenation operation, and ψ represents the activation function. Definition and Similarly, only the carbon emission decision variable set is exchanged and the power generation constraint set And swap the positions of the i-th and j-th nodes.
[0112] Furthermore, after obtaining the updated carbon emission decision variable, the node features of the updated carbon emission decision variable are concatenated into a matrix H, and then the matrix H is passed to a multi-layer perceptron (Multi-Layer Perceptron) with only one hidden layer to obtain the predicted carbon emission decision variable value The formula is: in, is the activation function, W (1) is the weight matrix from the input layer to the hidden layer, b (1) is the bias vector of the hidden layer, W (2) is the weight matrix from the hidden layer to the output layer, b (2) is the bias vector of the output layer.
[0113] In this embodiment, a long short-term memory network (LSTM) is used. To extract the dependency features between the sequence data in the above sequence data, it should be noted that the dependency features here refer to the dependency between the carbon emission assessment calculation formula and the power generation constraint. The purpose of this is to solve the low-carbon power generation scheduling problem. In this paper, the complex relationship between carbon emission assessment formula and power generation constraints that may exist across multiple power generation constraints is effectively captured.
[0114] Optionally, see Figures 5 and 6 The step of extracting dependency features between the sequence data based on the long short-term memory network includes steps S421 to S423:
[0115] Step S421: passing the target vector and the constraint vector to the long short-term memory network to determine the candidate memory state and the gating value of the output gate;
[0116] Step S422: Obtaining a hidden state according to the candidate memory state and the gating value of the output gate;
[0117] Step S423: Determine the dependency feature based on the hidden state.
[0118] Specifically, the target vector x 0 and the constraint vectors x 1 , x 2 , ……, x m-1 , x m are used as the input of the LSTM. Understandably, the sequence length is m + 1, and the dimension of each sequence vector is n + 1. The formula for the LSTM to extract features from each sequence vector includes:
[0119] p t = Θ(W p · [h t-1 , x t + b p )
[0120] q t = Θ(W q · [h t-1 , x t + b q )
[0121]
[0122] where x t (0 ≤ t < m + 1) represents the t-th sequence; p t is the output of the forget gate; W p is the weight matrix of the forget gate; Θ is the Sigmoid activation function, representing the proportion of discarding or retaining; tanh(·) is the activation function; q t is the gate control value of the input gate, used to determine which information will be written into the cell state; is the candidate memory state, used to generate new information that may be updated to the cell state; is the current cell state updated by combining the output of the forget gate and the output of the input gate; is the gate control value of the output gate; h t is the hidden state.
[0123] By updating the hidden state h t of the LSTM, the hidden state of each sequence step will contain the corresponding output information, and finally the vector h m obtained at the last sequence step converges all the long-term and short-term dependency relationship features. Therefore, the dual variable predicted by the LSTM is λ = h m .
[0124] Step S500: Transmit the structural features to the first self-supervised loss function for training the graph attention network to perform graph attention network learning, and transmit the dependency relationship features to the second self-supervised loss function for training the long short-term memory network to perform long short-term memory network learning to obtain the target model.
[0125] In this embodiment, before performing step S500, it is necessary to construct a first self-supervised loss function and a second self-supervised loss function. The first self-supervised loss function can be obtained by incorporating the above power generation constraint into the carbon emission evaluation calculation formula in the form of a penalty term; the second self-supervised loss function can be constructed by determining the difference between the current dual estimate and the predicted dual variable and minimizing the difference based on the difference.
[0126] Optionally, by introducing Lagrangian multipliers to construct Lagrangian functions, the power generation constraint can be incorporated into the carbon emission evaluation formula in the form of a penalty term to solve the above low-carbon power generation scheduling problem. The power generation constraint in is relaxed. It should be noted that the Lagrange multiplier is the dual variable λ mentioned above. It can be understood that the relaxation process introduces the cost of violating the power generation constraint into the carbon emission evaluation formula, thereby converting the low-carbon power generation scheduling problem into It is transformed into a low-carbon power generation scheduling problem with penalty terms and no constraints.
[0127] Therefore, the first self-supervisory function for learning GAT can be defined as:
[0128]
[0129] Among them, ρ(0<ρ<1000) is the penalty factor.
[0130] The purpose of this is to expand the loss function of the GAT model through the augmented Lagrangian method, transforming the constrained problem into an unconstrained problem, so that in the low-carbon power generation scheduling problem, the carbon emission decision variables approximated by the GAT model meet the power generation constraints, thereby improving the flexibility and efficiency of the GAT model in the optimization process.
[0131] Optionally, by minimizing the current dual estimate The difference between the predicted dual variable λ and the loss function is used to train the LSTM model. The second loss function can be expressed as: Among them, ||·|| represents L p Norm.
[0132] Furthermore, in one embodiment, when the violation of the power generation constraint is serious, the penalty factor ρ is introduced to implement a penalty for the violation when updating the dual variable λ, and to adjust the step size to a certain extent. The violation of the power generation constraint is represented by the violation value It is indicated by the formula Calculate violation value Then the solution of the current iteration is monitored to determine whether the solution of the current iteration satisfies all constraints. Among them, ||·|| ∞ Represents the infinity norm, which is defined as the element with the largest absolute value in the vector.
[0133] Specifically, when the violation value is detected to be too large, the penalty factor ρ is increased so that the solution violating the power generation constraint is punished more in subsequent iterations, thereby adjusting the optimization process. And the solution that violates the power generation constraint, if the violation value Greater than tolerance value Right now Then increase the penalty factor ρ, that is Among them, Γ∈(0,1) is used to determine whether to update the tolerance of the penalty factor ρ, is the update multiplier coefficient, ρ max is the upper protection value of ρ.
[0134] In this embodiment, the above structural features are passed to the graph attention network to obtain the predicted carbon emission decision variables; then the predicted carbon emission decision variables are passed to the above first self-supervised loss function, and the model parameters of the graph attention network are optimized by the gradient descent method to obtain an updated graph attention network, thereby realizing graph attention network learning. Also, the predicted dual variable λ is obtained by passing the above dependency features to the long short-term memory network; then the predicted dual variable is passed to the above second self-supervised loss function, and the model parameters of the long short-term memory network are updated by gradient to obtain an updated long short-term memory network, thereby realizing long short-term memory network learning. Also, based on the updated graph attention network and the updated long short-term memory network, the target model is obtained.
[0135] In this embodiment, an end-to-end self-supervision method is used to solve the low-carbon power generation scheduling problem. It should be noted that before learning the graph attention network and the long short-term memory network, it is necessary to first Γ、ρ max Initialization is performed for constraint relaxation, penalty adjustment, and initial setting of model weights. During the entire training process, the global training counter is first set Used to alternately perform graph attention network learning, long short-term memory network learning, and penalty coefficient update until the set maximum number of global training times is met
[0136] Optionally, in each round of global training, during the graph attention network learning phase, set the initial value of the graph attention network learning counter The instance parameter matrix X of the low-carbon power generation scheduling problem is input into the GAT model, and the construction of the power generation scheduling bipartite graph and the extraction of the structural features of the power generation scheduling bipartite graph are performed in sequence to obtain the predicted carbon emission decision variable p * Next, we use the first loss function Calculate the loss value and optimize the GAT model parameters by gradient descent. The learning counter value increases by 1 after each optimization until the predetermined counter number is reached. Finally, the graph attention network learning phase is completed.
[0137] In the long short-term memory network learning phase, first copy the current LSTM model to the static LSTM model middle, Used to provide the current dual estimate Set sequence learning counter Input the parameter matrix X into the LSTM model, extract the dependency features between the sequence data, and obtain the predicted dual variable λ. Then, use the second loss function Calculate the loss value and update the parameters of the LSTM model through the gradient. Similarly, after each optimization, the learning counter value increases by 1 until the predetermined counter number is reached. Then the sequence learning phase is completed.
[0138] After each round of global training completes the graph attention network learning and the long short-term memory network learning, the penalty factor ρ is updated. That is, according to the formula Calculate violation value According to the formula Update the penalty factor ρ. At this time, the global training counter Increase by 1, repeat the above process of graph attention network learning, long short-term memory network learning and penalty factor update until the maximum number of global training times is reached After that, the whole training process ends and the target model is obtained, that is, the trained Model.
[0139] Step S600: input the test set data into the target model to obtain the predicted data of the power generation of each of the generator sets.
[0140] In this embodiment, the test set data is input into the target model for forward propagation calculation; then, the data output by the target model is inversely normalized to obtain predicted data on the power generation of each of the generator sets.
[0141] In the technical solution provided in this embodiment, by incorporating multiple energy types into the carbon emission assessment calculation formula and considering three different power generation constraints, the carbon emission characteristics of the multi-energy system can be more comprehensively reflected. By constructing a bipartite graph for power generation scheduling, the GAT model is used to extract the structural features of the bipartite graph for power generation scheduling, and the LSTM model is used to extract the dependency features between sequence data, effectively capturing the dependency between the carbon emission calculation formula, the power generation constraint sequence, and the carbon emission decision variables. By introducing self-supervision methods into low-carbon power generation scheduling, graph attention network learning and long short-term memory network learning are performed alternately to improve the generalization ability of the model in dealing with complex power generation scheduling constraint problems.
[0142] For example, the carbon emission data of 100 power generation units in a certain area within 50 time periods are collected. Then, the carbon emission coefficients of the 100 power generation units are used according to the formula:
[0143]
[0144] To establish the carbon emission assessment calculation formula. Among them, the 100 power generation units include thermal power, renewable energy and nuclear power generation units. The carbon emission coefficients of some power generation units in the first time period are as follows: Figure 7 As shown, where z i is the label of the i-th unit.
[0145] Then, the low-carbon power generation scheduling constraint set is constructed by the power output constraints of each generator unit in 50 time periods, the total power output constraints of each power plant, and the power balance constraints. i represents different time periods (1≤i≤50).
[0146] Then, all low-carbon generation dispatch constraints are transformed into the formula The form of inequality constraints requires that all right sides of inequalities are less than or equal to zero, that is, the bilateral inequality is decomposed into two unilateral inequalities. Taking the first time period as an example, 10≤P U,1,1 ≤20,5≤P U,2,1 ≤30,1000≤P U,1,1 +P U,2,1 +……+P U,7,1 ≤2000,1000≤P U,8,1 +P U,9,1 +……+P U,13,1 ≤2000 (in kWh), converted into the form of inequality constraint: 10-P U,1,1 ≤0,P U,1,1 -20≤0,5-P U,2,1 ≤0,P U,2,1 -30≤0,1000-PU,1,1 +P U,2,1 +……+P U,7,1 ≤0,P U,1,1 +P U,2,1 +……+P U,7,1 -2000≤0,1000 - P U,8,1 +P U,9,1 +……+P U,13,1 ≤0,P U,8,1 +P U,9,1 +……+P U,13,1 -2000≤0。
[0147] Combined with the unilateral inequalities of low - carbon power generation scheduling constraints and the carbon emission evaluation calculation formula obtained after decomposition, a low - carbon power generation scheduling problem is constructed. The carbon emission evaluation calculation formula is constructed into a target vector Each of the unilateral inequalities of all power generation constraints is respectively constructed into a constraint vector The target vector is concatenated and the constraint vector to form an instantiated parameter matrix X (i) 。Similar processing is performed on the electricity - carbon data for 50 time periods to form a complete electricity - carbon data set The electricity data set is divided into a training set and a test set Next, using the formula the electricity - carbon data set is normalized to convert the electricity data into values between 0 and 1.
[0148] Then, a bipartite graph of power generation scheduling is constructed, taking the low - carbon power generation scheduling in the first time period as an example. It is constructed into a trainable constrained power generation scheduling bipartite graph The node set of where represents the set of carbon emission decision variables, represents the set of power generation constraint nodes. One side of the power generation scheduling bipartite graph contains 100 variable nodes. The feature vector of the j - th (0 ≤ j < 100) carbon emission decision variable node the value at the j - th (0 ≤ j < 101) position in is x 0 [j], and all other positions are 0, thus representing the feature of each carbon emission decision variable node to obtain the carbon emission decision variable node feature matrix The other side contains 218 constraint nodes. The feature vector of the i - th (0 < i ≤ 218) power generation constraint node is Using Represents the power generation constraint feature matrix. Next, the bipartite graph attention network is used for two-level message passing. First, the formula is:
[0149]
[0150] To calculate the attention coefficient when transmitting messages from the carbon emission decision variable side to the power generation constraint side Then use the calculated attention coefficient According to the formula Calculate the message transmission from the carbon emission decision variable side to the power generation constraint side to obtain the new feature representation of each power generation constraint node right After 1 update, the matrix is obtained After the message is delivered, some results are as follows Figure 8 shown.
[0151] By formula:
[0152]
[0153] Calculate the attention coefficient when passing messages from the power generation constraint side to the carbon emission decision variable side Using the calculated attention coefficient, according to the formula Calculate the message transmission from the power generation constraint side to the carbon emission decision variable side to obtain the new feature representation of each carbon emission decision variable right After 1 update, the matrix is obtained The message passing results are as follows Fig. 9 shown.
[0154] According to the formula The updated carbon emission decision variable node feature matrix Input into the multi-layer perceptron to predict the value of the carbon emission decision variable
[0155] Then, the dependency features between the sequence data are extracted to determine the low-carbon power generation dispatch in the first time period. Take 2 as an example. To extract the dependency between the carbon emission evaluation formula and the power generation constraint, the total sequence length is 219, and the dimension of each sequence vector is 101. According to the formula:
[0156] p t =θ(W p ·[h t-1 ,x t ]+b p )
[0157] q t =θ(W q ·[ht-1 ,x t ]+b q )
[0158]
[0159] The target vector and constraint vector Input LSTM step by step. At each sequence step, LSTM updates the current hidden state according to the current input vector and the hidden state of the previous step, and calculates the hidden state of all sequence steps. Select the hidden state As dual variable representation for LSTM prediction.
[0160] Then, after defining the first loss function, the second loss function, and the update rule of the penalty factor when the power generation constraint is violated, the power generation data of each generator set is predicted. First, initialize λ = 0 to ensure unbiased estimation; set ρ = 0.5 to balance the constraint relaxation in the early stage, and set the empirical value Control the growth rate of the penalty factor, Γ=0.5 to limit over-adjustment, ρ max = 1000 To avoid numerical instability caused by excessive penalty factors, set the maximum number of global training times Maximum number of counters when learning graph attention network Maximum counter times when learning long short-term memory networks The training set Z 1 As input, the complete training process is performed. The global training alternately performs graph attention network learning, long short-term memory network learning and penalty factor update, and updates the parameters of the GAT model and LSTM model. After the update is completed, the test set Z 2 The low-carbon power generation scheduling problem in 10 time periods is predicted using the trained model, and the predicted actual power generation of each generator set is obtained after inverse normalization.
[0161] It should be noted that the above examples are only used to understand the present application and do not constitute a limitation on the present application's low-carbon power generation scheduling method based on graph attention network and sequence model. More simple transformations based on this technical concept are all within the scope of protection of the present application.
[0162] The present application provides a low-carbon power generation scheduling device, which includes: at least one processor; and a memory communicatively connected to the at least one processor; wherein the memory stores instructions executable by the at least one processor, and the instructions are executed by the at least one processor so that the at least one processor can execute a low-carbon power generation scheduling method based on a graph attention network and a sequence model in the above-mentioned embodiment one.
[0163] Reference below Fig.10 , which shows a schematic diagram of the structure of a low-carbon power generation dispatching device suitable for implementing the embodiment of the present application. The low-carbon power generation dispatching device in the embodiment of the present application may include but is not limited to mobile terminals such as mobile phones, laptop computers, digital broadcast receivers, PDAs (Personal Digital Assistants), PADs (Portable Application Descriptions), PMPs (Portable Media Players), vehicle-mounted terminals (such as vehicle-mounted navigation terminals), etc., and fixed terminals such as digital TVs, desktop computers, etc. Fig.10 The low-carbon power generation scheduling device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present application.
[0164] like Fig.10 As shown, the low-carbon power generation dispatching device may include a processing device 1001 (such as a central processing unit, a graphics processor, etc.), which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM: Read Only Memory) 1002 or a program loaded from a storage device 1003 to a random access memory (RAM: Random Access Memory) 1004. In RAM1004, various programs and data required for the operation of the xxx device are also stored. The processing device 1001, ROM1002 and RAM1004 are connected to each other through a bus 1005. An input / output (I / O) interface 1006 is also connected to the bus. Generally, the following systems can be connected to the I / O interface 1006: an input device 1007 including, for example, a touch screen, a touchpad, a keyboard, a mouse, an image sensor, a microphone, an accelerometer, a gyroscope, etc.; an output device 1008 including, for example, a liquid crystal display (LCD: Liquid Crystal Display), a speaker, a vibrator, etc.; a storage device 1003 including, for example, a magnetic tape, a hard disk, etc.; and a communication device 1009. The communication device 1009 can allow the low-carbon power generation dispatching device to communicate with other devices wirelessly or by wire to exchange data. Although the figure shows a low-carbon power generation dispatching device with various systems, it should be understood that it is not required to implement or have all the systems shown. More or fewer systems can be implemented or provided instead.
[0165] In particular, according to the embodiments disclosed in the present application, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present application include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from a network through a communication device, or installed from a storage device 1003, or installed from a ROM 1002. When the computer program is executed by the processing device 1001, the above-mentioned functions defined in the method of the embodiment disclosed in the present application are executed.
[0166] The low-carbon power generation scheduling device provided by the present application adopts a low-carbon power generation scheduling method based on a graph attention network and a sequence model in the above-mentioned embodiment, which can solve the technical problem that the commonly used low-carbon power generation scheduling method not only has high computational cost, but also has to significantly improve its convergence and efficiency in high-dimensional constraint space, and cannot guarantee the finding of the global optimal solution. Compared with the prior art, the beneficial effects of the low-carbon power generation scheduling device provided by the present application are the same as the beneficial effects of a low-carbon power generation scheduling method based on a graph attention network and a sequence model provided by the above-mentioned embodiment, and the other technical features in the low-carbon power generation scheduling device are the same as the features disclosed in the method of the previous embodiment, which will not be repeated here.
[0167] It should be understood that the various parts disclosed in this application can be implemented by hardware, software, firmware or a combination thereof. In the description of the above embodiments, specific features, structures, materials or characteristics can be combined in any one or more embodiments or examples in a suitable manner.
[0168] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
[0169] The present application provides a computer-readable storage medium having computer-readable program instructions (i.e., computer programs) stored thereon, and the computer-readable program instructions are used to execute a low-carbon power generation scheduling method based on a graph attention network and a sequence model in the above-mentioned embodiment.
[0170] The computer-readable storage medium provided in the present application may be, for example, a USB flash drive, but is not limited to electrical, magnetic, optical, electromagnetic, infrared or semiconductor systems, systems or devices, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM: Random Access Memory), a read-only memory (ROM: Read Only Memory), an erasable programmable read-only memory (EPROM: Erasable Programmable Read Only Memory or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM: CD-Read Only Memory), an optical storage device, a magnetic storage device, or any suitable combination of the above. In this embodiment, the computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, system or device. The program code contained on the computer-readable storage medium may be transmitted using any appropriate medium, including but not limited to: wires, optical cables, RF (Radio Frequency: Radio Frequency), etc., or any suitable combination of the above.
[0171] The computer-readable storage medium may be included in the low-carbon power generation dispatching device; or may exist independently without being assembled into the low-carbon power generation dispatching device.
[0172] The computer-readable storage medium carries one or more programs. When the one or more programs are executed by the low-carbon power generation dispatching device, the low-carbon power generation dispatching device:
[0173] Obtaining the power generation of each power generation type of power generation unit in the power generation system, and obtaining the power generation limit of each power generation unit in the power generation system, the power generation limit of each power plant, and the power generation limit of the power generation end;
[0174] The power generation of each of the generator sets is used as the carbon emission decision variable of the carbon emission evaluation calculation formula, and the corresponding first power generation constraint, second power generation constraint and third power generation constraint are constructed based on the power generation limit of the generator set, the power generation limit of the power plant and the power generation limit of the power generation end respectively;
[0175] constructing a power generation scheduling bipartite graph according to the carbon emission decision variables and the power generation constraint, and using the carbon emission evaluation calculation formula and the power generation constraint as sequence data;
[0176] Based on the graph attention network, the structural features of the power generation scheduling bipartite graph are extracted, and based on the long short-term memory network, the dependency relationship features between the sequence data are extracted;
[0177] The structural features are transferred to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and the dependency features are transferred to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning to obtain a target model;
[0178] The test set data is input into the target model to obtain the predicted data of the power generation of each of the generator sets.
[0179] The computer program code for performing the operation of the present application can be written in one or more programming languages or a combination thereof, including object-oriented programming languages, such as Java, Smalltalk, C++, and conventional procedural programming languages, such as "C" language or similar programming languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as an independent software package, partially on the user's computer and partially on the remote computer, or entirely on the remote computer or server. In the case of a remote computer, the remote computer can be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or can be connected to an external computer (for example, using an Internet service provider to connect through the Internet).
[0180] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present application. In this regard, each box in the flow chart or block diagram can represent a module, a program segment or a part of a code, and the module, the program segment or a part of the code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a sequence different from that marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented with a dedicated hardware-based system that performs the specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0181] The modules involved in the embodiments described in this application may be implemented by software or hardware, wherein the name of the module does not constitute a limitation on the unit itself in some cases.
[0182] The readable storage medium provided in this application is a computer-readable storage medium, which stores computer-readable program instructions (i.e., computer programs) for executing the above-mentioned low-carbon power generation scheduling method based on a graph attention network and a sequence model, which can solve the technical problem that the commonly used low-carbon power generation scheduling method not only has high computational cost, but also has to significantly improve its convergence and efficiency in high-dimensional constraint space, and cannot guarantee the finding of the global optimal solution. Compared with the prior art, the beneficial effects of the computer-readable storage medium provided in this application are the same as the beneficial effects of the low-carbon power generation scheduling method based on a graph attention network and a sequence model provided in the above-mentioned embodiment, which will not be repeated here.
[0183] The present application also provides a computer program product, including a computer program, which, when executed by a processor, implements the steps of a low-carbon power generation scheduling method based on a graph attention network and a sequence model as described above.
[0184] The computer program product provided by this application can solve the technical problem that the commonly used low-carbon power generation scheduling method not only has high computational cost, but also has to significantly improve its convergence and efficiency in high-dimensional constraint space, and cannot guarantee the finding of the global optimal solution. Compared with the prior art, the beneficial effects of the computer program product provided by this application are the same as the beneficial effects of a low-carbon power generation scheduling method based on a graph attention network and a sequence model provided by the above embodiment, which will not be elaborated here.
[0185] The above descriptions are only some embodiments of the present application, and are not intended to limit the patent scope of the present application. All equivalent structural changes made using the contents of the present application specification and drawings under the technical concept of the present application, or direct / indirect applications in other related technical fields are included in the patent protection scope of the present application.
Claims
1. A low-carbon power generation scheduling method based on graph attention network and sequence model, characterized in that: The method includes: Obtaining the power generation of each power generation type of power generation unit in the power generation system, and obtaining the power generation limit of each power generation unit in the power generation system, the power generation limit of each power plant, and the power generation limit of the power generation end; The power generation of each of the generator sets is used as a carbon emission decision variable in the carbon emission evaluation calculation formula, and corresponding power generation constraints are constructed based on the power generation limit of the generator set, the power generation limit of the power plant and the power generation limit of the power generation end, respectively, and the power generation constraints include a first power generation constraint, a second power generation constraint and a third power generation constraint; constructing a power generation scheduling bipartite graph according to the carbon emission decision variables and the power generation constraint, and using the carbon emission evaluation calculation formula and the power generation constraint as sequence data; Based on the graph attention network, the structural features of the power generation scheduling bipartite graph are extracted, and based on the long short-term memory network, the dependency relationship features between the sequence data are extracted; The structural features are transferred to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and the dependency features are transferred to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning to obtain a target model; The test set data is input into the target model to obtain the predicted data of the power generation of each of the generator sets.
2. The method according to claim 1, characterized in that The steps of constructing a bipartite graph for power generation scheduling according to the carbon emission decision variables and the power generation constraint, and using the carbon emission evaluation calculation formula and the power generation constraint as sequence data include: Combining the carbon emission evaluation calculation formula and the power generation constraint to construct a low-carbon power generation scheduling problem; Encode the low-carbon power generation scheduling problem to obtain the power generation scheduling bipartite graph, wherein the power generation scheduling bipartite graph includes a carbon emission decision variable node, a power generation constraint node, and an edge connecting the carbon emission decision variable node and the power generation constraint node; A target vector is formed based on the carbon emission evaluation calculation formula, and a constraint vector is formed based on the first power generation constraint, the second power generation constraint and the third power generation constraint. The sequence data includes the target vector and the constraint vector.
3. The method according to claim 2, characterized in that The step of extracting the structural features of the power generation scheduling bipartite graph based on the graph attention network includes: capturing the influence of the carbon emission decision variable on the power generation constraint according to the first level message transmission from the carbon emission decision variable node to the power generation constraint node; Determining the reaction of the power generation constraint to the carbon emission decision variable according to the second level message transmission from the power generation constraint node to the carbon emission decision variable node; Based on the influence of the carbon emission decision variables on the power generation constraint and the reaction of the power generation constraint on the carbon emission decision variables, the structural characteristics of the power generation scheduling bipartite graph are obtained.
4. The method according to claim 2, characterized in that The step of extracting dependency features between the sequence data based on the long short-term memory network includes: Passing the target vector and the constraint vector to the long short-term memory network to determine the candidate memory state and the gating value of the output gate; Obtaining a hidden state according to the candidate memory state and the gating value of the output gate; The dependency characteristic is determined based on the hidden state.
5. The method according to claim 1, characterized in that Before the steps of transferring the structural features to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and transferring the dependency features to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning, the steps further include: Incorporating the power generation constraint into the carbon emission evaluation calculation formula in the form of a penalty term to obtain the first self-supervisory loss function; and Determine to minimize the difference between the current dual estimate and the predicted dual variable, and construct the second self-supervised loss function based on the difference.
6. The method according to claim 5, characterized in that The steps of transferring the structural features to the first self-supervised loss function of the graph attention network training to perform graph attention network learning, and transferring the dependency features to the second self-supervised loss function of the long short-term memory network training to perform long short-term memory network learning to obtain the target model include: Passing the structural features to the graph attention network to obtain predicted carbon emission decision variables; Passing the predicted carbon emission decision variable to the first self-supervised loss function, and optimizing the model parameters of the graph attention network by a gradient descent method to obtain an updated graph attention network; and, Passing the dependency feature to the long short-term memory network to obtain the predicted dual variable; Passing the predicted dual variable to the second self-supervised loss function, and updating the model parameters of the long short-term memory network through gradients to obtain an updated long short-term memory network; Based on the updated graph attention network and the updated long short-term memory network, the target model is obtained.
7. The method according to claim 5, characterized in that The step of inputting the test set data into the target model to obtain the prediction data of the power generation of each of the generator sets comprises: Inputting the test set data into the target model for forward propagation calculation; The data output by the target model is subjected to inverse normalization processing to obtain predicted data of power generation of each of the generator sets.
8. The method according to any one of claims 1 to 7, characterized in that The power generation types include fossil fuel power generation, nuclear power generation and renewable energy power generation; the carbon emission evaluation calculation formula is composed of the fossil fuel power generation carbon emission calculation formula, the nuclear power generation carbon emission calculation formula and the renewable energy power generation carbon emission calculation formula; the step of using the power generation of each of the generator sets as the carbon emission decision variable of the carbon emission evaluation calculation formula includes: The power generation of the fossil fuel power generation generator set is used as the carbon emission decision variable of the fossil fuel power generation carbon emission calculation formula; The power generation of the nuclear power generation unit is used as the carbon emission decision variable of the nuclear power generation carbon emission calculation formula; The power generation of the generator set generated by the renewable energy power generation is used as the carbon emission decision variable of the carbon emission calculation formula of the renewable energy power generation.
9. A low-carbon power generation dispatching device, characterized in that: The device includes: a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the computer program is configured to implement the steps of a low-carbon power generation scheduling method based on a graph attention network and a sequence model as described in any one of claims 1 to 8.
10. A storage medium, characterized in that: The storage medium is a computer-readable storage medium, and a computer program is stored on the storage medium. When the computer program is executed by a processor, the steps of a low-carbon power generation scheduling method based on a graph attention network and a sequence model as described in any one of claims 1 to 8 are implemented.
Citation Information
Patent Citations
Multi-source cooperative power system rolling scheduling method, system and device based on bipartite graph-graph convolutional neural network, and storage medium
CN118693874A