Abstract
Existing LSTM-based power quality (PQ) prediction models primarily rely on historical information, which limits their ability to fully capture contextual dependencies. Furthermore, these models process inputs sequentially without accounting for the varying importance of different time steps, leading to significant prediction inaccuracies. To address these limitations, this study proposes an enhanced PQ prediction model that integrates Bidirectional Long Short-Term Memory (BiLSTM) with a Self-Attention (SA) mechanism. The BiLSTM module is introduced to model both forward and backward temporal dependencies, enabling a more comprehensive capture of long-term patterns in time series data. The SA mechanism dynamically adjusts the importance of different time steps through weighted summation, enhancing the model’s ability to focus on critical features and improving its capacity to model nonlinear relationships. The weighted features from the SA layer are then mapped to a fully connected layer to generate the final prediction outputs. Experiments were conducted using power quality data from Nanchang as the primary dataset, with additional datasets from Nanjing, Wuhan, Changsha, and Beijing used for generalization testing. The results demonstrate that the BiLSTM-SA model outperforms traditional LSTM models across all PQ metrics, achieving a mean absolute error (MAE) of 0.09 for voltage deviation, a 0.05 improvement over single-layer LSTM. Notably, the model maintains robust performance in complex power supply scenarios, with a generalized MAE of only 0.2 in Beijing. These findings highlight the effectiveness of combining BiLSTM with the SA mechanism in reducing prediction errors and ensuring the stability of power supply quality, offering a significant advancement in PQ prediction methodologies.
Keywords
Get full access to this article
View all access options for this article.
