A new energy power system load forecasting method based on weather-holiday information gating fusion

CN122529154APending Publication Date: 2026-08-07INFORMATION & TELECOMM COMPANY SICHUAN ELECTRIC POWER
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
INFORMATION & TELECOMM COMPANY SICHUAN ELECTRIC POWER
Filing Date
2026-05-14
Publication Date
2026-08-07

AI Technical Summary

Technical Problem

针对现有负荷预测模型对天气、节假日等多源异构特征融合能力不足,通常仅采用简单拼接或加法操作,难以捕捉二者间复杂的非线性交互关系,且模型复杂度高、难以实际部署的问题,本发明提出了一种天气-节假日信息门控融合的轻量级高精度负荷预测网络(WHGF- Net)

Benefits of technology

[0159] 1. Achieved deep nonlinear fusion of multi-source heterogeneous features: Through the designed gated fusion module, the difference, product operation and adaptive gating mechanism are introduced to explicitly model the complex context-dependent nonlinear interaction between weather and holiday features (such as the change of temperature sensitivity during holidays), which overcomes the information loss and insufficient modeling caused by simple feature splicing or weighted summation in traditional methods.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122529154A_ABST
    Figure CN122529154A_ABST
Patent Text Reader

Abstract

The application discloses a new energy power system load prediction method based on weather-holiday information gating fusion, and belongs to the field of power system prediction. The application aims to solve the problem that the traditional load prediction method is difficult to effectively fuse multi-source heterogeneous characteristics and capture complex space-time dependence. The method firstly constructs a multi-source feature embedding module, which respectively maps historical load, temperature and holiday information to a unified embedding space; designs a gating fusion module to dynamically fuse weather and holiday features through difference, product operation and adaptive gating, and captures their nonlinear interaction; adopts an adaptive embedding module containing Conv1d and LSTM to extract multi-scale time patterns of the load sequence; further, a double attention architecture is constructed to decouple the spatial correlation between nodes and the feature time dependence through a spatial attention layer and a weather-holiday attention layer, and a lightweight time coding is introduced; finally, the future period load prediction value is obtained through an output projection layer.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of power system load forecasting technology, and in particular to a new energy power system load forecasting method based on weather-holiday information gating fusion. Background Technology

[0002] With the large-scale integration of renewable energy sources such as wind and solar power into the power system, the intermittency and volatility of their output have significantly increased the uncertainty of grid operation. Against this backdrop, high-precision short-term load forecasting is crucial for ensuring the safe and stable operation of the power grid, optimizing dispatch decisions, and enhancing the absorption capacity of new energy sources. However, the load sequences of renewable energy power systems exhibit complex characteristics such as high dimensionality, strong nonlinearity, multi-scale time dependence, and dynamic spatiotemporal correlations. Furthermore, they are coupled with various external factors such as meteorological conditions and holiday arrangements, posing a significant challenge to traditional forecasting methods.

[0003] Currently, load forecasting methods can be mainly divided into model-based methods and data-driven methods. Model-based methods, such as time series analysis (ARIMA, SARIMA, etc.), rely on the assumption of stationarity and linear relationship modeling, making it difficult to characterize the complex nonlinear interactions between load and factors such as weather and holidays. Furthermore, they have strict requirements on data distribution and model form, resulting in limited generalization ability. Machine learning-based methods, such as Support Vector Machines (SVM) and Random Forests, can handle certain nonlinearities, but still heavily rely on manual feature engineering and struggle to effectively model long-term dependencies and spatiotemporal correlations of sequences.

[0004] In recent years, deep learning methods, represented by Recurrent Neural Networks (RNNs), Long Short-Term Memory Networks (LSTMs), and Transformers, have shown potential in load forecasting. These methods can automatically learn feature representations and capture temporal dependencies. However, they still have significant limitations in handling the fusion of multi-source heterogeneous features: most studies use simple feature concatenation or weighted addition to integrate information such as historical load, weather, and holidays. This approach implicitly assumes that features are independent or linearly superimposed, and cannot effectively model context-dependent nonlinear interactions such as "temperature sensitivity changes during holidays." Furthermore, although the standard Transformer architecture can capture global dependencies through self-attention mechanisms, its computational complexity is high, and it is not optimized for the unique "spatiotemporal separation dependencies" of electricity load data (i.e., the spatial correlation between nodes differs from the evolutionary nature of features along the time dimension), resulting in limited model efficiency and accuracy.

[0005] Specifically, existing methods have the following prominent problems when dealing with load forecasting tasks in new energy power systems:

[0006] 1. The multi-source feature fusion mechanism is simple: it fails to design an effective module to explicitly model the complex, dynamic, and nonlinear interactions between external features such as weather and holidays and loads, as well as between external features themselves.

[0007] 2. Spatiotemporal dependency modeling coupling: The failure to decouple and specifically model spatial correlation (between nodes) and temporal dependency (especially temporal patterns affected by external features) results in insufficient learning ability of the model for complex spatiotemporal patterns.

[0008] 3. Insufficient extraction of multi-scale time patterns: There is a lack of a hybrid encoding mechanism that can simultaneously and effectively capture local short-term fluctuations (such as hourly abrupt changes) and long-term global trends (such as daily cycles and weekly cycles) of the load sequence.

[0009] 4. Lack of adaptive balance in feature contribution: The model is prone to over-reliance on or neglect of certain external features and lacks a mechanism to dynamically adjust the contribution of different feature sources according to the context, which affects the robustness and accuracy of the prediction.

[0010] Therefore, there is an urgent need for a new load forecasting method that can deeply integrate multi-source heterogeneous information, accurately model spatiotemporal dependencies, adaptively balance feature contributions, and be applicable to scenarios with a high proportion of renewable energy. Summary of the Invention

[0011] The main objective of this invention is to overcome the shortcomings of existing technologies and provide a load forecasting method for new energy power systems based on weather-holiday information gating fusion. Addressing the problem that existing load forecasting models lack the ability to fuse multi-source heterogeneous features such as weather and holidays, typically employing only simple splicing or addition operations, making it difficult to capture the complex nonlinear interactions between the two, and also exhibiting high model complexity and difficulty in practical deployment, this invention proposes a lightweight, high-precision load forecasting network (WHGF-Net) based on weather-holiday information gating fusion. This model maps historical load, weather, and holiday features to a unified embedding space through a multi-source feature embedding module, and introduces a learnable scaling factor to adaptively balance the contributions of each feature. Building upon this, an innovative gated fusion module is designed to dynamically fuse weather and holiday information by constructing interactive features such as differences and products, and utilizing adaptive gating generation and confidence temperature adjustment to accurately characterize their context-dependent nonlinear interactions. Furthermore, an adaptive embedding module combining Conv1d and LSTM extracts multi-scale time patterns such as local fluctuations and long-term trends in the load sequence, and constructs a dual-attention architecture—a spatial attention layer focuses on the correlation between nodes, and a weather-holiday attention layer captures temporal dependencies. Lightweight learnable temporal encoding enhances time-series awareness, and finally, different prediction lengths are adapted through hybrid or separate projection modes to achieve efficient output. The entire model maintains high accuracy while having low parameter count, high computational efficiency, and ease of engineering deployment, effectively solving the challenge of deep fusion of weather and holiday information, and providing a practical and lightweight high-precision solution for load forecasting in new energy power systems.

