Abstract
Accurate short-term load forecasting (STLF) is essential for the stability and economic efficiency of modern smart grids. This paper presents a novel hybrid deep learning model, TPA-LSTM, which integrates Long Short-Term Memory (LSTM) networks with a Time Pattern Attention (TPA) mechanism. By processing historical load data alongside external climatic and economic factors through a modular architecture, the proposed method achieves significant improvements in forecasting accuracy. Experimental results using real-world data from Panama demonstrate a Mean Absolute Percentage Error (MAPE) of 4.41%, significantly outperforming traditional recurrent neural network architectures.
Introduction
The transition toward smart grids necessitates precise electricity demand predictions to manage the integration of renewable energy and electric vehicles. Short-term load forecasting (STLF), covering periods from hours to weeks, is the cornerstone of grid operation. The economic implications are vast; for instance, a 1% reduction in forecasting error can save large utilities tens of millions of dollars annually. However, the inherent volatility of power consumption, influenced by weather shifts and economic fluctuations, poses a significant challenge for traditional models. Previous forecasting models often struggled to integrate diverse external factors with historical consumption trends without introducing excessive noise.
Methodology
The proposed TPA-LSTM model utilizes a three-module hybrid architecture to effectively process and fuse diverse data streams.
- Module 1: Historical Load Analysis. This module employs an LSTM network to capture long-term dependencies in historical consumption data. A Time Pattern Attention (TPA) mechanism is integrated to enhance feature extraction. Unlike standard attention mechanisms that focus on individual time points, TPA uses a 1D-Convolutional Neural Network (CNN) to identify recurring temporal "shapes" or patterns within the LSTM’s hidden states, prioritizing the most predictive features.
- Module 2: External Contextual Factors. Fully Connected Layers (FCLs) are used to analyze multi-regional external variables, including climate data (temperature, humidity, wind speed) and economic indicators (GDP, market stability).
- Module 3: Temporal Metadata. This module learns the influence of calendar-based information, such as seasonal variations and day types (e.g., holidays vs. workdays).
The outputs from these modules are integrated via a Fusion Layer to generate a 24-hour load profile. The model's deployment follows a structured workflow involving dataset preparation, model building, and iterative hyperparameter optimization to ensure robustness.
Data and Experimental Setup
The model was validated using a historical dataset from Panama spanning 2015 to 2020. The data, recorded at 1-hour intervals, included total load (MWh), meteorological variables (temperature, humidity, precipitation, wind speed), and temporal indicators for school days and holidays. The dataset was partitioned into training, validation, and test sets using an 8:1:1 ratio. Hyperparameters were optimized through a combination of random search and k-fold cross-validation.
Results and Discussion
The TPA-LSTM model was benchmarked against Multi-Layer Perceptron (MLP), standard LSTM, and Gated Recurrent Unit (GRU) models.
| Model | MAPE (%) | MAE (MW) | RMSE (MW) |
|---|---|---|---|
| MLP | 10.54 | 124.24 | 156.64 |
| LSTM | 8.56 | 96.41 | 148.85 |
| GRU | 8.10 | 91.30 | 144.18 |
| TPA-LSTM (Proposed) | 4.41 | 51.43 | 73.73 |
The proposed model achieved a MAPE of 4.41%, representing a nearly 50% improvement over the standard LSTM. Qualitative analysis confirmed that TPA-LSTM maintains high alignment with actual load curves, particularly during peak demand periods where baseline models often falter. The modular design effectively isolates historical trends from external noise, while the TPA mechanism provides resilience against outliers by focusing on temporal patterns rather than isolated data points.
Conclusion
The TPA-LSTM architecture offers a robust solution for short-term load forecasting by successfully integrating historical trends with complex external drivers. While the model demonstrates superior accuracy, future work will address challenges related to data heterogeneity across different smart meter sources and the handling of "Black Swan" events—such as extreme weather or grid faults—to further enhance system reliability.
Summary updated