Research on ultra-short-term load forecasting method based on PCA-MIC-LSTM

This research presents a PCA-MIC-LSTM-based ultra-short-term electric load forecasting approach. This method uses Principal Component Analysis (PCA) technology to denoise power load data, uses the Maximal Information Coefficient (MIC) method to perform feature screening and correlation analysis on the processed data and finally selects some features with high correlation to input Long-Short-Term Memory Neural Network (LSTM) for training and modeling. Through actual case analysis, this method reduces the prediction error MAPE by 0.29% compared to the basic LSTM model. Compared with LightGBM, Xgboost, and SVR models, the prediction error MAPE is reduced by 0.16%, 0.11%, and 0.32%, respectively. It demonstrates the validity of the approach established in this investigation and provides technical support and a theoretical basis for scientific decision-making to optimize the precision of ultra-short-term electric load prediction in power systems.


Introduction
With the fast expansion of the electrical market and the promotion of smart grids, the requirements for the precision and timeliness of ultra-short-term electric load prediction are increasing.Currently, there are many difficulties in ultra-short-term load prediction, and effective measures need to be taken to address them, such as a large amount of data, high noise, complex influencing factors, and poor model adaptability.
There are two main methods for ultra-short-term load prediction which are prediction approaches according to traditional data statistics [1] and artificial intelligence prediction methods [2][3].Among them, the traditional forecasting method has advantages in terms of model complexity and feasibility, but it has high requirements for the stability and timing of load changes which cannot consider nonlinear influencing factors.Deep learning methods can effectively solve nonlinear problems, and the RNN method in deep learning can handle time series problems well.However, when dealing with long-term sequence problems, it is easy to cause gradient disappearance or explosion [4].LSTM [5] is a nonlinear recurrent neural network, which overcomes the problem of traditional RNN gradient disappearance.It also takes into account the timing and nonlinear relationship of data and can achieve more refined load forecasting.Many scholars have tried to further optimize the LSTM model.Combining the Principal Component Analysis (PCA) method [6][7] with the Particle Swarm Optimization Algorithm (PSO) [8] can greatly improve the prediction effect.In addition, because the power load can readily be impacted due to variables which include weather changes or user production plans, it contains an abundance of noise information, which impacts the model's training effectiveness.The complexity of the algorithm input parameters is also prone to overfitting the established prediction model.
As a consequence, this research presents an approach for ultra-short-term electric load prediction that utilizes PCA decreased noise processing, MIC feature filtering, and LSTM model.First, during the data preprocessing stage, PCA is used to denoise the information to decrease the data dimension and reduce the impact of noise.Then, the MIC approach is utilized to compute the association of power load and meteorological factors.The features that are important to load forecasting are selected.Finally, the LSTM model receives the processed data and uses it for modeling and training.The model in this paper improves the reliability of the sample data through PCA noise reduction, simplifies the prediction model through MIC feature screening, improves the model's ability for generalization and precision of forecasting and effectively prevents overfitting problems which can be suitable for ultrashort-term power load prediction in different regions.

Ultra-short-term power load forecasting utilizing PCA-MIC-LSTM
This research suggests a PCA-MIC-LSTM-based approach for ultra-short-term electric load prediction.In Figure 1, the prediction procedure is depicted.

Data normalization
First of all, the power load data should be standardized and adjusted to a specific band to mitigate the effects of magnitude and scale variations.In this paper, the MinMax method is used to convert the data range to [0, 1], and the normalization function is shown in the formula.
In Formula (1): x is the vector to be normalized, x* is the normalized vector, the vector's maximum value is x max , and its minimum value is x min , correspondingly.

Data noise reduction processing based on PCA
Considering that there is a certain deviation in the collected data, there is redundancy between the features.Therefore, firstly, the PCA dimension reduction and noise reduction processing is performed on the sample data.In this paper, on the premise of retaining the effective information in the sample, initially by shrinking the sample dataset's dimensions, the sample dataset can be noise-filtered.Then the low-dimensional data is upgraded to high-dimensional data which is restored to the dimension of the original data set to achieve a reduction noise effect.

MIC feature screening
The MIC approach is utilized in this work to further screen multiple feature variables.Reshef et al. [9][10] suggested this approach for the first time in 2011, the nonlinear as well as linear associations between variables can be determined by this approach, effectively mining the internal connections between variables.
Assuming that X and Y are two random variables in the dataset, X = {x 1 ,...x n } and Y = {y 1 ,...y n }, n is the total amount of samples, the mutual information of X and Y can be described as: In Formula (2), p(x, y) represents the joint probability density of X and Y, whereas p(x) and p(y) represent the marginal probability density of X and Y, correspondingly.The following is a definition of the MIC for variables X and Y: In Formula (3), n x and n y are the total amount of grids split in the X and Y directions, correspondingly.
The MIC approach is utilized to calculate the correlation between load and meteorological parameters.The feature vector with a strong correlation will be finally chosen as the input element of the LSTM network.

PCA-MIC-LSTM model training
LSTM is selected as the basic model.This research offers a feature screening-based PCA-MIC-LSTM extremely short-term load forecasting strategy to optimize the model's prediction performance.
First, all sample data are normalized and denoised by PCA.Then, the MIC is used to realize the relevant feature screening.The feature vector with a MIC correlation coefficient not less than 0.3 is chosen for the LSTM's input.