[0012] To achieve the above objectives, the present invention adopts the following technical solution:

[0013] This invention proposes a load forecasting method for new energy power systems based on weather-holiday information gating fusion, characterized by the following steps:

[0014] S1: Construct a multi-source feature embedding module to map historical load data, weather data, and holiday information to a unified embedding space, and introduce a learnable scaling factor for weather and holiday embeddings to adaptively control their initial influence intensity.

[0015] S2: Construct a gating fusion module to dynamically fuse weather and holiday embedded features through difference, product operations and adaptive gating mechanisms in order to capture the complex nonlinear interaction between them;

[0016] S3: Construct an adaptive embedding module that combines a one-dimensional convolutional neural network with a long short-term memory network to collaboratively extract local short-term fluctuations and long-term global trends of the load sequence;

[0017] S4: Construct a dual attention architecture to model the spatial correlation between nodes and the temporal dependence of the weather-holiday fusion feature;

[0018] S5: Construct an output projection layer to map the encoded features to the load forecast values ​​for future periods;

[0019] S6: Train the constructed model using historical datasets, and optimize the model parameters by minimizing the loss function (such as mean squared error) between the predicted load and the actual load until the model converges;

[0020] S7: Apply the trained model, input real-time or recent multi-source feature data, and output the load forecast results of each node within a certain future period to support power grid dispatching decisions.

[0021] The detailed description of the construction of the multi-source feature embedding module described in S1 of the above method is as follows:

[0022] In practical power load forecasting, the input data contains various heterogeneous sources: historical load is continuous numerical data, weather data (such as temperature) is a scalar time series, and holiday information is represented by binary labels. These features have different dimensions, distributions, and semantic meanings. Directly concatenating or simply adding them can lead to feature space mismatch, making it difficult for the model to learn their inherent relationships. To solve this problem, it is necessary to map various features to a unified embedding space while preserving their original semantics and allowing the model to adaptively adjust the contribution of each feature. The difficulty in this part lies in the strong heterogeneity between data from different sources. For example, historical load is continuous time series data, temperature is a meteorological variable with obvious nonlinear effects, and holidays are discrete binary features. These data have significant differences in statistical distribution, data scale, and semantic expression. Directly concatenating or uniformly mapping them can easily lead to feature space mismatch, insufficient information expression, and the weakening of some features during training. To address this, we designed a multi-source feature embedding module. This paper proposes differentiated embedding methods for different types of features: linear projection is used to unify the dimensions of historical load and holiday features, and a multilayer perceptron (MLP) is introduced for temperature features to enhance nonlinear expressive power. At the same time, learnable scaling coefficients are introduced during the embedding process to adaptively adjust the contribution of features from different sources. This achieves effective alignment and information preservation of multi-source heterogeneous features in a unified embedding space, providing a stable and discriminative feature representation for subsequent gating fusion and attention modeling.

[0023] S11: Historical load data Linear projection is performed to map the data to a high-dimensional embedding space. Historical load is the primary input to the model, but the original values ​​are typically low-dimensional scalars (D=1), with limited expressive power. Increasing the dimensionality through linear transformation enhances feature representation, enabling subsequent modules to capture richer patterns. Specific formula:

[0024]

[0025] in It is a learnable weight matrix. It is a bias vector. It is the embedded dimension. Indicates the current time step. Indicates the number of historical time steps. Indicates the number of nodes (number of sensors). This represents the feature dimension of each node;

[0026] S12: Weather data (such as temperature) The model is mapped to the embedding space using a multilayer perceptron. A complex nonlinear relationship exists between weather factors and electricity load (e.g., both high summer temperatures and low winter temperatures increase electricity demand, but the impact curves differ), and simple linear projections are insufficient to characterize this dependency. Therefore, an MLP is used to introduce nonlinearity, enabling the model to adaptively adjust the temperature effect according to the context. The specific formula is as follows:

[0027]

[0028] in, and It is a weight matrix. and It is a bias vector. It is the hidden layer dimension. This involves modifying the linear unit activation function and introducing a learnable scaling factor to prevent weather features from overly dominating or weakening model predictions.

[0029]

[0030] in, It is a learnable scaling parameter. It is the sigmoid function;

[0031] S13: Holiday Data This is a binary vector representing whether each time step is a holiday. Holidays significantly alter industrial and commercial activities, thus affecting load patterns, but simple 0 / 1 markings cannot be directly used for model calculations. Embedding it into a continuous space through linear projection preserves the semantic information of holidays and allows the model to learn the interaction between holidays and other features. The specific formula is as follows:

[0032]

[0033] in It is a weight matrix. It is a bias vector, and a learnable scaling factor is introduced to control the influence of holiday features:

[0034]

[0035] in These are learnable scaling parameters. This design allows the model to adaptively adjust the weights of holiday features based on the data, preventing the over- or under-utilization of holiday information.

[0036] The detailed description of the gated fusion module construction described in S2 of the above method is as follows:

[0037] Although weather and holiday features are mapped to the same embedding space, there are complex nonlinear interactions between them (for example, weather sensitivity during holidays may be completely different from that on weekdays). Traditional feature concatenation or weighted summation assumes that features are independent or linearly additive, failing to capture such context-dependent interactions. To address this issue, we designed an enhanced gated fusion module, mainly composed of a fusion input construction layer, a gating weight generation layer, and a feature weighted fusion layer. Its core objective is to dynamically adjust the contributions of weather and holiday features through a gating mechanism and generate a fusion feature representation with stronger expressive power. First, weather and holiday features from the multi-source embedding module are input into the fusion input construction layer. In this stage, the module not only retains the original information of the two types of features but also characterizes the potential connections between the two types of factors by constructing difference relationship features and interaction relationship features. This information is then combined along the feature dimension to form a comprehensive input representation containing original features, difference information, and interaction information. Subsequently, the fused input is fed into the gate weight generation layer. In this part, a set of adaptive gate weights is learned through linear transformation and nonlinear activation functions to evaluate the importance of weather and holiday information in the current time context. Next, the signal stream enters the feature weighted fusion layer, where the gate weights adjust the weights of weather and holiday features dimensionally, strengthening important information while appropriately suppressing weakly correlated or noisy information. This, combined with the previously constructed interactive features, forms the final fused representation. Simultaneously, a temperature adjustment mechanism is introduced during the fusion process to smoothly control the distribution of the gate weights, preventing any one type of feature from having an excessively strong or weak influence. The final fused feature not only retains the individual influence information of weather and holidays but also explicitly characterizes the nonlinear synergistic relationship between them, and continues to participate in model calculations as input to subsequent attention or prediction modules.

[0038] S21: Fusion Input Construction

