Energy load prediction method based on layered space-time fusion graph LSTM network
By constructing a physical topology graph and a semantic function graph through a hierarchical spatiotemporal fusion graph LSTM network (HSTF-GL), and combining adaptive fusion gates and spatiotemporally alternating LSTM units, the problem of existing models being unable to capture multi-level dependencies of energy load is solved, and more efficient energy load prediction is achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- WUXI UNIV
- Filing Date
- 2026-02-04
- Publication Date
- 2026-05-15
AI Technical Summary
Existing spatiotemporal GNN models cannot effectively capture the multi-level and complex dependencies of energy load, especially when grid load and renewable energy production fluctuate, resulting in poor prediction performance and low robustness.
The hierarchical spatiotemporal fusion graph LSTM network (HSTF-GL) is adopted. By constructing a physical topology graph and a semantic function graph, and combining dual adaptive fusion gates and spatiotemporally alternating LSTM units, the spatial dependencies of the fusion nodes are dynamically learned and fused to achieve deep spatiotemporal dynamic interaction.
It improves the accuracy and stability of energy load forecasting, better captures the complex spatial dependencies and temporal evolution between nodes, and enhances the model's spatiotemporal perception capabilities.
Smart Images

Figure CN122047902A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of energy technology, and more specifically, to an energy load forecasting method based on a hierarchical spatiotemporal fusion graph LSTM network. Background Technology
[0002] With the rapid development of smart grids and the widespread application of renewable energy, energy management has entered a new era characterized by large volumes of dynamic and complex data. In this context, accurate energy load forecasting is not only central to this transformation but also plays a crucial role in ensuring grid stability, optimizing energy dispatch, and achieving efficient demand response.
[0003] As energy networks gradually transition to smart grids, the uncertainty and volatility of electricity demand make accurate load forecasting even more crucial. Traditional forecasting methods often fail to meet the needs of modern power grids, especially given fluctuations in grid load and renewable energy production. To address this challenge, deep learning models, particularly those capable of capturing spatiotemporal dependencies, have become a key technology in modern forecasting systems, providing efficient and accurate forecasting support for grid management.
[0004] Among various deep learning methods, Graph Neural Networks (GNNs) have been widely applied to model the inherent non-Euclidean relational structures in energy systems, such as transmission networks, distribution networks, or distributed metering networks. By propagating information along the edges of the graph, GNN-based models can effectively aggregate information from neighboring nodes, thereby improving node-level prediction accuracy. Unlike traditional sequence models, GNNs can capture complex spatial dependencies between nodes. However, existing spatiotemporal GNN models typically rely on a single, static, and often homogeneous graph structure to represent all spatial relationships. This simplistic assumption fails to capture the multi-layered complex dependencies in the dynamic changes of energy load, especially when energy load is influenced not only by physical connectivity but also by macroscopic factors such as regional functions and social activities.
[0005] Specifically, the load on a node is affected not only at the micro level by the physical topology (e.g., electrical connections and power flow in a distribution network) but also at the macro level by regional functional similarities (e.g., areas with similar commercial or residential characteristics may exhibit synchronized consumption patterns). Therefore, methods that use only physical adjacency graphs or fully connected similarity graphs either fail to capture functional correlations or introduce noise and non-causal dependencies, resulting in poor prediction performance and low robustness.
[0006] To address this issue, this invention proposes a hierarchical spatiotemporal fusion graph LSTM network (HSTF-GL) designed to explicitly model and integrate these multi-layered dependencies. Summary of the Invention
[0007] In view of this, this invention proposes an energy load forecasting method based on a hierarchical spatiotemporal fusion graph LSTM network, which dynamically learns the importance of different graph information at each node and time step. Subsequently, the spatiotemporal LSTM unit processes the fused spatial representation, alternating between graph-based aggregation operations and time-gating mechanisms, thereby achieving deep interaction between spatial dynamics and temporal dynamics.
[0008] The specific implementation of the technical solution of this invention is as follows: The energy load forecasting method based on hierarchical spatiotemporal fusion graph LSTM network includes the following steps: Define the energy load forecasting task and construct a hierarchical spatiotemporal fusion graph LSTM network; For the energy load prediction task, the hierarchical spatiotemporal fusion graph LSTM network analyzes historical energy load instances and constructs physical topology graphs and semantic function graphs based on raw data or prior knowledge. A gating mechanism is used to dynamically aggregate spatial context information from the physical topology graph and the semantic function graph to obtain fused features; Spatiotemporal alternating LSTM units are used to perform spatiotemporal joint memory evolution on the fused features, and the energy load prediction results are output.
[0009] Furthermore, the physical topology graph is constructed based on the power grid topology or the geographical distance between nodes, and the edge weights are calculated using a threshold Gaussian kernel:
[0010] in, It is a node and Geographical distance between them Control the decay rate, It is a distance threshold. It is an indicator function.
[0011] Furthermore, the semantic function graph is constructed based on the Pearson correlation coefficient of historical load sequences, and the edge weights are calculated using softmax normalization.
[0012] in, Let k be the correlation coefficient between nodes i and k. Represents a node The former The most relevant set of neighbors.
[0013] Furthermore, the gating mechanism is implemented through a dual adaptive fusion gate, and the fusion gate weights are calculated as follows:
[0014] in, From the physical topology diagram, Derived from the semantic function graph, || indicates a connection along the feature dimension. and These are learnable parameters.
[0015] Furthermore, the process of dynamically aggregating spatial context information from the physical topology graph and the semantic function graph using a gating mechanism includes: At each time step, the input node features are obtained by performing a linear transformation on the original observations; Graph convolution is applied to the physical topology graph and the semantic function graph respectively to obtain specific graph features; The specific graph features are calculated using a dual adaptive fusion gate to obtain the fused features.
[0016] Furthermore, the fusion feature The calculation is as follows:
[0017] in, , Represents specific graph features, From the physical topology diagram, From the semantic function graph, For fusion gate weights.
[0018] Furthermore, the spatiotemporally alternating LSTM unit alternates between graph convolution and LSTM gating, performing the following operations at each time step: Using the fused features and the hidden state of the previous time step as input, the spatial memory is obtained by spatially aggregating the previous hidden state through the GCN layer. The spatial memory weights are dynamically adjusted through the gating mechanism. By combining the current fusion features with the spatial memory, the LSTM cell state is updated, and the hidden state is obtained through the output gate.
[0019] Furthermore, the equations for updating the LSTM cell states and hidden states are as follows:
[0020] in, and These are the forget gate and the input gate, which work by modifying the connection features. The sigmoid activation is calculated to obtain, For spatial memory, and These are learnable parameters.
[0021] Compared with the prior art, the beneficial effects of the present invention are as follows: This invention proposes a dual-graph structure for energy prediction, comprising a physical topology graph and a semantic function graph. These two graph structures focus on the physical connectivity and semantic function similarity of nodes, respectively, thus enabling a more comprehensive modeling of spatial dependencies.
[0022] This invention designs a dual adaptive fusion gate mechanism that can dynamically learn the importance of specific information about each node in the graph at each time step. This mechanism enables the model to automatically adjust the fusion of physical constraints and semantic interactions under different time steps and node features, enhancing the model's spatiotemporal awareness.
[0023] This invention proposes a spatiotemporal LSTM unit that achieves deep coupling of spatial aggregation and temporal dynamics by alternately executing graph-based propagation and LSTM gating operations. This unit enables spatial dependencies to evolve over time and provides information for temporal memory through multi-hop neighbor states, effectively capturing spatiotemporal interactions. Attached Figure Description
[0024] Various other advantages and benefits will become apparent to those skilled in the art upon reading the following detailed description of preferred embodiments. The accompanying drawings are for illustrative purposes only and are not intended to limit the invention. In the drawings: Figure 1 This is a schematic diagram of the hierarchical spatiotemporal fusion graph LSTM network HSTF-GL structure proposed in this invention; Figure 2 The results show the performance comparison of the proposed hierarchical spatiotemporal fusion graph LSTM network HSTF-GL with other traditional models on a public energy prediction dataset. Figure 3 The results of the ablation experiment of the hierarchical spatiotemporal fusion graph LSTM network HSTF-GL proposed in this invention on the BDGP2 dataset; Figure 4 The results of the hierarchical spatiotemporal fusion graph LSTM network HSTF-GL proposed in this invention and other traditional models are compared on the BDGP2 dataset with different prediction step sizes. Detailed Implementation
[0025] Exemplary embodiments of the present disclosure will now be described in more detail with reference to the accompanying drawings. While exemplary embodiments of the present disclosure are shown in the drawings, it should be understood that the present disclosure may be implemented in various forms and should not be limited to the embodiments set forth herein. Rather, these embodiments are provided to enable a more thorough understanding of the present disclosure and to fully convey the scope of the disclosure to those skilled in the art. It should be noted that, unless otherwise specified, the embodiments and features described herein can be combined with each other. The present invention will now be described in detail with reference to the accompanying drawings and embodiments.
[0026] This embodiment proposes an energy load forecasting method based on a hierarchical spatiotemporal fusion graph LSTM network, focusing primarily on the energy load forecasting task and aiming to support the power industry. This task involves multiple time series data. Each time step... ,make express The goal of this embodiment is to analyze a historical energy load instance, denoted as [values in a series]. The length of each series is The goal of this embodiment is to predict the next... Step load value, denoted as This embodiment develops a mapping function using the proposed model. .
[0027] Overall framework (Overview) Existing methods based on a single static graph, such as STGCN, typically assume that the relationships between nodes are uniform and fixed. However, in energy systems, the states of nodes are driven by two distinct mechanisms: causal propagation characteristics determined by the hard constraints of the physical network, and soft coordination induced by similar functional or social behavioral patterns. Compressing these two fundamentally different dependencies into a single adjacency matrix obscures their respective propagation patterns, limiting the model's expressiveness and interpretability.
[0028] Therefore, this embodiment proposes a hierarchical spatiotemporal fusion graph LSTM network (HSTF-GL). The core idea is to explicitly separate and model the spatial dependencies between two layers, and then dynamically fuse them through carefully designed memory units. This enables the model to jointly capture both spatial dependencies and temporal evolution. As... Figure 1 As shown, HSTF-GL comprises three key stages, forming a complete process from data to prediction: 1. Hierarchical graph structure construction: Construct physical topology graphs and semantic function graphs using raw data or prior knowledge.
[0029] 2. Adaptive Feature Fusion: Uses a gating mechanism to dynamically aggregate spatial context information from the two graphs.
[0030] 3. Spatiotemporal Joint Memory Evolution: Graph-based spatial aggregation and gated temporal updates are executed alternately within recursive units to achieve deep coupling.
[0031] Hierarchical Graph Construction In this embodiment, two different graphs are constructed to model different types of relationships between nodes in the system: a physical topology graph and a semantic function graph, which share the same set of nodes. Size is These two types of graphs capture complementary aspects of node relationships, providing a comprehensive representation that takes into account both physical and semantic dependencies.
[0032] Physical topology diagram The constraints enforced by the physical network are encoded. In cases where the exact power grid topology is unavailable, this embodiment approximates the network structure by using the geographical distance between nodes. and nodes The edge weights between them are calculated using a threshold Gaussian kernel:
[0033] in, It is a node and Geographical distance between them Control the decay rate, It is a distance threshold. It is an indicator function that ensures that when the distance is less than a threshold... The edge only exists at that time.
[0034] Semantic Functional Diagram This embodiment captures behavioral similarities between nodes based on historical load sequences. To construct this graph, this embodiment computes nodes... and nodes Pearson correlation coefficient between historical load series This reflects the semantic similarity between them. Then, the softmax function is used to convert these correlation values into sparse, non-negative edge weights:
[0035] in, Represents a node The former A set of most relevant neighbors. In this way, each node connects to only a few semantically similar nodes. Both graph structures remain fixed during training and inference and are constructed only once from the training data. Therefore, by using these two graph structures, this embodiment can effectively capture the physical and semantic dependencies between nodes, enabling the model to learn and infer these relationships within a unified framework.
[0036] Adaptive Feature Fusion To dynamically fuse the information from these two graphs, this embodiment introduces a dual adaptive fusion gate. At each time step... ,make This represents the input node features, which are obtained through a linear transformation of the original observations. First, in this embodiment, graph convolution is applied to each graph to obtain graph-specific features: From the physical topology diagram, It is derived from the semantic function graph and computed using the standard GCN layer.
[0037] Next, the fusion gate calculates the weight vector for each node. :
[0038] Where || denotes connection along the feature dimension, and These are learnable parameters. It uses the sigmoid activation function. Then, the fused features... Calculated as a weighted combination of two graph features:
[0039] in, It involves element-wise multiplication. This adaptive fusion mechanism allows each node to dynamically emphasize information from the physical or semantic graph based on the current context.
[0040] Spatio-Temporal Joint Memory Evolution Traditional methods separate spatial aggregation and temporal modeling, failing to capture the evolution of spatial dependencies. To address this limitation, this embodiment introduces a spatiotemporally alternating LSTM (ST-ALSTM) unit, which alternates between graph convolution and LSTM gating.
[0041] At each time step This unit features fusion characteristics The hidden state of the previous time step For input. First, this embodiment uses a GCN layer, similar to a feature fusion step, to spatially aggregate the previous hidden state to obtain spatial memory. and through similar adaptive gate calculate.
[0042] Then, in this embodiment, the state of the LSTM unit is updated by combining the current input and spatial memory. The core LSTM unit state update equation is:
[0043] in, and These are forget gates and input gates, which work by modifying the connection features. The sigmoid activation is calculated. Then, the hidden state is obtained through the output gate. This design ensures that spatial dependencies are introduced in every temporal update, allowing the model to co-evolve its spatial and temporal representations within a unified framework.
[0044] Experiment Experimental Setup Dataset The HSTF-GL model was evaluated using two publicly available energy forecasting datasets, representing energy systems of different sizes and characteristics: The ETT (Electricity Transformer Temperature) dataset contains two years of power transformer load and temperature data from two counties in China. Data is recorded hourly and includes six power load characteristics (such as high load and low load) and oil temperature as the target variable. This embodiment uses the ETTm1 subset, which has a 15-minute sampling interval and a total of 69,680 time steps. The dataset is divided chronologically into 80% training set, 10% validation set, and 10% test set.
[0045] The Building Data Genome Project 2 (BDGP2) dataset is a large-scale dataset containing energy consumption data from 1,636 non-residential buildings across multiple climate zones. This example selects a subset of 300 commercial and educational buildings with complete hourly data for 2016-2017. Each building serves as a node in the graph, and the dataset also includes rich metadata (such as primary space use and floor area) for semantic graph construction. The dataset is also allocated 80% for training, 10% for validation, and 10% for testing.
[0046] Evaluation Metrics To evaluate the predictive performance of the model in this embodiment, two evaluation metrics widely used in time series forecasting are used: mean absolute error (MAE) and root mean square error (RMSE).
[0047] Compared Algorithms The HSTF-GL model is compared with several baseline methods, which fall into three categories: classic time series models, graph-based spatiotemporal models, and more recent transformer-based models.
[0048] Classic time series models include ARIMA, LSTM, and GRU, which are applied independently to each time series. They primarily focus on temporal dependencies without considering spatial relationships between nodes.
[0049] Graph-based spatiotemporal models such as STGCN, ASTGCN, MSGNET, and GraphWaveNet combine spatial and temporal dependencies and model them through graph convolutional layers. However, they rely on a single graph structure and cannot capture evolutionary dependencies as effectively as the model in this embodiment.
[0050] Transformer-based models, including Informer, Autoformer, and PatchTST, have made state-of-the-art progress in time series forecasting by leveraging attention mechanisms. They are particularly suitable for long-series forecasting, but typically treat each series separately, failing to fully capture spatial relationships.
[0051] By comparing HSTF-GL with these methods, this embodiment aims to demonstrate the advantages of using a dual-graph structure to dynamically model physical and semantic dependencies compared to traditional methods and transformer-based models.
[0052] Implementation Details The HSTF-GL model was implemented using PyTorch 1.12.1 and PyTorch Geometric 2.2.0 for graph computation. All experiments were performed on a server configured with an NVIDIA RTX 3090 GPU (24GB RAM), an Intel Xeon Gold 6226R CPU, and 128GB RAM. The hidden layer dimension was set to 64, and the model used two layers of ST-ALSTM units. In this embodiment, a dropout rate of 0.2 was applied to the GCN layer, and the parameter δ of the Huber loss function was set to 1.0. The model used the Adam optimizer with an initial learning rate of 0.001, which decayed to 0.5 every 20 epochs. Training used a batch size of 32, and an early stopping mechanism based on the validation set loss stopped training when the validation loss did not improve within 30 epochs. All models were trained for a maximum of 200 epochs, and the training data was normalized using z-score based on training statistics.
[0053] Experimental Results Experimental results are as follows Figure 2 As shown, the HSTF-GL model performs exceptionally well on both datasets, outperforming all baseline methods. On the ETT dataset, HSTF-GL outperforms other methods across all metrics. For 24-step predictions, HSTF-GL reduces the mean absolute error (MAE) by 8.7% and the root mean square error (RMSE) by 9.2% compared to AGCRN. The performance gap widens as the prediction range increases, indicating that HSTF-GL is better able to capture long-term dependencies, which is crucial for accurate energy prediction. On the BDGP2 dataset, HSTF-GL continues to lead, surpassing all methods and performing exceptionally well on both metrics. For 24-step predictions, HSTF-GL reduces MAE by 12.1% and RMSE by 11.8% compared to the second-best method, MSGNET. The improvement on the BDGP2 dataset is more significant than that on the ETT dataset, likely due to the richer semantic information provided in the BDGP2 dataset. The dual-graph structure of this embodiment effectively utilizes this semantic information, enhancing the model's ability to capture complex dependencies. Experimental results show that graph-based methods generally outperform traditional time series methods and transformer-based methods, highlighting the importance of modeling spatial dependencies in energy forecasting. Furthermore, models with adaptive graph learning mechanisms, such as MSGNET and AGCRN, perform better than models with fixed graph structures, demonstrating the advantages of learning dynamic graph structures during training.
[0054] Ablation Study Figure 3This paper presents ablation experiments on the BDGP2 dataset (24-step prediction, using MAE), clearly highlighting the importance of each core module in the HSTF-GL framework. Removing any key component leads to a significant performance degradation, as evidenced by the increased MAE across variants. The most significant degradation occurs when the semantic graph is removed, increasing MAE by 15.2%. This is due to the loss of crucial information about building functional similarity (such as usage patterns), which is essential for capturing energy consumption behavior beyond geographic proximity. Removing the physical graph results in a 9.8% increase in MAE, emphasizing the importance of spatial dependencies even with weak semantic relationships. Fusion gates and ST-ALSTM also contribute to model performance, but their impact is slightly less significant, increasing MAE by 8.3% and 9.1%, respectively. Fusion gates allow the model to dynamically adjust the weights of the physical and semantic graphs based on context, while ST-ALSTM helps capture joint spatiotemporal dynamics, which is impossible with static architectures.
[0055] Different Time Steps Prediction Analysis Figure 4 The MAE results are presented on the BDGP2 dataset at different prediction step sizes (6, 12, and 24 steps), clearly demonstrating the superior performance of the HSTF-GL model at each time step. As the prediction step size increases, the performance of all models decreases, which is expected due to the increased uncertainty in long-term predictions. However, HSTF-GL exhibits the smallest performance decline, with a relative increase in MAE of only 11.5% from 6 to 24 steps, compared to 11.4% for MSGNET and 11.6% for LSTM. Although the relative increases are similar across models, HSTF-GL shows a significantly smaller absolute increase, indicating its superior stability and generalization ability in capturing long-term spatiotemporal dependencies.
[0056] In summary, this invention proposes a novel hierarchical graph learning framework—HSTF-GL—for multi-source energy load forecasting. The core contribution of this invention lies in explicitly modeling and dynamically fusing two distinct spatial dependencies—physical topology and semantic functions—through three key innovations: a dual-graph construction method, an adaptive fusion gate, and a spatiotemporally alternating LSTM unit. Extensive experiments on the ETT and BDGP2 datasets demonstrate that HSTF-GL consistently outperforms existing state-of-the-art benchmark methods in prediction accuracy and provides interpretability regarding the dynamic interaction of physical and semantic factors with energy load. This approach provides a robust framework for complex spatiotemporal forecasting. Future work will focus on extending the model to accommodate larger networks, fusing more heterogeneous data sources, and improving its capabilities in uncertainty quantification and few-sample adaptation.
[0057] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention and not to limit it. Although the present invention has been described in detail with reference to the above embodiments, those skilled in the art should understand that modifications or equivalent substitutions can still be made to the specific implementation of the present invention. Any modifications or equivalent substitutions that do not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.
Claims
1. An energy load forecasting method based on a hierarchical spatiotemporal fusion graph LSTM network, characterized in that, include: Define the energy load forecasting task and construct a hierarchical spatiotemporal fusion graph LSTM network; For the energy load prediction task, the hierarchical spatiotemporal fusion graph LSTM network analyzes historical energy load instances and constructs physical topology graphs and semantic function graphs based on raw data or prior knowledge. A gating mechanism is used to dynamically aggregate spatial context information from the physical topology graph and the semantic function graph to obtain fused features; Spatiotemporal alternating LSTM units are used to perform spatiotemporal joint memory evolution on the fused features, and the energy load prediction results are output.
2. The method according to claim 1, characterized in that, The physical topology graph is constructed based on the power grid topology or geographical distances between nodes, and the edge weights are calculated using a threshold Gaussian kernel. , in, It is a node and Geographical distance between them Control the decay rate, It is a distance threshold. It is an indicator function.
3. The method according to claim 1, characterized in that, The semantic function graph is constructed based on the Pearson correlation coefficient of historical load sequences, and the edge weights are calculated using softmax normalization. , in, Let k be the correlation coefficient between nodes i and k. Represents a node The former The most relevant set of neighbors.
4. The method according to claim 1, characterized in that, The gating mechanism is implemented through a dual adaptive fusion gate, and the fusion gate weights are calculated as follows: , in, From the physical topology diagram, Derived from the semantic function graph, || indicates a connection along the feature dimension. and These are learnable parameters.
5. The method according to claim 1, characterized in that, The process of dynamically aggregating spatial context information from the physical topology graph and the semantic function graph using a gating mechanism includes: At each time step, the input node features are obtained by performing a linear transformation on the original observations; Graph convolution is applied to the physical topology graph and the semantic function graph respectively to obtain specific graph features; The specific graph features are calculated using a dual adaptive fusion gate to obtain the fused features.
6. The method according to claim 5, characterized in that, The fusion feature The calculation is as follows: , in, , Represents specific graph features, From the physical topology diagram, From the semantic function graph, For fusion gate weights.
7. The method according to claim 1, characterized in that, The spatiotemporally alternating LSTM unit alternates between graph convolution and LSTM gating, performing the following operations at each time step: Using the fused features and the hidden state of the previous time step as input, the spatial memory is obtained by spatially aggregating the previous hidden state through the GCN layer. The spatial memory weights are dynamically adjusted through the gating mechanism. By combining the current fusion features with the spatial memory, the LSTM cell state is updated, and the hidden state is obtained through the output gate.
8. The method according to claim 7, characterized in that, The equations for updating the LSTM cell states and hidden states are as follows: , in, and These are the forget gate and the input gate, which work by modifying the connection features. The sigmoid activation is calculated to obtain, For spatial memory, and These are learnable parameters.