A Load Forecasting Model for Smart Grid Based on RF-BiLSTM and Federated Learning

Wenhui Li, Huilin Jiang, Lei ZhangResearch Square 2024

Abstract

Accurate load forecasting is essential for improving the efficiency and reliability of smart grids. Traditional forecasting models face challenges in integrating high-dimensional data and protecting privacy. To address these issues, a novel load forecasting model is presented in this paper. The proposed approach combines a random forest (RF) and a bi-directional long short-term memory (BiLSTM) network based on a federated learning framework. To effectively process high-dimensional heterogeneous data in smart grids, the proposed model exploits the feature extraction capability of radio frequency. In addition, the sequential data processing capability of BiLSTM provides a means of processing time-varying load data in smart grids. The federated learning method protects user privacy and achieves the goal of global model training adopting distributed data. Experimental results demonstrate that the proposed model is superior to traditional models in accuracy and efficiency.

Introduction

Maintaining a stable power grid requires utility companies to accurately predict consumer electricity demand. While modern deep learning models excel at time-series forecasting, they typically require centralizing massive amounts of high-resolution smart meter data. This centralization poses significant privacy risks, as granular usage data can reveal intimate details of household routines. Furthermore, smart grid data is often highly heterogeneous (Non-IID), with consumption patterns varying wildly between households.

Federated Learning (FL) offers a solution by training models locally on edge devices. However, standard FL algorithms like Federated Averaging (FedAvg) often struggle to converge with the extreme data diversity found in residential energy usage.

Proposed Methodology

The researchers developed a hybrid architecture combining Random Forest (RF) for feature selection, Bi-directional Long Short-Term Memory (BiLSTM) for sequence modeling, and the FedProx algorithm for robust federated training.

Overall architecture of the proposed RF-BiLSTM model within the Federated Learning framework.

Feature Selection via Random Forest

Smart grid datasets are often high-dimensional and noisy. To streamline the model, an RF regression model is used to calculate feature importance. By identifying key variables—such as historical electrical load and temperature—the model filters out irrelevant data, preventing the neural network from overfitting to noise and reducing computational overhead.

Sequence Modeling with BiLSTM

For the core forecasting task, the model utilizes a BiLSTM network. Unlike standard LSTMs, BiLSTMs process time-series data in both forward and backward directions, allowing the model to capture a more comprehensive context of consumption trends.

Structure of a Bi-directional Long Short-Term Memory (BiLSTM) network showing forward and backward layers.

Privacy-Preserving Federated Learning

The model is trained locally on user devices to ensure data privacy. To address the challenges of Non-IID data, the authors implemented FedProx. This algorithm introduces a proximal regularization term during local training, which penalizes local updates that drift too far from the global model. This ensures stable and accurate aggregation at the central server despite diverse household energy habits.

Experimental Evaluation

The model was evaluated using a real-world dataset from London households spanning 28 months. Households were categorized into three groups based on daily consumption: Low (<9 kWh), Mid (9-18 kWh), and High (>18 kWh).

Key Results

The RF-BiLSTM + FedProx model was compared against centralized BiLSTM and standard federated BiLSTM (FedAvg) models.

  • Accuracy: The proposed model consistently achieved the lowest error metrics (MSE, RMSE, MAE) across all consumption tiers. For "Low" consumption households, it achieved an MSE of 0.16 and an MAE of 0.33.
  • Efficiency: Surprisingly, the FedProx approach was the fastest to train. In the "Low" consumption group, it completed training in 1350.8 seconds, significantly faster than the centralized (1664.3s) and FedAvg (1720.5s) counterparts.
  • Generalizability: High predictive performance was maintained across all energy consumption profiles, demonstrating the model's robustness.

Conclusion

This research demonstrates that privacy-preserving federated learning can match or even exceed the performance of centralized models in smart grid applications. By combining RF-based feature selection with BiLSTM and the FedProx algorithm, the proposed model effectively manages data heterogeneity while protecting consumer privacy. Future work will explore integrating other advanced ML techniques and expanding this framework to tasks like demand response optimization and fault detection.

Summary updated

BibTeX
@inproceedings{li2024load,
  author = {Wenhui Li and Huilin Jiang and Lei Zhang},
  title = {{A Load Forecasting Model for Smart Grid Based on RF-BiLSTM and Federated Learning}},
  booktitle = {Research Square},
  year = {2024},
  doi = {10.21203/rs.3.rs-4996650/v1},
}
Figure