[0039] Weather embedding features are Holiday embedding features are Where De is the embedding dimension, interactive features are generated through the following operations:

[0040] S211: Preservation of original features: Direct inclusion and Preserve basic semantic information;

[0041] S212: Difference Characteristics: Calculation To depict the relative differences between the two;

[0042] S213: Product characteristics: Calculation To capture the synergistic enhancement effect of the two;

[0043] The four types of features mentioned above are concatenated along the last dimension to construct a gated input. ,Right now:

[0044]

[0045] Indicates a splicing operation;

[0046] The reason for this construction is that the difference feature can reflect the degree of deviation between the two, while the product feature can strengthen the co-activated pattern. These interactive features provide rich information for subsequent gating generation.

[0047] S22: Adaptive Gated Generation

[0048] S221: The gated MLP structure is designed as follows:

[0049]

[0050] MLP stands for Multilayer Perceptron. For the hidden layer dimension of MLP, This is the gated output dimension, and its value is determined by the fusion granularity. It is a modified linear unit activation function. Indicates a linear transformation layer;

[0051] Element-level gating: when At the same time, the gating weights are consistent with the embedded feature dimensions, and the weights can be adjusted independently for each feature dimension to adapt to fine-grained feature interactions;

[0052] Scalar gating: when When =1, the gating weight is a scalar, and all feature dimensions share the same weight, which reduces computational complexity and enhances stability;

[0053] S222: Introduces a confidence-based temperature regulation mechanism, which learns the temperature coefficient through an independent MLP and dynamically adjusts the gating sharpness.

[0054]

[0055]

[0056] Where τ is the temperature scaling factor. This represents the activation function. Indicates an independent multilayer perceptron. This represents the dynamic temperature coefficient. The mechanism works as follows: when there is a strong interaction between weather and holidays (e.g., extreme weather combined with holidays), the temperature coefficient makes the gating sharper (weights approaching 0 or 1), reinforcing dominant features; when the interaction is weak, the gating is smoother (weights approaching 0.5), achieving uniform fusion. This adaptive temperature adjustment improves the model's adaptability to dynamic scenarios.

[0057] S23: Feature Fusion and Optimization

[0058] S231: Execution Gated Fusion:

[0059]

[0060] in This represents element-wise multiplication, which uses a linear combination of weather and holiday features with gating weights to achieve dynamic fusion.

[0061] S232: Preserve original feature information through residual connections:

[0062]

[0063] in As residual weights, introducing residual connections can avoid the loss of basic information in the original features during the fusion process, and at the same time, the original features are prevented from becoming overly dominant by using smaller weights.

[0064] S233: Further optimize the representational capability of fused features through LayerNorm and refined MLP:

[0065]

[0066]

[0067] in To fuse feature output dimensions, To normalize layers, LayerNorm enables stable training, refines the MLP to enhance non-linearity, and finally adjusts the dimensions using linear layers to match the requirements of the subsequent attention module. It is a modified linear unit activation function. This represents a linear transformation layer, while introducing a learnable scaling factor. :

[0068]

[0069] This scaling factor allows the model to adaptively adjust the overall contribution of fused features, avoiding an imbalance in the proportion of fused features in the total features.

[0070] The detailed description of the adaptive embedding module construction described in S3 of the above method is as follows:

[0071] Electricity load sequences simultaneously contain short-term local fluctuations (such as hourly load spikes) and long-term global trends (such as intraday, weekly, and monthly periodicity). A single model structure struggles to capture multi-scale temporal features simultaneously: convolutional neural networks excel at extracting local patterns but have limited receptive fields, while recurrent neural networks can model long-term dependencies but suffer from gradient problems and low computational efficiency. To combine the advantages of both, we designed an adaptive embedding module integrating Conv1d and LSTM. The overall structure mainly consists of a one-dimensional convolutional feature extraction layer (Conv1d), a temporal modeling layer (LSTM), and an adaptive mapping layer. The signal flow first enters the convolutional layer from historical load embedding features to extract local temporal patterns. Then, the convolutional output sequence is fed into the LSTM network to capture long-distance temporal dependencies. Finally, a stable adaptive temporal embedding representation is generated through normalization and learnable scaling mechanisms, thereby achieving collaborative modeling of multi-scale temporal information.

[0072] S31: Local Feature Extraction

[0073] S311: Embedding features of historical loads Perform dimensional reshaping to adapt to the Conv1d input format:

[0074]

[0075] The Permute operation adjusts the dimensional order as {number of nodes, embedding dimension, time step}, which allows Conv1d to slide the convolution kernel along the time dimension to capture local temporal patterns.

[0076] S312: Design of a double-layer Conv1d structure:

[0077]

[0078]

[0079] in To determine the number of output channels for the convolution, use and By ensuring that the output time step length remains constant, stacking two convolutional layers can expand the receptive field and capture more complex local combination patterns (such as short-period sequences of "rise-stable-fall"). It is a modified linear unit activation function;

[0080] S32: Long-term time dependency capture

[0081] S321: Reshape the convolutional output into an LSTM input format to capture long-range temporal dependencies using LSTM.

[0082]

[0083] Permute indicates changing the order of tensor dimensions;

[0084] S322: Take the hidden state of the last time step of the LSTM as the long-term dependency feature representation:

[0085]

[0086]

[0087] in The expression XXX, where _ indicates that the output is not used, is more effective than average pooling of all time step outputs. The last hidden state can better focus on key information of long-term trends (such as the time pattern of intraday load peaks) and reduce redundancy.

[0088] S33: Feature Normalization and Adaptation

[0089] S331: Perform LayerNorm normalization on the LSTM output:

[0090]

[0091] S332: Adjust feature contributions using a learnable scaling factor and broadcast to all time steps, aligning with other feature dimensions.

[0092]

[0093] in For learnable scaling parameters, This indicates a dimension insertion operation. This indicates tensor broadcast extension. This represents the sigmoid activation function. Indicates the number of nodes. Indicates the number of historical time steps. This represents the dimension of the adaptive embedding feature. The node-level long-term feature is expanded to a shape consistent with the time step, allowing it to be concatenated with historical load embeddings, gated fusion features, etc.; the scaling factor is used to balance the overall contribution of the adaptive feature.

[0094] The detailed description of the dual attention architecture construction described in S4 of the above method is as follows:

[0095] Electricity load forecasting requires simultaneously modeling two core dependencies: spatial correlations between nodes (e.g., the mutual influence of loads in adjacent areas) and temporal dependencies of weather-holiday features (e.g., the cumulative effect of continuous high temperatures). Traditional Transformers handle spatiotemporal dimensions in a mixed manner, making it difficult to specifically capture the characteristics of different types of dependencies. Therefore, we designed a dual-attention architecture, modeling the two types of dependencies through a spatial attention layer and a weather-holiday attention layer, respectively, and introducing lightweight temporal encoding to enhance time step discriminability. The spatial attention layer models the spatial associations between different nodes, enabling the model to capture the spatial linkages of electricity load; the weather-holiday attention layer characterizes the dynamic interactions between external factors, avoiding insufficient information representation caused by simple feature splicing; and the introduction of lightweight temporal encoding provides clear temporal location information for different time steps, thereby enhancing the model's ability to recognize temporal periodicity and temporal structure.