Evaluation of prediction results
In this study, the two prediction error assessment criteria used are root mean square error (RMSE) and mean absolute percentage error (MAPE).
In the equation, y i represents the actual load, y i ' represents the predicted load, and n represents the number of prediction points.

Experimental environment
The investigation calculation example in this paper uses Python 3.8 as the programming language.It also uses Keras, an open-source deep learning framework based on Tensorflow as the backend, to build a prediction model for training, learning and prediction.The computer processor used is CPU i7-12700 H.The memory is 16 GB.
The application verification of the PCA-MIC-LSTM model developed in this research is carried out using load data from a specific province.The dataset utilized is electrical load data from January 1, 2020 to May 15, 2022, which is separated into 70%, 15%, and 15% training, validation, and testing sets, correspondingly.

MIC feature screening
Based on the MIC approach, the correlation value between power load and various meteorological indicators is computed, which is displayed in Table 2. From Table 2, it can be seen that the meteorological indicators with a strong correlation with load are the highest temperature, the lowest temperature, and the median temperature, while the correlation with other meteorological indicators is relatively low.Therefore, the three meteorological indicators of the highest temperature, the lowest temperature, and the median temperature are used for model training.

Analysis of prediction results
To demonstrate the efficacy of the prediction algorithm established in the present research, the prediction results and errors of various models are compared.The results of a certain day are visualized in Figure 2. The average prediction error conclusion of the models is displayed in Table 2.The findings in Table 3 indicate that the MAPE of PCA-MIC-LSTM-based ultra-short-term electric load prediction algorithm is 0.64%.The MAPE values of the PCA-MIC-LSTM have lowered by 0.29%, 0.21%, and 0.25%, correspondingly, when compared to the pure LSTM, PCA-LSTM, and MIC-LSTM.This suggests that the PCA-MIC-LSTM has higher accuracy and application value in ultra-short-term power load prediction.By comparing the RMSE of the prediction results of the PCA-MIC-LSTM, the MIC-LSTM, and the PCA-LSTM model, it can be observed that relative to the single LSTM model, the prediction errors of the three models have decreased to varying degrees.This indicates that PCA data denoising and MIC feature screening help to understand the relationship between data structure and features, reflecting the effectiveness of PCA data denoising and MIC feature screening.
To sum up, the ultra-short-term load projection framework utilizing PCA-MIC-LSTM has an excellent performance in forecasting accuracy which can enhance forecasting outcomes.

Comparison of predicted results with other models
To further confirm the accuracy of the forecasting approach described in the investigation, the PCA-MIC-LSTM model was compared with LightGBM, Xgboost, and SVR models, which are frequently employed in prediction situations.The forecasting results and error comparison of a certain day are as follows:   According to Table 4, the error of the PCA-MIC-LSTM model is lower than that of the other three models, indicating that PCA data denoising and MIC feature filtering are more effective in mining data information.Compared with LightGBM, Xgboost, and SVR prediction models, the prediction accuracy of the PCA-MIC-LSTM approach proposed in this investigation has been improved by 0.16%, 0.11%, and 0.32%, respectively.

Conclusions
This paper proposes an ultra-short-term load forecasting method based on PCA-MIC-LSTM.The method provided in this paper effectively extracts important features related to load forecasting by combining PCA denoising and MIC feature screening and utilizes the LSTM model for forecasting.After experimental comparison between the PCA-MIC-LSTM approach proposed in this investigation and the LSTM basic model, LightGBM and Xgboost in the tree model, as well as SVR in the regression model, the prediction accuracy has been improved to varying degrees, achieving good application results and being suitable for ultra-short-term load forecasting in different regions.

Figure 2 .
Figure 2. Comparison of Prediction Results of Various Models Based on LSTM on April 4, 2022.

Figure 2
Figure 2 compares the outcomes of several algorithms' load predictions based on LSTM in the test set on a certain day.According to Figure 2, the predicted outcomes of a single LSTM are relatively low compared to the actual value with a large error.The PCA-LSTM model and MIC-LSTM model have improved their prediction performance compared to LSTM, but the predicted results are unstable in the afternoon.The PCA-MIC-LSTM model is closer to the actual value, and its predicted fluctuation trend and numerical value are more accurate.

Figure 3 .
Figure 3.Comparison of Prediction Results of Various Models on March 6, 2022.

Figure 3
Figure 3 shows the comparison of load prediction results on a certain day in the test set under LightGBM, Xgboost, SVR, and the PCA-MIC-LSTM model.It is observed in the figure that a single SVR model predicts a larger load prediction error, while LightGBM and Xgboost tree models predict relatively low actual values in the morning and evening peak periods which have a larger deviation in predicting extreme points.The PCA-MIC-LSTM model presents an excellent match of the predicted and actual curves with a small error.

Table 1 .
Table 1 displays the LSTM algorithm's parameter settings.Parameter settings for LSTM algorithm.

Table 2 .
Correlation between load and meteorological factors.

Table 3 .
Comparison of prediction effects.

Table 4 .
Comparison of prediction errors with other models.