CN-122021987-A - Power consumption prediction method and system based on causal inference
Abstract
The application discloses a power consumption prediction method and system based on causal inference, relates to the technical field of power consumption prediction, and solves the problem that a power consumption prediction model is degraded when being influenced by confounding factors. According to the embodiment of the application, the causal relation of the power consumption related variables is explicitly modeled, and the replacement characterization vector of the unobserved confounding factor is calculated based on the variation self-encoder to eliminate the confounding deviation, so that the prediction model can take more accurate causal characteristics as input, and can show stronger robustness and higher prediction accuracy when facing the data distribution change.
Inventors
- WANG ZHICHENG
- Zhong Yusha
- ZHANG HONGZHI
- XIAO HAIHUA
- Mai Disi
- LING BING
Assignees
- 广东电网有限责任公司管理科学研究院
Dates
- Publication Date
- 20260512
- Application Date
- 20251208
Claims (10)
- 1. A causal inference based electricity usage prediction method, the method comprising: Constructing a causal graph for describing the causal relation of electricity consumption based on field knowledge, wherein the nodes in the causal graph comprise electricity consumption nodes, environment variable nodes, user behavior characterization nodes, economic policy intervention variable nodes and unobserved confounding factor nodes, the causal graph is a directed acyclic graph, the unobserved confounding factor nodes are used for indicating common factors which affect a plurality of variables simultaneously and are not observed, the user behavior characterization nodes are used for indicating behavior characteristics of electricity consumption user groups, and the economic policy intervention variable nodes are used for indicating intervention time and strength of economic policy intervention; collecting historical observation data corresponding to nodes in the causal graph, and calculating derivative features based on the historical observation data; calculating, by a variational self-encoder, a surrogate token vector of unobserved confounding factors based on the causal graph, the historical observation data, and the derived features; Constructing and training a dual-branch neural network model, wherein the model comprises a result prediction branch and an intervention effect estimation branch, the input of the result prediction branch is an environment variable in the historical observation data, a user behavior representation in the derivative feature and the substitution representation vector, and the output is a basic prediction electricity consumption; And inputting the historical observation data, the derivative features and the substitution characterization vector into a dual-branch neural network model to obtain target prediction electricity consumption output by the dual-branch neural network model.
- 2. The method of claim 1, wherein constructing a causal graph for describing causal relationships of electricity usage based on domain knowledge comprises: constructing nodes of the causal graph based on the domain knowledge; The environment variable node is used as a reason node affecting the user behavior characterization node and the electricity consumption node, and a first corresponding edge is established; Taking the economic policy intervention variable node as a reason node affecting the user behavior characterization node, and establishing a second corresponding edge; taking the user behavior characterization node as an intermediate node affecting the electricity consumption node, and establishing a third corresponding edge; Based on the domain knowledge, taking the unobserved clutter factor node as a hidden variable node which affects a plurality of nodes simultaneously, and establishing a fourth corresponding edge; The causal graph is constructed based on the node, the first corresponding edge, the second corresponding edge, the third corresponding edge, and the fourth corresponding edge.
- 3. The method of claim 1, wherein the historical observation further comprises fine-grained electricity usage data for electricity users, and wherein the calculation flow of user behavior characterization comprises: carrying out non-invasive load decomposition on the fine-grained electricity consumption data to obtain the power of the main electricity consumption type of the electricity consumption user; Calculating the opening rate or average power of various electric equipment on the user group level based on the power of the main power class; based on the turn-on rate or the average power, constructing the user behavior characterization reflecting aggregate user decision intent.
- 4. The method of claim 2, wherein the calculating, by a variational self-encoder, an alternative characterization vector for unobserved confounding factors based on the causal map, the historical observation data and the derived features comprises: determining an influence confounding node affected by the unobserved confounding factor node based on a fourth corresponding edge in the causal graph; and inputting the historical observation data and the derivative features corresponding to the influence hybrid nodes into the variation self-encoder to obtain the substitution characterization vector output by the variation self-encoder.
- 5. The method of claim 4, wherein the variational self-encoder is a cyclic neural network or a time convolution network structure, and wherein the input to the variational self-encoder comprises historical observations and derived features corresponding to the affected confounding nodes over a period of time.
- 6. The method of any one of claims 1-5, wherein after said building and training of a dual-branch neural network model, the method further comprises: receiving a counterfacts query, the counterfacts query including a specified historical time period and a hypothetical economic policy intervention variable; Calculating a power consumption prediction sequence under the counter-facts intervention based on the historical observation data and the derivative features corresponding to the specified historical time period, the hypothetical economic policy intervention variable and the model; And quantifying causal effects of the hypothetical economic policy intervention based on comparing the predicted sequence of electricity usage with the sequence of actual electricity usage for the specified historical period of time.
- 7. The method of claim 6, wherein the calculating a predicted sequence of electricity usage under a counter-fact intervention based on the historical observation data and derived features corresponding to the specified historical time period, and the hypothetical economic policy intervention variable and the model, comprises: initializing user behavior characterization of the last time step corresponding to the initial time of the appointed historical time period; sequentially executing, at each time step of the anti-facts intervention simulation, calculating a current substitution representation vector by using the user behavior representation of the last time step and the current anti-facts intervention; the method comprises the steps of inputting a current environment variable, a user behavior representation of the last time step, a current substitution representation vector and a current counter fact intervention into the dual-branch neural network model to obtain a current counter fact prediction electricity consumption; and predicting the electricity consumption based on the current counter facts obtained in each time step, and constructing the electricity consumption prediction sequence.
- 8. A causal inference based electricity usage prediction system, applied to the method of any of claims 1-7, said system comprising: The system comprises a building module, a causal graph, a user behavior characterization node, an economic policy intervention variable node and an unobserved confounding factor node, wherein the building module is used for building a causal graph for describing the causal relationship of the electricity consumption based on domain knowledge, the nodes in the causal graph comprise an electricity consumption node, an environment variable node, a user behavior characterization node, an economic policy intervention variable node and an unobserved confounding factor node, the causal graph is a directed acyclic graph, the unobserved confounding factor node is used for indicating common factors which affect a plurality of variables simultaneously, and the unobserved common factors are not observed; The acquisition module is used for acquiring historical observation data corresponding to the nodes in the causal graph and calculating derivative characteristics based on the historical observation data; A calculation module for calculating, by a variational self-encoder, a surrogate token vector of unobserved confounding factors based on the causal graph, the historical observation data and the derived features; The building module is also used for building and training a dual-branch neural network model, the model comprises a result prediction branch and an intervention effect estimation branch, the input of the result prediction branch is an environment variable in the historical observation data, a user behavior characterization vector in the derivative feature and the substitution characterization vector, and the output is a basic prediction electricity consumption; and the prediction module is used for inputting the historical observation data, the derivative features and the substitution characterization vector into a dual-branch neural network model to obtain target prediction electricity consumption output by the dual-branch neural network model.
- 9. A computing device, comprising: A memory for storing a program; A processor for loading the program to perform the method of any of claims 1-7.
- 10. A computer readable storage medium, characterized in that the computer readable storage medium comprises a stored program, wherein the program, when run, controls a device in which the computer readable storage medium is located to perform the method of any one of claims 1-7.
Description
Power consumption prediction method and system based on causal inference Technical Field The invention relates to the technical field of electricity consumption prediction, in particular to an electricity consumption prediction method and system based on causal inference. Background In the fields of energy management, power grid dispatching, energy policy making and the like, the power consumption prediction is a core technical support for realizing refined operation and scientific decision-making. The accurate electricity consumption prediction can help the power supplier to reasonably allocate the power generation resources, reduce the power supply cost, and simultaneously assist the user in optimizing the electricity utilization strategy and reducing the energy waste, thereby having important significance for improving the energy utilization efficiency and ensuring the stable operation of the power system. Currently, most of the construction of the electricity consumption prediction model uses data correlation as core logic. In the prior art, historical electricity consumption data are collected, characteristic variables potentially related to the electricity consumption are mined, and then a mapping relation between the characteristic variables and the electricity consumption is established by adopting methods such as statistical analysis and machine learning, so that the future electricity consumption is predicted. The correlation-based prediction model can obtain a certain prediction effect in a scene of relatively stable data distribution, so that the correlation-based prediction model is widely applied to practical application. However, in the practical application process, the external environment and internal mechanism affecting the power consumption are always in dynamic change, and when the data distribution deviates due to the factors, the existing correlation-based model can have performance degradation due to the existence of a 'confounding factor'. By "confounding factor" is meant a potential variable that affects both the characteristic variable and the amount of electricity used, the effect of which is such that the correlation learned by the model is not truly causal, and once the external environmental changes cause the confounding factor's mode of influence to change, the mapping established by the model based on historical correlations will fail. In view of this, there is a need for a causal inference based electricity usage prediction method and system. Disclosure of Invention Aiming at the problem that the performance of the model is declined when the prior art is influenced by the confounding factor, the invention provides a power consumption prediction method and a power consumption prediction system based on causal inference, which can eliminate the confounding deviation in the causal relationship, so that the model shows stronger robustness and higher prediction accuracy when facing the data distribution change. The specific technical scheme is as follows: In a first aspect, an embodiment of the present application provides a causal inference-based electricity consumption prediction method, including: Constructing a causal graph for describing the causal relation of the electricity consumption based on the domain knowledge, wherein the nodes in the causal graph comprise electricity consumption nodes, environment variable nodes, user behavior characterization nodes, economic policy intervention variable nodes and unobserved confounding factor nodes; the causal graph is a directed acyclic graph, the unobserved confounding factor node is used for indicating a common factor which affects a plurality of variables simultaneously and is not observed, the user behavior characterization node is used for indicating behavior characteristics of a power utilization user group, the economic policy intervention variable node is used for indicating intervention time and strength of economic policy intervention, historical observation data corresponding to the causal graph node is collected and derivative characteristics are calculated based on the historical observation data, a replacement characterization vector of the unobserved confounding factor is calculated based on the causal graph, the historical observation data and the derivative characteristics through a variable self-encoder, a dual-branch neural network model is constructed and trained, the model comprises a result prediction branch and an intervention effect estimation branch, the input of the result prediction branch is an environment variable in the historical observation data, the user behavior characterization in the derivative characteristics and the replacement characterization vector, the input of the intervention effect estimation branch is an underlying prediction power consumption, the input of the intervention effect estimation branch is an economic intervention variable in the derivative characteristics and the replacem