[0096] S41: Lightweight Time Coding

[0097] S411: Employs learnable embedding vectors to encode only the relative time position within the input window, from 0 to T-1, where T is the number of historical time steps.

[0098]

[0099]

[0100] in For the time encoding dimension, Embedding represents the learnable embedding layer. It represents the shape of the output tensor. Compared with the fixed-position encoding of Transformer, the learnable encoding can adaptively adjust according to the data and only encodes the relative position. The parameters are lightweight and avoid overfitting.

[0101] S412: Broadcasts time-encoded data to all nodes and batches, and controls contribution through a learnable scaling factor.

[0102]

[0103]

[0104] in, This indicates a dimension insertion operation. This indicates tensor broadcast extension. For batch size, The scaling parameter for time encoding allows the model to adaptively adjust the influence intensity of time encoding, avoiding excessive interference with core features.

[0105] S42: Feature Concatenation and Preprocessing

[0106] Multi-source features are concatenated and preprocessed:

[0107]

[0108]

[0109] in For model dimensions, And must meet mod num-heads = 0 ensures reasonable multi-head attention splitting. This indicates a splicing operation. This indicates that the weights are discarded. Layer normalization is used, dropout is used to drop out probabilities, and LayerNorm and Dropout are used to stabilize training and prevent overfitting;

[0110] S43: Constructing a Spatial Attention Layer

[0111] Perform self-attention computation at node dimension dim=2 to model the spatial correlation between nodes:

[0112]

[0113] The specific calculation process includes:

[0114] S431: Linear Projection and Multi-Head Splitting: Global Features The fully connected MLP layer projects the query Q, key K, and value V, and splits them into num_heads attention heads.

[0115] S432: Attention Score Calculation: ,in For the head dimension, square root scaling is used to prevent the fraction from becoming too large;

[0116] S433: Softmax Normalization: ;

[0117] S434: Context vector calculation: ;

[0118] S435: Multi-head stitching and output projection: The outputs of multiple attention heads are stitched together and spatial attention output is obtained through a linear projection layer;

[0119] The spatial attention layer adopts a pre-normalized Pre-LN structure and introduces a feedforward network (FFN) and residual connections:

[0120]

[0121]

[0122]

[0123] in For the hidden layer dimension of the feedforward network, For layer normalization, This indicates that the weights are discarded. It is a modified linear unit activation function. This represents a linear transformation layer, and the spatial attention layer is stacked with num_layers layers. By stacking multiple layers, the accuracy of spatial dependency modeling is gradually improved.

[0124] S44: Construct a Weather-Holiday Attention Layer

[0125] S441: Weather-Holiday Fusion Features in the Time Dimension Perform self-attention calculation:

[0126]

[0127] The number of stacking layers is This layer focuses on modeling the temporal dependence of weather-holiday features, such as the accumulation of multiple consecutive days of high temperatures or holiday effects, and is decoupled from the spatial attention layer to reduce computational complexity.

[0128] S442: The attention-enhanced weather-holiday features are re-concatenated with the spatial attention output features to obtain the final spatiotemporal-environment fusion features:

[0129]

[0130] in This indicates a splicing operation, which preserves the spatial modeling results while incorporating weather and holiday information enhanced by the time dimension, providing rich fusion representations for subsequent forecasts.

[0131] The detailed description of the output projection layer construction in S5 of the above method is as follows:

[0132] After dual-attention encoding, the model obtains a representation that integrates spatiotemporal and external features. It needs to be mapped to the future. The load forecast values ​​are calculated for each time step. Two output projection modes were designed to suit the characteristics of short-term and long-term forecasts, respectively, for forecasting tasks of different lengths.

[0133] S51: Hybrid projection mode, i.e., when use_mixed_proj=True, the time step dimension and feature dimension are mixed and then directly projected onto the target dimension through a linear layer:

[0134]

[0135]

[0136]

[0137] in To predict the number of time steps, For output dimensions, Represents a linear transformation layer. Indicates the shape of the structure;

[0138] This model is suitable for short sequence prediction (such as the next few hours) because the feature dimension and time step dimension can fully interact, and parameter sharing is efficient.

[0139] S52: Separate projection mode, i.e., when use_mixed_proj=False, first perform time dimension projection, then perform feature dimension projection:

[0140]

[0141]

[0142]

[0143]

[0144] Permute indicates changing the order of tensor dimensions. Indicates a linear transformation layer;

[0145] This model first independently maps historical time steps to future time steps, and then obtains the final output through feature projection. It can better maintain the integrity of the time structure, is suitable for long sequence prediction (such as the next few days), and avoids the confusion of time information caused by dimensional mixing.

[0146] The loss function described in S6 of the above method is the HuberLoss loss function:

[0147]

[0148] in It is a predicted value. It is the actual value.

[0149] The complete prediction process for S7 in the above method is as follows:

[0150] S71: Input data preprocessing: Organize the raw input data {load, temperature, holidays} into (B,T,N,D) format (D=3);

[0151] S72: Multi-source feature embedding: Maps various features to a unified embedding space through linear projection or MLP, and introduces a learnable scaling factor to control the feature contribution.

[0152] S73: Gated Fusion: Dynamically fuses weather and holiday features through a gated fusion module to capture the non-linear interaction between the two;

[0153] S74: Adaptive Embedding: Extracting Multi-Scale Temporal Patterns of Load Sequences via Conv1d+LSTM;

[0154] S75: Lightweight time coding: Adds learnable relative position coding to each time step;

[0155] S76: Feature concatenation and preprocessing: Concatenate all features and optimize using LayerNorm and Dropout;

[0156] S77: Dual attention modeling: Modeling the correlation between nodes through a spatial attention layer, and modeling the time dimension dependency through a weather-holiday attention layer;

[0157] S78: Output Projection: Maps encoded features to the future through hybrid projection or split projection modes. Load forecast values ​​for each time step.

[0158] Compared with the prior art, the present invention has the following advantages:

[0159] 1. Achieved deep nonlinear fusion of multi-source heterogeneous features: Through the designed gated fusion module, the difference, product operation and adaptive gating mechanism are introduced to explicitly model the complex context-dependent nonlinear interaction between weather and holiday features (such as the change of temperature sensitivity during holidays), which overcomes the information loss and insufficient modeling caused by simple feature splicing or weighted summation in traditional methods.

[0160] 2. Decoupling and accurate modeling of spatiotemporal dependencies: Through a dual-attention architecture, the spatial correlation between nodes and the temporal dependency of weather-holiday features are separated and modeled in a targeted manner. The spatial attention layer focuses on capturing the load interactions between geographically or electrically related nodes, while the weather-holiday attention layer focuses on the evolution of external features over time and their cumulative effect on the load, thus more comprehensively and accurately depicting the complex spatiotemporal patterns of the load.

