A method for generating cognitive graphs for power grid dispatching based on dual graph structure and dual supervision
By adopting dual graph structure and dual supervision mechanism in power grid dispatching, combined with graph attention mechanism and adversarial learning, the problem of insufficient decoupling of entity expression in the existing technology is solved, and the instruction recommendation accuracy and decision-making quality of power grid dispatching are improved. .
Patent Information
- Application Number
- CN202210448132.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-04-27
- Publication Date
- 2024-09-06
- Estimated Expiration
- 2042-04-27
AI Technical Summary
Existing power grid cognitive map generation methods based on deep learning do not consider the impact of the surrounding environment and online human-computer interaction information when learning entity and relationship representations, resulting in weak decoupling of entity expressions and inability to effectively complete online recommendation or reasoning tasks. .
Using a method based on dual graph structure combined with dual supervision, the graph attention mechanism is used to integrate power grid data, resource data, environmental data and operation data to build a knowledge graph, and use online human-computer interaction information to conduct adversarial learning to generate knowledge about power grid dispatching. Know the map.
It effectively improves the accuracy and rationality of instruction recommendations, improves the quality of instruction actions, and improves decision-making effects.
Smart Images

Figure CN114781882B
Abstract
Description
Technical Field
[0001] The present invention relates to the field of intelligent power grid dispatching, and in particular to a method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision. Background Art
[0002] Most of the existing deep learning-based power grid cognitive graph generation methods only initialize the entities and relationships as specified dimensional vectors for fitting when learning the representation of entities and relationships (or actions) in the knowledge graph, without considering the specific impact of the surrounding environment on the entity representation, resulting in weak decoupling of entity expression.
[0003] Most of the existing deep learning-based power grid cognitive graph generation methods do not consider online human-computer interaction information when learning the representation of entities and relationships (or actions) in the knowledge graph, which results in the cognitive knowledge graph trained with offline data being unable to complete online recommendation or reasoning tasks well. Summary of the invention
[0004] In view of this, the purpose of the present invention is to provide a method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision, which can effectively improve the accuracy and rationality of instruction recommendations, improve the quality of instruction actions, and ultimately make the resulting decision-making effect better.
[0005] To achieve the above object, the present invention adopts the following technical solutions:
[0006] A method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision includes the following steps:
[0007] Step S1: Obtaining data sets related to power grid dispatching;
[0008] Step S2: Based on the prior knowledge of power grid dispatching, the corresponding knowledge graph structure is constructed by combining the entity states related to power grid dispatching and the corresponding dispatching actions;
[0009] Step S3: Based on the knowledge graph structure and the relationship between the state transitions of various power grid dispatch-related entities, the graph representation learning of nodes and power grid dispatch commands is performed, wherein the entity node state is obtained by integrating the characteristics of the power grid data itself, resource data, environmental data and operation data in the subgraph through the graph attention mechanism, and the action edge corresponds to the instruction action set in the historical data set, which is initialized by the neural network;
[0010] Step S4: Based on the obtained node representation and action edge representation, the instruction set representation set in the historical data of the power grid dispatching staff's instruction ticket is used for representation learning through the online human-computer interaction instruction information, and the obtained node representation information, action edge representation information, and human-computer interaction instruction information are obtained;
[0011] Step S5: Based on the node representation information, action edge representation information, and human-computer interaction instruction information obtained in step S4, first use the action edge information and node representation information to use graph embedding to train the graph attention mechanism fusion model for the node-related information in the subgraph, and then use the online human-computer interaction instruction information and the guidance action information based on cognitive graph reasoning to perform adversarial learning online, and constrain the update to apply the graph attention mechanism fusion model in the subgraph;
[0012] Step S6: Use the graph attention mechanism fusion model and graph representation learning mechanism to perform representation learning on the historical offline data set. On the one hand, it integrates the spatiotemporal factors in the environment, and on the other hand, it generates a cognitive graph applied to power grid dispatching based on the dual graph structure combined with the dual supervision mechanism.
[0013] Furthermore, the data set related to power grid dispatching includes power grid data, environmental data, resource data, operation data, and a dispatching instruction action set.
[0014] Furthermore, the step S2 is specifically as follows:
[0015] Step S2-1: The state of each power grid node is regarded as an entity node in the knowledge graph, where each entity node is represented by a subgraph containing several spatiotemporal factor nodes; the command action made for each power grid node state is used as the associated edge between the entity nodes; Step S2-2: The power grid node states of the entire data set are associated according to the edges corresponding to the command actions, and finally a knowledge graph containing the power grid node states and command actions in the data set is formed.
[0016] Furthermore, the step S3 is specifically as follows:
[0017] Step S3-1: According to the power grid node state, define the entity class corresponding to each power grid node state, and the number of entity classes is defined as n; at the same time, define the dimension size of each state input as embed_size;
[0018] Step S3-2: Initialize the representation learning of each power grid node state of the entity class according to each subgraph containing several spatiotemporal factor nodes, and the dimension of the initialization vector is embed_size;
[0019] A message passing function GA_f based on the graph attention mechanism is defined to embed environmental information in the node state:
[0020]
[0021]
[0022] Among them, i and j represent the subscripts of two adjacent nodes, k represents the subscript of the neighbor node, the first formula calculates the coefficient of the attention mechanism, and the second formula fuses the neighbor node information based on the graph attention mechanism. The neighbor nodes of these subgraphs represent the spatiotemporal factor information, and each subgraph shares the convolution kernel parameters of the graph attention mechanism;
[0023] Step S3-3: define the initialization vector dimension of the instruction action as 1*embed_size;
[0024] Step S3-4: According to the instruction action data set under the relevant node state, the corresponding record is obtained, which contains instance records corresponding to n entity classes as an n-tuple; based on the n-tuple, a triple of corresponding existence relationship (state i, instruction action r, state j) is generated, and the number of such triples is recorded as k. These k triples are used as inputs of the mature graph representation learning algorithm transH, and loss training is performed together to generate Embeddings corresponding to the power grid node state set and instruction action set.
[0025] Furthermore, the step S4 is specifically as follows:
[0026] Step S4-1: embedding the instruction action information based on online human-computer interaction according to the obtained node representation and action edge representation;
[0027] Step S4-2: Based on the graph representation learning of command actions and node states in the offline historical data set, action supervision constraints based on online human-computer interaction command information are added, and the graph embedding model obtained through preliminary training is enhanced in representation learning and fine-tuned in parameters to complete the construction of the graph representation learning model under the dual supervision mechanism.
[0028] Further, the step S5 is specifically as follows:
[0029] Step S5-1: Process the input data set, extract the shared spatiotemporal factors that affect the state of each power grid node, and then construct a subgraph with the shared spatiotemporal factors to embed environmental information into the node. Finally, abstract the subgraph into a node in graph embedding to form a node network, where the subgraph contains spatiotemporal factors f(1,...n), which are used to embed into node features.
[0030] Step S5-2: After the abstract nodes are defined by the subgraph, these nodes are used as nodes in the graph embedding and are initialized using the neural network;
[0031] Step S5-3: Set the number of training iterations epochs, and start training when epochs equals 1;
[0032] Step S5-4: Use TransH to train the graph embedding model based on the node information and instruction information;
[0033] Step S5-5: Calculate the embedding representation of the node plus the embedding representation of the adjacent edge and minimize the loss function of the adjacent nodes, and update the model parameters;
[0034] Step S5-6: Repeat step S5-3 within the value range defined by epochs to obtain a preliminary graph embedding model based on the dual graph structure;
[0035] Step S5-7: obtaining online human-computer interaction instruction information, and using the graph embedding model based on the dual graph structure initially obtained to perform representation learning on the instruction information;
[0036] Step S5-8: Minimize the loss function of the embedding representation of the calculation node plus the embedding representation of the instruction and the adjacent nodes, and update the model parameters;
[0037] Step S5-9: Repeat step S5-3 within the value range defined by epochs to obtain the final graph embedding model based on the dual graph structure combined with the dual supervision mechanism.
[0038] Compared with the prior art, the present invention has the following beneficial effects:
[0039] The present invention effectively improves the accuracy and rationality of instruction recommendations, improves the quality of instruction actions, and ultimately makes the resulting decision-making effect better. BRIEF DESCRIPTION OF THE DRAWINGS
[0040] Figure 1 It is a graph representation learning based on a dual graph structure in one embodiment of the present invention;
[0041] Figure 2 It is a dual supervision mechanism framework based on offline historical data sets and online human-computer interaction instructions in one embodiment of the present invention;
[0042] Figure 3 It is a cognitive graph generation framework for power grid dispatching based on a dual graph structure combined with dual supervision in one embodiment of the present invention. DETAILED DESCRIPTION
[0043] The present invention will be further described below in conjunction with the accompanying drawings and embodiments.
[0044] Please refer to Figure 1 The present invention provides a method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision, comprising the following steps:
[0045] Step S1: Acquire a data set related to power grid dispatching; the data set includes node-related information such as power grid data, environmental data, resource data, and operation data, as well as a dispatching instruction action set;
[0046] Step S2: Based on the prior knowledge of power grid dispatching, the corresponding knowledge graph structure is constructed by combining the entity states related to power grid dispatching and the corresponding dispatching actions;
[0047] Step S3: Utilize the knowledge graph constructed in step S2 and the relationship between the state transitions of each power grid dispatch-related entity in the power grid data set to perform graph representation learning on the nodes and power grid dispatch commands in the power grid data set in step S1, where the entity node state is obtained by integrating the power grid data characteristics, resource data, environmental data, operation data and other related information in the subgraph through the graph attention mechanism, and the action edge corresponds to the instruction action set in the historical data set, which is initialized directly by the neural network;
[0048] Step S4: Based on the obtained node representation and action edge representation, the instruction set representation set in the historical data of the power grid dispatching staff's instruction ticket is used for representation learning through the online human-computer interaction instruction information, and the obtained node representation information, action edge representation information, and human-computer interaction instruction information are obtained;
[0049] Step S5: Based on the node representation information, action edge representation information, and human-computer interaction instruction information obtained in step S4, first use the action edge information and node representation information to use graph embedding to train the graph attention mechanism fusion model for the node-related information in the subgraph, and then use the online human-computer interaction instruction information and the guidance action information based on cognitive graph reasoning to perform adversarial learning online, and constrain the update to apply the graph attention mechanism fusion model in the subgraph;
[0050] Step S6: Use the graph attention mechanism fusion model and graph representation learning mechanism to perform representation learning on the historical offline data set. On the one hand, it integrates the spatiotemporal factors in the environment, and on the other hand, it generates a cognitive graph applied to power grid dispatching based on the dual graph structure combined with the dual supervision mechanism.
[0051] In this embodiment, step S2 is specifically as follows:
[0052] Step S2-1: The state of each power grid node is regarded as an entity node in the knowledge graph, where each entity node is represented by a subgraph containing several spatiotemporal factor nodes; the command action made for each power grid node state is used as the associated edge between the entity nodes; Step S2-2: The power grid node states of the entire data set are associated according to the edges corresponding to the command actions, and finally a knowledge graph containing the power grid node states and command actions in the data set is formed.
[0053] In this embodiment, step S3 is specifically as follows:
[0054] Step S3-1: According to the power grid node state, define the entity class corresponding to each power grid node state, and the number of entity classes is defined as n; at the same time, define the dimension size of each state input as embed_size;
[0055] Step S3-2: Initialize the representation learning of each power grid node state of the entity class according to each subgraph containing several spatiotemporal factor nodes, and the dimension of the initialization vector is embed_size;
[0056] A message passing function GA_f based on the graph attention mechanism is defined to embed environmental information in the node state:
[0057]
[0058]
[0059] Among them, i and j represent the subscripts of two adjacent nodes, k represents the subscript of the neighbor node, the first formula calculates the coefficient of the attention mechanism, and the second formula fuses the neighbor node information based on the graph attention mechanism. The neighbor nodes of these subgraphs are preferably represented by the spatiotemporal factor information, and each subgraph shares the convolution kernel parameters of the graph attention mechanism;
[0060] Step S3-3: define the initialization vector dimension of the instruction action as 1*embed_size;
[0061] Step S3-4: According to the instruction action data set under the relevant node state, the corresponding record is obtained, which contains instance records corresponding to n entity classes as an n-tuple; based on the n-tuple, a triple of corresponding existence relationship (state i, instruction action r, state j) is generated, and the number of such triples is recorded as k. These k triples are used as inputs of the mature graph representation learning algorithm transH, and loss training is performed together to generate Embeddings corresponding to the power grid node state set and instruction action set.
[0062] In this embodiment, step S4 is specifically as follows:
[0063] Step S4-1: embedding the instruction action information based on online human-computer interaction according to the initial graph representation learning model obtained in step S3;
[0064] Step S4-2: Based on the graph representation learning of command actions and node states in the offline historical data set, action supervision constraints based on online human-computer interaction command information are added, and the graph embedding model obtained through preliminary training is enhanced in representation learning and fine-tuned in parameters to complete the construction of the graph representation learning model under the dual supervision mechanism.
[0065] In this embodiment, the power grid cognitive knowledge graph is implemented based on a graph embedding framework combining a dual graph structure with a dual supervision mechanism. Step S5 is specifically as follows:
[0066] Step S5-1: Process the input data set, extract the shared spatiotemporal factors that affect the state of each grid node, and then construct a subgraph with the shared spatiotemporal factors to embed environmental information into the node. Finally, abstract the subgraph into a node in graph embedding to form a node network. The network structure is as follows: Figure 1 As shown, the subgraph contains spatiotemporal factors f(1,...n), which are used to embed into node features;
[0067] Step S5-2: After the abstract nodes are defined by the subgraph, these nodes are used as nodes in the graph embedding and are initialized using the neural network;
[0068] Step S5-3: Set the number of training iterations epochs, and start training when epochs equals 1;
[0069] Step S5-4: Use TransH to train the graph embedding model based on the node information and instruction information;
[0070] Step S5-5: Calculate the embedding representation of the node plus the embedding representation of the adjacent edge and minimize the loss function of the adjacent nodes, and update the model parameters;
[0071] Step S5-6: Repeat step S5-3 within the value range defined by epochs to obtain a preliminary graph embedding model based on the dual graph structure;
[0072] Step S5-7: obtaining online human-computer interaction instruction information, and using the graph embedding model based on the dual graph structure initially obtained to perform representation learning on the instruction information;
[0073] Step S5-8: Calculate the embedding representation of the node plus the embedding representation of the instruction and the loss function of the adjacent nodes to update the model parameters, such as Figure 2 As shown;
[0074] Step S5-9: Repeat step S5-3 within the value range defined by epochs to obtain the final graph embedding model based on the dual graph structure combined with the dual supervision mechanism, such as Figure 3 shown.
[0075] The above description is only a preferred embodiment of the present invention. All equivalent changes and modifications made according to the scope of the patent application of the present invention should fall within the scope of the present invention.
Claims
1. A method for generating cognitive graphs for power grid dispatching based on dual graph structure combined with dual supervision, characterized in that: The following steps are involved: Step S1: Obtaining data sets related to power grid dispatching; Step S2: Based on the prior knowledge of power grid dispatching, the corresponding knowledge graph structure is constructed by combining the entity states related to power grid dispatching and the corresponding dispatching actions; Step S3: Based on the knowledge graph structure and the relationship between the state transitions of various power grid dispatch-related entities, the graph representation learning of nodes and power grid dispatch commands is performed, wherein the entity node state is obtained by fusing the power grid data characteristics, resource data, environmental data and operation data in the subgraph through the graph attention mechanism, and the action edge corresponds to the instruction action set in the historical data set, which is initialized by the neural network; Step S4: Based on the obtained node representation and action edge representation, the instruction set representation set in the historical data of the power grid dispatching staff's instruction ticket is used for representation learning through the online human-computer interaction instruction information, and the obtained node representation information, action edge representation information, and human-computer interaction instruction information are obtained; Step S5: Based on the node representation information, action edge representation information, and human-computer interaction instruction information obtained in step S4, first use the action edge information and node representation information to use graph embedding to train the graph attention mechanism fusion model for the node-related information in the subgraph, and then use the online human-computer interaction instruction information and the guidance action information based on cognitive graph reasoning to perform adversarial learning online, and constrain the update to apply the graph attention mechanism fusion model in the subgraph; Step S6: Using the graph attention mechanism fusion model and the graph representation learning mechanism to perform representation learning on the historical offline data set, on the one hand, the spatiotemporal factors in the environment are integrated, and on the other hand, a cognitive graph applied to power grid dispatching is generated based on the dual graph structure combined with the dual supervision mechanism; The step S3 is specifically as follows: Step S3-1: According to the power grid node state, define the entity class corresponding to each power grid node state, and the number of entity classes is defined as n; at the same time, define the dimension size of each state input as embed_size; Step S3-2: Initialize the representation learning of each power grid node state of the entity class according to each subgraph containing several spatiotemporal factor nodes, and the dimension of the initialization vector is embed_size; A message passing function GA_f based on the graph attention mechanism is defined to embed environmental information in the node state: Among them, i and j represent the subscripts of two adjacent nodes, k represents the subscript of the neighbor node, the first formula calculates the coefficient of the attention mechanism, and the second formula fuses the neighbor node information based on the graph attention mechanism. The neighbor nodes of these subgraphs represent the spatiotemporal factor information, and each subgraph shares the convolution kernel parameters of the graph attention mechanism; Step S3-3: define the initialization vector dimension of the instruction action as 1*embed_size; Step S3-4: According to the instruction action data set under the relevant node state, the corresponding record is obtained, which contains instance records corresponding to n entity classes as an n-tuple; based on the n-tuple, a triple of corresponding existence relationship (state i, instruction action r, state j) is generated, and the number of such triples is recorded as k. These k triples are used as inputs of the mature graph representation learning algorithm transH, and loss training is performed together to generate Embeddings corresponding to the power grid node state set and instruction action set.
2. The method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision according to claim 1 is characterized in that: The data set related to power grid dispatching includes power grid data, environmental data, resource data, operation data, and a dispatching instruction action set.
3. The method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision according to claim 1 is characterized in that: The step S2 is specifically as follows: Step S2-1: The state of each power grid node is regarded as an entity node in the knowledge graph, where each entity node is represented by a subgraph containing several spatiotemporal factor nodes; the command action made for each power grid node state is used as the associated edge between the entity nodes; Step S2-2: The power grid node states of the entire data set are associated according to the edges corresponding to the command actions, and finally a knowledge graph containing the power grid node states and command actions in the data set is formed.
4. The method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision according to claim 1, characterized in that: The step S4 is specifically as follows: Step S4-1: embedding the instruction action information based on online human-computer interaction according to the obtained node representation and action edge representation; Step S4-2: Based on the graph representation learning of command actions and node states in the offline historical data set, action supervision constraints based on online human-computer interaction command information are added, and the graph embedding model obtained through preliminary training is enhanced in representation learning and fine-tuned in parameters to complete the construction of the graph representation learning model under the dual supervision mechanism.
5. The method for generating a cognitive graph for power grid dispatching based on a dual graph structure combined with dual supervision according to claim 1, characterized in that: The step S5 is specifically: Step S5-1: Process the input data set, extract the shared spatiotemporal factors that affect the state of each power grid node, and then construct a subgraph with the shared spatiotemporal factors to embed environmental information into the node. Finally, abstract the subgraph into a node in graphembedding to form a node network, where the subgraph contains spatiotemporal factors f(1,...n), which are used to embed into node features. Step S5-2: After the abstract nodes are defined by the subgraph, these nodes are used as nodes in the graph embedding and are initialized using the neural network; Step S5-3: Set the number of training iterations epochs, and start training when epochs equals 1; Step S5-4: Use TransH to train the graph embedding model based on the node information and instruction information; Step S5-5: Calculate the embedding representation of the node plus the embedding representation of the adjacent edge and minimize the loss function of the adjacent nodes, and update the model parameters; Step S5-6: Repeat step S5-3 within the value range defined by epochs to obtain a preliminary graph embedding model based on the dual graph structure; Step S5-7: obtaining online human-computer interaction instruction information, and using the graph embedding model based on the dual graph structure initially obtained to perform representation learning on the instruction information; Step S5-8: Minimize the loss function of the embedding representation of the calculation node plus the embedding representation of the instruction and the adjacent nodes, and update the model parameters; Step S5-9: Repeat step S5-3 within the value range defined by epochs to obtain the final graph embedding model based on the dual graph structure combined with the dual supervision mechanism.
