Short-Term Electricity Consumption Forecasting Based on the EMD-Fbprophet-LSTM Method
Short-term electricity consumption data reflects the operating efficiency of grid companies, and accurate forecasting of electricity consumption helps to achieve refined electricity consumption planning and improve transmission and distribution transportation efficiency. In view of the fact that the power consumption data is nonstationary, nonlinear, and greatly influenced by the season, holidays, and other factors, this paper adopts a time-series prediction model based on the EMD-Fbprophet-LSTM method to make short-term power consumption prediction for an enterprise's daily power consumption data. The EMD model was used to decompose the time series into a multisong intrinsic mode function (IMF) and a residual component, and then the Fbprophet method was used to predict the IMF component. The LSTM model is used to predict the short-term electricity consumption, and finally the prediction value of the combined model is measured based on the weights of the single Fbprophet and LSTM models. Compared with the single time-series prediction model, the time-series prediction model based on the EMD-Fbprophet-LSTM method has higher prediction accuracy and can effectively improve the accuracy of short-term regional electricity consumption prediction.
In the new electricity market, the members of the electricity market need to remain stable in the market in order to make the highest possible profit, and this profit is closely related to the accurate forecasting of electricity consumption . The demand for electricity consumption by customers is affected by many uncertainties, and an accurate forecasting model has an important role in improving the operation and planning of the power system, the main purpose of which is to help plan future power consumption and power load, so that a balance is achieved between power consumption and power production in order to reduce operating costs and resource waste . In order to build a reasonably sized, safe, and reliable power system, electricity sales companies or agency platforms are now allowed to sell electricity to industrial or residential customers, optimizing the grid structure, enabling spatial segmentation of the electricity consumption market, and ensuring reliability of supply . By improving the accuracy and reliability of short-term electricity consumption prediction, the response speed of the grid to unexpected situations can be improved, the operational efficiency of the transmission and distribution network can be improved, the power consumption planning of the grid can be refined, and daily maintenance costs can be reduced .
Current forecasts of electricity consumption are generally divided into short-term forecasts, medium-term forecasts, and long-term forecasts, with the medium-term and long-term forecasts mainly focusing on monthly and above time scales of electricity demand, while the short-term forecasts are for demand within a day . Traditional forecasting methods are based on mathematical methods, such as regression analysis, ARIMA model, and exponential smoothing . The autoregressive moving model (ARIMA) is often applied to short-term time series with strong regularity and periodicity, and literature  adopts the ARIMA model for short-term prediction and evaluation of a month’s power load data in Dayton, and, by comparing the relative errors, the prediction value of the model is found to be more accurate. Reference  applied the exponential smoothing method for medium-term and long-term demand forecasting, which is suitable for large areas with relatively little uncertainty, and some seasonal factors can also be included in the model. These methods are simple and easy to use, but when encountering nonlinear and unstable electricity consumption data, the forecast results are not highly accurate and prone to various problems . Artificial intelligence methods have been proposed, which will effectively solve the accuracy problem in load forecasting, including BP neural networks (ANNs)  and support vector machines (SVMs) . Reference  adopts the support vector machine (SVM) model to forecast the medium-term and long-term electricity consumption in Jibei region, taking into account the economic environment and the downstream environment of the industrial chain, through which the complexity of the calculation is reduced, the speed of the calculation is accelerated, and the accuracy of the prediction is improved. Reference  proposes an improved BP neural network prediction model, which effectively improves the convergence and prediction accuracy by batch-processing the data. Although a single intelligent algorithmic model has good adaptability to nonlinear and unstructured electricity consumption data and the accuracy of prediction can be improved to some extent by deeply mining the inherent patterns of electricity consumption data, its prediction results are difficult to promote the use, so many scholars use combinatorial models to improve the robustness of the model and the accuracy of prediction . Reference  proposes a model for predicting regional electricity consumption based on gray prediction and stochastic forest combination method, which considers the interaction between electricity consumption and economic indicators. Reference  constructs a prediction model based on random forest (RF) and deep belief network (DBN) to simplify the structure of electricity prediction model by unbiased optimization identification of variables, which helps to improve the training rate and generalization ability of the model. Combinatorial forecasting method is greatly influenced by random factors, and multiple factors work together on electricity consumption, so preprocessing of data is needed before forecasting, and the fluctuating characteristics of electricity consumption data can be well analyzed by decomposition. Reference  proposed a short-term load prediction model based on GM (1, 1) and EMD combinatorial model, which better adapts to the randomness and periodicity of load and significantly improves the accuracy of prediction. In literature , the time series is decomposed by wavelet function, and different models are built for predicting the time series on different scales, and the complete prediction result is obtained by sequence reconstruction, which improves the prediction accuracy and the modeling efficiency. Reference  proposes a prediction model based on the combination of EMD and LSTM, which can be predicted by modeling each component and is more suitable for nonlinear electricity consumption prediction than the traditional single model.
Based on the shortcomings of existing studies, such as the complexity of processing complex data and the lack of general applicability of prediction results, this paper proposes a combined prediction model to predict short-term electricity consumption. Since short-term electricity consumption data is a nonlinear, nonstationary series consisting of multiple frequency superpositions, the volatility of electricity consumption data is the focus of research and is affected by a variety of external factors, such as daily, weekly, and seasonal cyclicality [20, 21]. The previously proposed methods and models have greater complexity and uncertainty in predicting this type of data, so there is still a need for a more accurate method to target and obtain more valuable results. To this end, this paper proposes a new EMD-Fbprophet-LSTM short-term electricity consumption prediction model, which firstly uses the LSTM method to predict short-term electricity consumption and secondly uses the Fbprophet time-series model to predict electricity consumption based on the decomposition of electricity consumption by EMD. As a new and more advanced hybrid model, the EMD-Fbprophet-LSTM model takes into account the unique fluctuating characteristics of electricity demand on different time scales and the influence of factors such as weather on customer demand and provides lower forecast errors and better results when forecasting short-term electricity consumption of customers.
This study is a time-series forecast of short-term electricity consumption, with a forecast lead time of one day, taking full account of the temporal correlation between dynamic electricity consumption data. The LSTM has strong generalization ability, good learning ability for both large and small data sets, and strong advantages for the processing of nonlinear data, which can improve the accuracy of short-term power consumption prediction. The empirical mode decomposition (EMD)  is based on the different waveform data obtained from the electricity consumption data, and, according to the time series of the waveform data itself, it can smoothly decompose the nonlinear and nonstationary time series, which is usually decomposed into a small number of embedded mode function components (intrinsic mode functions, IMF) and a residual component, thus reducing the nonstationarity of the original data and the complexity of the time series even more, so that the periodicity and trend of the original data series can be revealed. Using the Fbprophet time-series model  to implement the prediction of the IMF component, the prediction results can be obtained quickly and accurately, the outliers in the time series can be handled effectively, and the seasonal and holiday factors in the time series can be taken into account. The final empirical evidence shows that the prediction of electricity consumption by combining the Fbprophet and LSTM method has a high accuracy, and the simulation results verify that it is an effective method for short-term electricity consumption prediction.
Based on the above, the important questions can be summarized as follows:(1)Disaggregation of the original short-term electricity consumption data using the EMD method(2)The Fbprophet forecasting model is used to forecast each part of the IMF, taking into account the effects of holidays and other factors, in order to obtain valid electricity consumption forecasts(3)Adopt LSTM model to forecast the short-term electricity consumption(4)Construct a combined EMD-Fbprophet-LSTM model to forecast short-term electricity consumption and compare the forecast results with those of ARIMA model and single Fbprophet model, LSTM model, and EMD-Fbprophet model to prove the validity of the model proposed in this paper
The rest of the paper is presented as follows. Section 2 introduces the algorithmic principles of EMD, Fbprophet, and LSTM and constructs the EMD-Fbprophet-LSTM model proposed in this paper. Section 3 selects the electricity consumption data of an enterprise in Province Z for empirical study and compares and verifies the results to prove the accuracy of the prediction results. Section 4 gives the conclusion of this paper.
2. Models and Estimates
2.1. Principle of EMD Algorithm
Empirical mode decomposition (EMD) is an adaptive time-series decomposition method that smooths the nonlinear time series into feature components with different feature scales, namely, the intrinsic mode function (IMF) component, and the residual component r(t). The decomposed resulting IMF represents the fluctuating components of different time scales implicit in the raw electricity consumption data, and its values and waveforms can well reflect the characteristics of the raw electricity consumption data. The residual term, on the other hand, represents the trend of the forecast series [24, 25]. The basic steps are as follows:(1)Find the maximum and minimum points of the original signal , fit the upper and lower envelope lines and of , and calculate the mean values of and , :(2)Calculate the difference between the raw data and the mean of the envelope lines, :(3)Determine the nature of ; if it is satisfied that the numbers of zero crosses and extreme points in are the same and the local maxima and minimal values, respectively, form envelope lines that are zero-mean, then is an IMF component. Otherwise, the above steps need to be repeated for screening.(4)Define residuals :(5)Repeat filtering to the point where no new IMF can be filtered. Then the original signal can be expressed as the decomposed IMF and the residuals of the sum.
2.2. Principles of the Fbprophet Algorithm
The Fbprophet model is a time-series prediction tool proposed by Facebook in 2017, which carries out time-series prediction through time-series-based decomposition and machine learning fitting . The Fbprophet prediction process consists of four parts: model building, evaluation of predictions, problem solving, and manual checking, which work in a sequential loop until a suitable predictive model is obtained. The Fbprophet algorithm decomposes the time series into three parts, as shown in the following equation:where is the trend term, which represents the trend of the time series on a nonperiodic basis; is the seasonal term (period term); is the holiday term; and is the error.
By fitting these three items through the submodel, it can be reasonably applied to a variety of time-series predictions with regularity and can identify and adjust the anomalies in the data, effectively dealing with the jump points and periodicity of the time series, while the Fbprophet algorithm also takes into account the seasonal and holiday effects that are of concern to the prediction model and is a convenient and efficient time-series prediction tool.
2.3. Principle of LSTM Algorithm
LSTM (Long Short-Term Memory) consists of an input layer, a hidden layer, and an output layer , which can effectively solve the problem of gradient disappearance or explosion due to the long time span of dependencies between information, learn and predict based on historical information, balance the temporal and nonlinear relationships of electricity consumption data, and obtain better prediction results. Figure 1 shows the network structure of LSTM.
2.3.1. Oblivion Gate
The forgetting gate determines how much information can be passed from the previous cell state to the current cell state, with an output of 1 indicating that all information from the previous moment is retained and an output of 0 indicating that all information from the previous moment is discarded.where is the oblivion gate, is the excitation function, taking values between [0, 1], is the weight matrix, and is the deviation vector.
2.3.2. Input Gate
The input gate updates the candidate information in the memory cell by activating the function to filter new input information and add it to the memory cell.where and are the input gate, xt is the input vector, and are the deviation vectors.
2.3.3. Update Cell State
The output of the forgetting gate and the old cell state of the previous moment form part of the updated cell state , while the other part consists of the output of the input gate and the memory cell candidate state.where is the updated cell state and is the old cell state at the previous moment.
2.3.4. Input Gates and Hidden Layer Outputs
The output gate can be obtained by the excitation function . The output vector ht can be obtained by compressing and updating the cell state .where is the output gate and is the output vector.
2.4. Model Integration
The construction of a combined prediction model can combine the advantages of each single model and improve the prediction accuracy. In this paper, the weights of the models are determined using the variance method and are calculated as follows.
Calculate the variance corresponding to each prediction model.
Get the weights from the variance.
After deriving the weights, the respective predictions are multiplied by the corresponding predictions to obtain the combined predictions.where indicates the predicted result. denote the separate predictions of the LSTM model and the EMD-Fbprophet model, respectively.
2.5. Model Construction
After decomposing the time series by EMD method, the resulting IMF component can simplify the time-series forecasting model with a high degree of fit, but the lower-order IMF component is still highly volatile and cannot be simply discarded for noise reduction as it retains some of the information from the time series. Since short-term electricity consumption forecasts are influenced by complex external market factors, the Fbprophet model relies only on historical time series, it is difficult to utilize other external information related to the forecast target, and if used alone it will not achieve the desired forecast level due to insufficient information. Since the prediction accuracy of LSTM is affected by the selection of key parameters and the size of the dataset, for the predictive analysis of nonlinear time series, this paper proposes a combined LSTM-Fbprophet model for short-term electricity consumption prediction. Based on the advantages of LSTM neural network for long-time problem processing and EMD-Fbprophet algorithm for mutation point and periodic problem processing, the combined LSTM-Fbprophet algorithm can effectively improve the prediction accuracy. The modeling process is shown in Figure 2.(1)The decomposition of the original time series into a number of IMF components and a residual component r(t) using EMD highlighting the local characteristics of the original data, which can well reflect the periodicity, trend, randomness, and other characteristics of the original data(2)Preprocessing the load data of the decomposed subseries to normalize the data(3)Prediction of each IMF component and residual component r(t) using the Fbprophet method to integrate the prediction results and obtain the time-series prediction results(4)Prediction of the time-series analysis using the LSTM method to obtain the prediction results of the time series(5)Determining the respective weights according to the variance of the LSTM model and Fbprophet model, integrating the prediction results, and obtaining the final prediction results
3. Case Study
3.1. Data Description
The dataset used in this paper is for the installation of smart meters at an enterprise in Province Z between January 1, 2019, and September 27, 2019. The sum of the users’ daily electricity consumptions is 270 data samples (the data have been desensitized). To test the predictive power of the model, this paper splits the dataset into a training data sample and a predictive test data sample, using the former daily. The electricity consumption data trained the model and predicted the daily electricity consumption for the last 7 days. The mean absolute percentage error (MAPE), root mean square error (RMSE), and mean absolute error (MAE) were used as the indicators to assess the effectiveness of predictive models, comparative analysis of the Fbprophet model, and EMD-Fbprophet predicted results of the model.
In this paper, all algorithms of the proposed technique are implemented in Python 3.7.9 software.
3.2. Descriptive Analysis and Data Preprocessing
As can be seen in Figure 3, there is a large volatility in regional daily electricity consumption data, and there are more external factors affected by changes in daily electricity consumption. Holidays have a greater impact on electricity consumption, and, during special holidays, such as around Chinese New Year, there is a significant trough in electricity consumption. Electricity consumption is significantly higher than weekend consumption, showing a cyclical variation on a weekly basis.
For missing data and anomalies, the average of the valid data before and after two weeks is used to fill in the missing and anomalous data. The preprocessing of the data does not remove data points such as holidays which cause significant changes in electricity consumption.
3.3. Experimental Results
This paper uses the front part of the dataset as a training sample to predict the daily electricity consumption for the last 7 days; in order to prove the validity of the proposed model in the prediction model, this paper will longitudinally compare the prediction performances of ARIMA, LSTM, Fbprophet model, and the proposed LSTM-Fbprophet model to analyze the daily electricity consumption.
The EMD method is used to decompose the short-term electricity consumption data after preprocessing to obtain waveforms formed by six different intrinsic modal functions (IMF) and a residual component (see Figure 4).
In Figure 4, the six IMFs are sorted according to their frequencies to show some of the periodicity of factors affecting the time series, reflecting the impact of noninfluential factors on the electricity consumption data at different scales. The higher frequency of the components in IMF1 and IMF2 can be seen as the high-frequency component of the original series and the more pronounced periodicity of the components in IMF3, which can be seen as the periodic component of the original series. The component frequencies in IMF4, IMF5, and IMF6 are low and can be considered as low-frequency components. The residual component Res, on the other hand, represents the long-term trend of the electricity consumption series.
In order to better test the accuracy of the proposed model, the ARIMA model, LSTM model, Fbprophet model, and the proposed model are used to predict the daily electricity consumption data for the last 7 days of an enterprise, respectively. The predicted results are shown in Table 1 and Figure 5. Among them, the error is positive when the predicted value is larger than the actual electricity consumption and it is negative when the predicted value is smaller than the actual electricity consumption.
Model prediction accuracy indicators used are MAPE, RMSE, and MAE, where MAPE reflects the overall level of deviation between the model prediction value and the actual value of the prediction test data sample, and the smaller the value of MAPE, the higher the prediction accuracy; RMSE reflects the degree of dispersion of error, and the smaller the value of RMSE, the better the prediction stability; MAE is the average absolute error, and the smaller the value, the higher the prediction accuracy. The models MAPE, RMSE, and MAE were obtained (see Table 2).
Through the comparison of the actual and predicted values and the statistical analysis of the error indicators, the following conclusions can be drawn.
First, the proposed model’s MAPE, RMSE, and MAE are the smallest, which means that the model has better average forecast accuracy and stability than the ARIMA, LSTM, Fbprophet, and EMD-Fbprophet models.
Second, the RMSE value of ARIMA is the largest among the several models, indicating a moderate prediction performance. Fbprophet and EMD-Fbprophet models are more stable than ARIMA, and the LSTM model is second only to the model proposed in this paper in terms of accuracy. The prediction trend of the proposed model is basically consistent with the actual value, which has the highest stability and accuracy, and can better grasp the daily electricity consumption trend.
In this paper, a short-term electricity consumption prediction model based on the combination of EMD-Fbprophet and LSTM method is proposed. Firstly, the EMD method is used to decompose the raw data of regional daily electricity consumption, the subseries and residual series of low frequency and high frequency are obtained, and the influence of different components is distinguished to reduce the complexity, randomness, and nonstationarity of the raw data. The Fbprophet method is used to model predictions for each component. Then short-term electricity consumption is predicted by a single LSTM model. Finally, the prediction results of the combined EMD-Fbprophet-LSTM prediction model are measured based on the weights obtained from the variance. In addition, in order to prove the validity and optimality of the EMD-Fbprophet-LSTM prediction model proposed in this paper, the EMD-Fbprophet-LSTM model and the prediction results of the traditional ARMA method with a single Fbprophet and LSTM model are compared and analyzed in the empirical analysis. The experimental results show that the fluctuations of the EMD-Fbprophet-LSTM optimized prediction model errors are relatively smaller, and, by distinguishing the effects of different components, the complexity, randomness, and nonstationarity of the raw data are reduced, which can effectively improve the prediction accuracy and precision, reduce the prediction errors, and have a good ability to accurately predict the short-term nonlinear electricity consumption data.
Since short-term electricity consumption data are nonlinear data with strong volatility and instability and the EMD-Fbprophet-LSTM prediction model proposed in this paper can predict data with strong holiday effects and seasonal fluctuations well and can also handle outliers well, it can effectively reduce the prediction error and improve the prediction accuracy. Therefore, the model can effectively forecast short-term electricity consumption, which is conducive to balancing demand-side management, guaranteeing basic electricity consumption, and helping power companies to rationally allocate power resources and providing them with more accurate decision support.
The data were from State Grid Zhejiang Economic Research Institute and have been desensitized.
Conflicts of Interest
There are no conflicts of interest regarding the publication of this paper.
This work was supported by the application of artificial intelligence technology in the decision-making of core value flow operations of power grid companies under the spot market environment, State Grid Zhejiang Economic Research Institute (Grant no. 5211JY18000X).
O. Abedinia, M. Zareinejad, M. H. Doranehgard, G. Fathi, and N. Ghadimi, “Optimal offering and bidding strategies of renewable energy based large consumer using a novel hybrid robust-stochastic approach,” Journal of Cleaner Production, vol. 215, pp. 878–889, 2019.View at: Publisher Site | Google Scholar
C. Liu, Bo Sun, Chenghui et al., “A hybrid prediction model for residential electricity consumption using holt-winters and extreme learning machine,” Applied Energy, vol. 275, Article ID 115383, 2020.View at: Google Scholar
W. Bin, “Short-term forecast analysis of power load based on time series ARIMA model,” Shihezi Science and Technology, vol. 3, pp. 43–47, 2019, (In Chinese).View at: Google Scholar
L. Gangyun, C. Haozhong, and D. Yifeng, “Middle and long term electricity demand forecasting based on multi-exponents sliding forecast model,” East China Electric Power, vol. 7, pp. 8–10, 2004, (In Chinese).View at: Google Scholar
L. Shunxin, J. Guoqiang, K. Hui et al., “Modeling forecast of annual maximum load in northern Hebei province based on support vector machine,” Science Technology and Engineering, vol. 19, no. 36, pp. 179–183, 2019.View at: Google Scholar
X. Yang, J.-f. Yao, J.-y. Xu et al., “Electric quantity prediction based on grey prediction and Stochastic Forest Combination Algorithm,” Rural Electrification, vol. 7, pp. 13–17, 2020, (in Chinese).View at: Google Scholar
Y. Gu, Y. Wang, and J. Kang, “Research on medium and long term electricity consumption prediction based on RF and deep learning,” Electromechanical Information, vol. 6, pp. 15–17, 2019, (in Chinese).View at: Google Scholar
F. Jiao, F. Hao, N. Dongxiao et al., “Monthly electricity sales forecast based on wavelet analysis and GM-ARIMA model,” Journal of North China Electric Power University (Natural Science Edition), vol. 42, no. 4, pp. 101–105, 2015, (In Chinese).View at: Google Scholar
R. Chengguo, X. Erliang, J. Xianzhong et al., “Application research of deep learning in short-term power load forecasting,” Electric Power Science and Engineering, vol. 35, no. 8, pp. 12–16, 2019.View at: Google Scholar
A. Francesco, “Relationships between meteorological variables and monthly electricity demand,” Applied Energy, vol. 98, pp. 346–356, 2012.View at: Google Scholar
K. Menghai and Y. Jianjun, “Ending balance forecasting method based on fbprophet framework,” E-Science Technology & Application, vol. 10, no. 3, pp. 13–20, 2019.View at: Google Scholar
B. Zhou, B. Sun, X. Gong et al., “Ultra-short-term prediction of wind power based on EMD and DLSTM,” in Proceedings of the 2019 14th IEEE Conference On Industrial Electronics And Applications (ICIEA), Xi’an, China, June 2019.View at: Google Scholar
N. K. Chikkakrishna, C. Hardik, K. Deepika, and N. Sparsha, “Short-term traffic prediction using sarima and FbPROPHET,” in Proceedings of the 2019 IEEE 16th India Council International Conference (INDICON), Rajkot, India, December 2019.View at: Google Scholar