[0161] 3. Adaptive collaborative extraction of multi-scale time patterns is achieved: By combining the adaptive embedding module of Conv1d and LSTM, local short-term fluctuations (such as hourly abrupt changes) and long-term global trends (such as daily and weekly cycles) can be automatically and effectively extracted from the load sequence without manual design, providing richer and more discriminative time feature representations.

[0162] 4. Achieved dynamic adaptive balance of feature contribution: By introducing learnable scaling factors for weather embedding, holiday embedding, fused features, adaptive embedding, and time encoding, the model can dynamically adjust the contribution intensity of each feature source according to the data distribution and task requirements during training. This avoids the model's over-reliance on certain features (such as strongly correlated temperature) or neglect of other features (such as sparse holidays), significantly enhancing the model's robustness and generalization ability.

[0163] 5. Significantly improves the overall performance of short-term load forecasting: Experiments on the public benchmark dataset (GEFCOM2012) show that the method of this invention significantly outperforms mainstream baseline models such as RNN, LSTM, TCN, Transformer and Informer in core indicators such as root mean square error (RMSE), mean absolute error (MAE) and mean absolute percentage error (MAPE). It provides a more accurate and reliable short-term load forecasting tool for power systems with a high proportion of renewable energy, which is of great value for ensuring the safe, economical and green operation of the power grid. Attached Figure Description

[0164] Figure 1 This diagram illustrates the key challenges in electricity load forecasting.

[0165] Figure 2 This is a diagram of the overall architecture of the WHGF-Net model proposed in this invention.

[0166] Figure 3 This is a detailed structural diagram of the gating fusion module in this invention.

[0167] Figure 4 This is a structural diagram of the adaptive embedding module in this invention.

[0168] Figure 5This is a schematic diagram of a lightweight time-coding module.

[0169] Figure 6 A graph showing the MAE performance of different prediction models in a single step on the test set.

[0170] Figure 7 A graph showing the RMSE performance of different prediction models in a single step on the test set.

[0171] Figure 8 A graph showing the MAPE performance comparison of different prediction models in a single step on the test set.

[0172] Figure 9 This is a graph showing the decrease in the loss function of the WHGF-Net model during training. Detailed Implementation

[0173] The embodiments of the present invention will be described in detail below. Although the present invention will be described and illustrated in conjunction with some specific embodiments, it should be noted that the present invention is not limited to these embodiments. On the contrary, any modifications or equivalent substitutions made to the present invention should be covered within the scope of the claims of the present invention.

[0174] Furthermore, to better illustrate the present invention, numerous specific details are set forth in the following detailed embodiments. Those skilled in the art will understand that the present invention can be practiced without these specific details.

[0175] This invention proposes a load forecasting method for new energy power systems based on weather-holiday information gating fusion, comprising:

[0176] S1: Construct a multi-source feature embedding module to map historical load data, weather data, and holiday information to a unified embedding space, and introduce a learnable scaling factor for weather and holiday embeddings to adaptively control their initial influence intensity.

[0177] S2: Construct a gating fusion module to dynamically fuse weather and holiday embedded features through difference, product operations and adaptive gating mechanisms in order to capture the complex nonlinear interaction between them;

[0178] S3: Construct an adaptive embedding module that combines a one-dimensional convolutional neural network with a long short-term memory network to collaboratively extract local short-term fluctuations and long-term global trends of the load sequence;

[0179] S4: Construct a dual attention architecture to model the spatial correlation between nodes and the temporal dependence of the weather-holiday fusion feature;

[0180] S5: Construct an output projection layer to map the encoded features to the load forecast values ​​for future periods;

[0181] S6: Train the constructed model using historical datasets, and optimize the model parameters by minimizing the loss function (such as mean squared error) between the predicted load and the actual load until the model converges;

[0182] S7: Apply the trained model, input real-time or recent multi-source feature data, and output the load forecast results of each node within a certain future period to support power grid dispatching decisions.

[0183] The detailed description of the construction of the multi-source feature embedding module described in S1 of the above method is as follows:

[0184] S11: Historical load data Perform a linear projection to map it to a high-dimensional embedding space:

[0185]

[0186] in It is a learnable weight matrix. It is a bias vector. It is the embedded dimension. Indicates the current time step. Indicates the number of historical time steps. Indicates the number of nodes (number of sensors). This represents the feature dimension of each node;

[0187] S12: Weather data (such as temperature) Mapping to the embedding space via a multilayer perceptron:

[0188]

[0189] in, and It is a weight matrix. and It is a bias vector. It is the hidden layer dimension. It modifies the linear unit activation function and introduces a learnable scaling factor:

[0190]

[0191] in, It is a learnable scaling parameter. It is the sigmoid function;

[0192] S13: Holiday Data It is a binary vector representing whether each time step is a holiday or not, which is mapped to the embedding space using a linear projection layer:

[0193]

[0194] in It is a weight matrix. It is a bias vector, and a learnable scaling factor is introduced to control the influence of holiday features:

[0195]

[0196] in It is a learnable scaling parameter.

[0197] The detailed description of the gated fusion module construction described in S2 of the above method is as follows:

[0198] S21: Fusion Input Construction

[0199] Weather embedding features are Holiday embedding features are ,in To embed the dimension, interactive features are generated through the following operations:

[0200] S211: Preservation of original features: Direct inclusion and Preserve basic semantic information;

[0201] S212: Difference Characteristics: Calculation To depict the relative differences between the two;

[0202] S213: Product characteristics: Calculation To capture the synergistic enhancement effect of the two;

[0203] The four types of features mentioned above are concatenated along the last dimension to construct a gated input. ,Right now:

[0204]

[0205] Indicates a splicing operation;

[0206] S22: Adaptive Gated Generation

[0207] S221: The gated MLP structure is designed as follows:

[0208]

[0209] MLP stands for Multilayer Perceptron. For the hidden layer dimension of MLP, This is the gated output dimension, and its value is determined by the fusion granularity. It is a modified linear unit activation function. Indicates a linear transformation layer;

[0210] Element-level gating: when At the same time, the gating weights are consistent with the embedded feature dimensions, and the weights can be adjusted independently for each feature dimension to adapt to fine-grained feature interactions;

[0211] Scalar gating: when When =1, the gating weight is a scalar, and all feature dimensions share the same weight, which reduces computational complexity and enhances stability;

[0212] S222: Introduces a confidence-based temperature regulation mechanism, which learns the temperature coefficient through an independent MLP and dynamically adjusts the gating sharpness.

[0213]

[0214]

[0215] Where τ is the temperature scaling factor. This represents the activation function. Indicates an independent multilayer perceptron. Indicates the dynamic temperature coefficient;

[0216] S23: Feature Fusion and Optimization

[0217] S231: Execution Gated Fusion:

[0218]

[0219] in Represents element-wise multiplication;

[0220] S232: Preserve original feature information through residual connections:

[0221]

[0222] in For residual weights;

[0223] S233: Further optimize the representational capability of fused features through LayerNorm and refined MLP:

[0224]

[0225]

[0226] in To fuse feature output dimensions, For layer normalization, It is a modified linear unit activation function. This represents a linear transformation layer, while introducing a learnable scaling factor. :

[0227] .

[0228] The detailed description of the adaptive embedding module construction described in S3 of the above method is as follows:

[0229] S31: Local Feature Extraction

[0230] S311: Embedding features of historical loads Perform dimensional reshaping to adapt to the Conv1d input format:

[0231]

[0232] The Permute operation adjusts the dimensions in the order of {number of nodes, embedding dimension, time step}.

[0233] S312: Design of a double-layer Conv1d structure:

[0234]

[0235]

[0236] in The number of output channels for the convolution. It is a modified linear unit activation function;

[0237] S32: Long-term time dependency capture

[0238] S321: Reshape the convolutional output into an LSTM input format to capture long-range temporal dependencies using LSTM.

[0239]

[0240] S322: Take the hidden state of the last time step of the LSTM as the long-term dependency feature representation:

[0241]

[0242]

[0243] Where, _ indicates that the output is not used;

[0244] S33: Feature Normalization and Adaptation

[0245] S331: Perform LayerNorm normalization on the LSTM output:

[0246]

[0247] S332: Adjust feature contributions using a learnable scaling factor and broadcast to all time steps, aligning with other feature dimensions.

[0248]

[0249] in For learnable scaling parameters, This indicates a dimension insertion operation. This indicates tensor broadcast extension. This represents the sigmoid activation function. Indicates the number of nodes. Indicates the number of historical time steps. This indicates the dimension of the adaptive embedding feature.

[0250] The detailed description of the dual attention architecture construction described in S4 of the above method is as follows:

[0251] S41: Lightweight Time Coding

[0252] S411: Employs learnable embedding vectors to encode only the relative time position within the input window, from 0 to T-1, where T is the number of historical time steps.

[0253]

[0254]

[0255] in For the time encoding dimension, Embedding represents the learnable embedding layer. Indicates the shape of the output tensor;

[0256] S412: Broadcasts time-encoded data to all nodes and batches, and controls contribution through a learnable scaling factor.

[0257]

[0258]

[0259] in, This indicates a dimension insertion operation. Tensor broadcast extension For batch size, For time encoding scaling parameters;

[0260] S42: Feature Concatenation and Preprocessing

[0261] Multi-source features are concatenated and preprocessed:

[0262]

[0263]

[0264] in For model dimensions, And must meet mod num-heads = 0, This indicates a splicing operation. This indicates that the weights are discarded. For layer normalization, dropout is the probability of dropping items;

[0265] S43: Constructing a Spatial Attention Layer

[0266] Perform self-attention computation at node dimension dim=2 to model the spatial correlation between nodes:

[0267]

[0268] The specific calculation process includes:

[0269] S431: Linear Projection and Multi-Head Splitting: Global Features The fully connected MLP layer is projected to query Q, key K, and value V, and then split into num_heads attention heads;

[0270] S432: Attention Score Calculation: ,in For the head dimension, square root scaling is used to prevent the fraction from becoming too large;

[0271] S433: Softmax Normalization: ;

[0272] S434: Context vector calculation: ;

[0273] S435: Multi-head stitching and output projection: The outputs of multiple attention heads are stitched together and spatial attention output is obtained through a linear projection layer;

[0274] The spatial attention layer adopts a pre-normalized Pre-LN structure and introduces a feedforward network (FFN) and residual connections:

[0275]

[0276]

[0277]

[0278] in For the hidden layer dimension of the feedforward network, For layer normalization, This indicates that the weights are discarded. It is a modified linear unit activation function. This represents a linear transformation layer, and spatial attention layers stacked on top of num_layers layers;

[0279] S44: Construct a Weather-Holiday Attention Layer

[0280] S441: Weather-Holiday Fusion Features in the Time Dimension Perform self-attention calculation:

[0281]

[0282] The number of stacking layers is ;

[0283] S442: The attention-enhanced weather-holiday features are re-concatenated with the spatial attention output features to obtain the final spatiotemporal-environment fusion features:

[0284]

[0285] in This indicates a splicing operation.

[0286] The detailed description of the output projection layer construction in S5 of the above method is as follows:

[0287] Mapping encoded features to load forecasts for future time periods includes two modes:

[0288] S51: Hybrid projection mode, i.e., when use_mixed_proj=True, the time step dimension and feature dimension are mixed and then directly projected onto the target dimension through a linear layer:

[0289]

[0290]

[0291]

[0292] in To predict the number of time steps, For output dimensions, Represents a linear transformation layer. Indicates the shape of the structure;

[0293] S52: Separate projection mode, i.e., when use_mixed_proj=False, first perform time dimension projection, then perform feature dimension projection:

[0294]

[0295]

[0296]

[0297]

[0298] Permute indicates changing the order of tensor dimensions. This represents a linear transformation layer.

[0299] The loss function described in S6 of the above method is the HuberLoss loss function:

[0300]

[0301] in It is a predicted value. It is the actual value.

[0302] The complete prediction process for S7 in the above method is as follows:

[0303] S71: Input data preprocessing: Organize the raw input data {load, temperature, holidays} into (B,T,N,D) format (D=3);

[0304] S72: Multi-source feature embedding: Maps various features to a unified embedding space through linear projection or MLP, and introduces a learnable scaling factor to control the feature contribution.

[0305] S73: Gated Fusion: Dynamically fuses weather and holiday features through a gated fusion module to capture the non-linear interaction between the two;

[0306] S74: Adaptive Embedding: Extracting Multi-Scale Temporal Patterns of Load Sequences via Conv1d+LSTM;

[0307] S75: Lightweight time coding: Adds learnable relative position coding to each time step;

[0308] S76: Feature concatenation and preprocessing: Concatenate all features and optimize using LayerNorm and Dropout;

[0309] S77: Dual attention modeling: Modeling the correlation between nodes through a spatial attention layer, and modeling the time dimension dependency through a weather-holiday attention layer;

[0310] S78: Output Projection: Maps encoded features to the future through hybrid projection or split projection modes. Load forecast values ​​for each time step.

[0311] Example

[0312] 1. Experimental Data and Environmental Description

[0313] The simulation environment used in this embodiment is based on the publicly available benchmark dataset from the Global Energy Forecasting Competition (GEFCOM2012). Zone 1 of this dataset is selected as the representative of the microgrid or load area, with a data time granularity of 1 hour. To construct a short-term forecasting task, historical data from this area for eight consecutive months are selected as experimental samples. The input data contains three-dimensional features that perfectly match the model design: historical load values ​​(unit: MW), average temperature for the corresponding period (unit: °C), and binary holiday identifiers (0 for weekdays, 1 for holidays / weekends). The raw data is first preprocessed: linear interpolation is used to fill in missing values; Min-Max normalization is applied to the load and temperature data, scaling them to the [0,1] interval to accelerate model training and improve stability; holiday data retains its original binary form. After preprocessing, the data is divided into training, validation, and test sets in a 7:2:1 ratio according to time order, for model parameter learning, hyperparameter tuning, and final performance evaluation, respectively.

[0314] 2. Model and Algorithm Parameter Description

[0315] In this embodiment, all comparison models and the WHGF-Net proposed in this invention are implemented based on the PyTorch deep learning framework. The core structural parameters of WHGF-Net are set as follows: unified embedding dimension. The MLP hidden layer dimension of the gated fusion module is 128; in the adaptive embedding module, the Conv1d output channel and LSTM hidden layer dimensions are both set to 32; in the dual attention architecture, the spatial attention layer is stacked 3 times, the weather-holiday attention layer is stacked 1 time, the number of attention heads is set to 8, and the hidden layer dimension of the feedforward network is 256; the dropout rate during training is set to 0.1 to prevent overfitting. All models are trained using the same configuration: the Adam optimizer is used with an initial learning rate of 0.001, along with a cosine annealing scheduler; the maximum number of training epochs is set to 100, and an early stopping mechanism is introduced, terminating training when the validation set loss does not decrease for 10 consecutive epochs; the batch size is set to 32. The loss function is mean squared error (MSE).

[0316] 3. Test Instructions

[0317] This invention discloses a load forecasting method for new energy power systems based on weather-holiday information gating fusion. This verification test aims to systematically evaluate whether the method of this invention (WHGF-Net) can learn effective load change patterns and compare its prediction accuracy with traditional methods and other advanced deep learning models.

[0318] I. Functional Testing and Result Analysis

[0319] Functional testing is primarily used to verify the stability and convergence of the model training process. WHGF-Net is trained according to the algorithm steps and parameter settings described above. Figure 9 As shown, the training loss and validation loss curves of the model decrease rapidly in the first 30 rounds, and then gradually flatten out, remaining close to each other without significant separation. This indicates that the model can effectively learn from the training data without overfitting, demonstrating the stability of the collaborative work of the gating fusion, dual attention, and other modules proposed in this invention, and ensuring that the model has reliable fitting and generalization capabilities.

[0320] II. Performance Testing and Result Analysis

[0321] Performance testing aimed to quantitatively compare the prediction accuracy of WHGF-Net with several representative baseline models. The selected baseline models included RNN, LSTM, TCN, Transformer, and Informer. Evaluation metrics included root mean square error (RMSE), mean absolute error (MAE), and mean absolute percentage error (MAPE). The results are shown in Table 1.

[0322] As shown in Table 1, on the same test set, the proposed WHGF-Net model achieved the best performance across all three metrics, with RMSE, MAE, and MAPE of 1850, 1275, and 7.56%, respectively, significantly outperforming all other comparative models. This collectively demonstrates that WHGF-Net can predict future load values ​​more accurately with less prediction bias. In particular, compared to the powerful Transformer variant Informer, WHGF-Net reduced RMSE by approximately 9.8%, proving the effectiveness of its architectural innovation.

[0323] The performance advantages mainly stem from the following design: 1) The gating fusion mechanism effectively captures the nonlinear interaction between temperature and holidays (such as the change in temperature sensitivity to load during holidays), avoiding the information loss of simple feature splicing; 2) The dual attention architecture decouples the modeling of "spatial correlation between nodes" and "temporal dependence of weather-holiday features", enabling the model to learn different types of dependencies more specifically; 3) The adaptive embedding module, through the combination of Conv1d and LSTM, simultaneously captures the local fluctuations and long-term trends of the load sequence, providing richer time-scale information.

[0324] Table 1. Comparison of prediction performance of different models on the test set

[0325] Model RMSE MAE MAPE (%) RNN 2850 1950 11.20% LSTM 2450 1680 9.80% TCN 2200 1520 8.90% Transformer 2100 1450 8.50% Informer 2050 1400 8.10% WHGF-Net 1850 1275 7.56%

[0326] Furthermore, from the single-step prediction performance curve (Figure 6 , 7 (8) As can be seen, WHGF-Net maintains leading and stable performance across different prediction step sizes, further verifying its robustness in multi-step prediction tasks.

[0327] III. Test Summary

[0328] This embodiment verifies the rationality and superiority of the load forecasting method (WHGF-Net) based on weather-holiday information gating fusion proposed in this invention through complete functional testing and detailed performance comparison testing. Experimental results show that WHGF-Net not only has a stable training process, but also comprehensively surpasses traditional recurrent neural networks, temporal convolutional networks, and current mainstream Transformer-based prediction models in terms of prediction accuracy. This fully demonstrates that this invention effectively solves the core challenges of difficult multi-source heterogeneous feature fusion and complex spatiotemporal dependency modeling in load forecasting of new energy power systems through innovative gating fusion, dual-attention modeling, and multi-scale feature extraction. The obtained prediction model can provide more accurate and reliable decision support for real-time scheduling, economic operation, and high-proportion renewable energy consumption of power systems, and has clear engineering application value.

Claims

1. A load forecasting method for new energy power systems based on weather-holiday information gating fusion, characterized in that, Includes the following steps: S1: Construct a multi-source feature embedding module to map historical load data, weather data, and holiday information to a unified embedding space, and introduce a learnable scaling factor for weather and holiday embeddings to adaptively control their initial influence intensity. S2: Construct a gating fusion module to dynamically fuse weather and holiday embedded features through difference, product operations and adaptive gating mechanisms in order to capture the complex nonlinear interaction between them; S3: Construct an adaptive embedding module that combines a one-dimensional convolutional neural network with a long short-term memory network to collaboratively extract local short-term fluctuations and long-term global trends of the load sequence; S4: Construct a dual attention architecture to model the spatial correlation between nodes and the temporal dependence of the weather-holiday fusion feature; S5: Construct an output projection layer to map the encoded features to the load forecast values ​​for future periods; S6: Train the constructed model using historical datasets, and optimize the model parameters by minimizing the loss function (such as mean squared error) between the predicted load and the actual load until the model converges; S7: Apply the trained model, input real-time or recent multi-source feature data, and output the load forecast results of each node within a certain future period to support power grid dispatching decisions.

2. The method according to claim 1, characterized in that, The detailed description of the construction of the multi-source feature embedding module described in S1 is as follows: S11: Historical load data Perform a linear projection to map it to a high-dimensional embedding space: in It is a learnable weight matrix. It is a bias vector. It is the embedded dimension. Indicates the current time step. Indicates the number of historical time steps. Indicates the number of nodes (number of sensors). Represents the feature dimension of each node; S12: Weather data (such as temperature) Mapping to the embedding space via a multilayer perceptron: in, and It is a weight matrix. and It is a bias vector. It is the hidden layer dimension. It modifies the linear unit activation function and introduces a learnable scaling factor: in, It is a learnable scaling parameter. It is the sigmoid function; S13: Holiday Data It is a binary vector representing whether each time step is a holiday or not, which is mapped to the embedding space using a linear projection layer: in It is a weight matrix. It is a bias vector, and a learnable scaling factor is introduced to control the influence of holiday features: in It is a learnable scaling parameter.

3. The method according to claim 1, characterized in that, The detailed description of the gated fusion module construction described in S2 is as follows: S21: Fusion Input Construction Weather embedding features are Holiday embedding features are Where De is the embedding dimension, interactive features are generated through the following operations: S211: Preservation of original features: Direct inclusion and Preserve basic semantic information; S212: Difference Characteristics: Calculation To depict the relative differences between the two; S213: Product characteristics: calculate To capture the synergistic enhancement effect of the two; The four types of features mentioned above are concatenated along the last dimension to construct a gated input. ,Right now: Indicates a splicing operation; S22: Adaptive Gated Generation S221: The gated MLP structure is designed as follows: in, For the hidden layer dimension of MLP, This is the gated output dimension, and its value is determined by the fusion granularity. It is a modified linear unit activation function. Indicates a linear transformation layer; Element-level gating: when At the same time, the gating weights are consistent with the embedded feature dimensions, and the weights can be adjusted independently for each feature dimension to adapt to fine-grained feature interactions; Scalar gating: when When =1, the gating weight is a scalar, and all feature dimensions share the same weight, which reduces computational complexity and enhances stability; S222: Introduces a confidence-based temperature regulation mechanism, which learns the temperature coefficient through an independent MLP and dynamically adjusts the gating sharpness. Where τ is the temperature scaling factor. This represents the activation function. Indicates an independent multilayer perceptron. Indicates the dynamic temperature coefficient; S23: Feature Fusion and Optimization S231: Execution Gated Fusion: in Represents element-wise multiplication; S232: Preserve original feature information through residual connections: in For residual weights; S233: Further optimize the representational capability of fused features through LayerNorm and refined MLP: in To fuse feature output dimensions, For layer normalization, It is a modified linear unit activation function. This represents a linear transformation layer, while introducing a learnable scaling factor. : 。 4. The method according to claim 1, characterized in that, The adaptive embedding module construction described in S3 includes the following steps: S31: Local Feature Extraction S311: Embedding features of historical loads Perform dimensional reshaping to adapt to the Conv1d input format: The Permute operation adjusts the dimensions in the order of {number of nodes, embedding dimension, time step}. S312: Design of a double-layer Conv1d structure: in The number of output channels for the convolution. It is a modified linear unit activation function; S32: Long-term time dependency capture S321: Reshape the convolutional output into an LSTM input format to capture long-range temporal dependencies using LSTM. Permute indicates changing the order of tensor dimensions; S322: Take the hidden state of the last time step of the LSTM as the long-term dependency feature representation: Where, _ indicates that the output is not used; S33: Feature Normalization and Adaptation S331: Perform LayerNorm normalization on the LSTM output: S332: Adjust feature contributions using a learnable scaling factor and broadcast to all time steps, aligning with other feature dimensions. in For learnable scaling parameters, This indicates a dimension insertion operation. This indicates tensor broadcast extension. This represents the sigmoid activation function. Indicates the number of nodes. Indicates the number of historical time steps. This indicates the dimension of the adaptive embedding feature.

5. The method according to claim 1, characterized in that, The detailed description of the dual attention architecture described in S4 is as follows: S41: Lightweight Time Coding S411: Employs learnable embedding vectors to encode only the relative time position within the input window, from 0 to T-1, where T is the number of historical time steps. in For the time encoding dimension, Embedding represents the learnable embedding layer. Indicates the shape of the output tensor; S412: Broadcasts time-encoded data to all nodes and batches, and controls contribution through a learnable scaling factor. in This indicates a dimension insertion operation. This indicates tensor broadcast extension. For batch size, For time encoding scaling parameters; S42: Feature Concatenation and Preprocessing Multi-source features are concatenated and preprocessed: in For model dimensions, And must meet mod num-heads = 0, This indicates a splicing operation. This indicates that the weights are discarded. For layer normalization, dropout is the probability of dropping items; S43: Constructing a Spatial Attention Layer Perform self-attention computation at node dimension dim=2 to model the spatial correlation between nodes: The specific calculation process includes: S431: Linear Projection and Multi-Head Splitting: Global Features Project FC_Q, FC_K, and FC_V onto query Q, key K, and value V, and split them into num_heads attention heads; S432: Attention Score Calculation: ,in For the head dimension, square root scaling is used to prevent the fraction from becoming too large; S433: Softmax Normalization: ; S434: Context vector calculation: ; S435: Multi-head stitching and output projection: The outputs of multiple attention heads are stitched together and spatial attention output is obtained through a linear projection layer; The spatial attention layer adopts a pre-normalized Pre-LN structure and introduces a feedforward network (FFN) and residual connections: in For the hidden layer dimension of the feedforward network, For layer normalization, This indicates that the weights are discarded. It is a modified linear unit activation function. This represents a linear transformation layer, and spatial attention layers stacked on top of num_layers layers; S44: Construct a Weather-Holiday Attention Layer S441: Weather-Holiday Fusion Features in the Time Dimension Perform self-attention calculation: The number of stacking layers is ; S442: The attention-enhanced weather-holiday features are re-concatenated with the spatial attention output features to obtain the final spatiotemporal-environment fusion features: in This indicates a splicing operation.

6. The method according to claim 5, characterized in that, The detailed description of the output projection layer construction described in S5 is as follows: Mapping encoded features to load forecasts for future time periods includes two modes: S51: Hybrid projection mode, i.e., when use_mixed_proj=True, the time step dimension and feature dimension are mixed and then directly projected onto the target dimension through a linear layer: in To predict the number of time steps, For output dimensions, Represents a linear transformation layer. Indicates the shape of the structure; S52: Separate projection mode, i.e., when use_mixed_proj=False, first perform time dimension projection, then perform feature dimension projection: Permute indicates changing the order of tensor dimensions. This represents a linear transformation layer.

7. The method according to claim 1, characterized in that, The loss function described in S6 is the HuberLoss loss function: in It is a predicted value. It is the actual value.

8. The method according to claim 1, characterized in that, The complete prediction process for S7 is as follows: S71: Input data preprocessing: Organize the raw input data {load, temperature, holidays} into (B,T,N,D) format, D=3; S72: Multi-source feature embedding: By using linear projection or MLP, various features are mapped to a unified embedding space, and a learnable scaling factor is introduced to control the feature contribution. S73: Gated Fusion: Dynamically fuses weather and holiday features through a gated fusion module to capture the non-linear interaction between the two; S74: Adaptive Embedding: Extracting Multi-Scale Temporal Patterns of Load Sequences via Conv1d+LSTM; S75: Lightweight time coding: Adds learnable relative position coding to each time step; S76: Feature concatenation and preprocessing: Concatenate all features and optimize using LayerNorm and Dropout; S77: Dual attention modeling: Modeling the correlation between nodes through a spatial attention layer, and modeling the time dimension dependency through a weather-holiday attention layer; S78: Output Projection: Maps encoded features to the future through hybrid projection or split projection modes. Load forecast values ​​for each time step.