ELFNet: An Effective Electricity Load Forecasting Model Based on a Deep Convolutional Neural Network with a Double-Attention Mechanism
Abstract
:1. Introduction
- (1)
- A novel deep convolutional attention mechanism model is proposed to solve the issue of electricity load forecasting with strong nonlinear features, which optimizes the deep characteristics of the power load data using the convolution layer, residual connections, and the CA and SA mechanisms;
- (2)
- The proposed deep learning structure is designed to reduce the randomness of the data and guarantee the robustness of machine learning. It can also easily extract the intrinsic properties of the data thanks to the Gram matrix principle, which is used to convert time series data into figure data;
- (3)
- From different time scales, the proposed model can directly output the multi-step prediction results, reduce the prediction error, and achieve more excellent prediction performance results.
2. Background Theory
2.1. Gramian Angular Field
2.2. Residual Convolutional Structure
2.3. Channel Attention Mechanism
2.4. Spatial Attention Mechanism
3. Structure of the Proposed Models
4. Experiment Study
4.1. Experiment Data
4.2. Evaluation Metrics
4.3. Ablation Study
- CNN: the convolutional structure proposed in Section 2.2, without CA and SA modules;
- CNN-CA: the CNN structure with only the CA module added;
- CNN-SA: the CNN structure with only the SA module added;
4.4. Comparative Experiment Results and Analysis
4.5. Robustness Experiment
5. Conclusions
Author Contributions
Funding
Data Availability Statement
Conflicts of Interest
Nomenclature
Adam | The optimizer used for training | SA | Spatial attention |
Avgpool | Average pooling layers | Skew | Skewness value |
CA | Channel attention | SMAPE | Symmetric mean absolute percentage error |
CNN | Convolutional neural network | SNR | Signal–noise ratio |
Conv2d | The 2D convolution operation | Std | Standard deviation |
CV | Coefficient of variation | Activation function | |
DL | Deep learning | The forecast horizon | |
DNN | Deep neural network | Time series | |
ELFNet | Electricity load forecasting networks | Constant normalization factor | |
GAF | Gramian angular field | Correlation coefficient | |
GASF | Gram summation angular field | Polar angles in polar coordinate system | |
Kurt | Kurtosis value | The normalized time series | |
LSTM | Long short-term memory neural network | The effective power of the noise | |
MAE | Mean absolute error | The effective power of the time series | |
MAPE | Mean absolute percentage error | Polar radius in polar coordinate system | |
Max | Maximum | The time stamp of the time series | |
MaxPool | Max pooling layers | The total sample of the time serie | |
Med | Median | Time series after GAF processing | |
Min | Minimum | Feature map data obtained after a 2D convolution | |
MLP | The multiple linear perceptron | Feature map data obtained after four 2D convolutions | |
MSELoss | Error function used for training | Forecast results | |
NN | Neural network | ||
ReLU | Rectified linear unit | ||
ResNet | |||
RMSE | Root mean square error | ||
RNN | Recurrent neural network |
References
- Xi, K.; Dubbeldam, J.; Lin, H.; Schuppen, J. Power-imbalance allocation control for secondary frequency control of power systems. IFAC-PapersOnLine 2017, 50, 4382–4387. [Google Scholar] [CrossRef]
- Deryugina, T.; MacKay, A.; Reif, J. The long-run dynamics of electricity demand: Evidence from municipal aggregation. Am. Econ. J. Appl. Econ. 2020, 12, 86–114. [Google Scholar] [CrossRef]
- Guo, W.; Che, L.; Shahidehpour, M.; Wan, X. Machine-Learning based methods in short-term load forecasting. Electr. J. 2021, 34, 106884. [Google Scholar] [CrossRef]
- Pan, L.; Feng, X.; Sang, F.; Li, L.; Leng, M.; Chen, X. An improved back propagation neural network based on complexity decomposition technology and modified flower pollination optimization for short-term load forecasting. Neural Comput. Appl. 2019, 31, 2679–2697. [Google Scholar] [CrossRef]
- Jiao, J.; Tang, Z.; Zhang, P.; Yue, M.; Yan, J. Cyberattack-resilient load forecasting with adaptive robust regression. Int. J. Forecast. 2022, 38, 910–919. [Google Scholar] [CrossRef]
- Dudek, G. Pattern-based local linear regression models for short-term load forecasting. Electr. Power Syst. Res. 2016, 130, 139–147. [Google Scholar] [CrossRef]
- Matrenin, P.; Safaraliev, M.; Dmitriev, S.; Kokin, S.; Ghulomzoda, A.; Mitrofanov, S. Medium-term load forecasting in isolated power systems based on ensemble machine learning models. Energy Rep. 2022, 8, 612–618. [Google Scholar] [CrossRef]
- Alhmoud, L.; Nawafleh, Q. Short-term load forecasting for Jordan power system based on narx-elman neural network and ARMA model. IEEE Can. J. Electr. Comput. Eng. 2021, 44, 356–363. [Google Scholar] [CrossRef]
- Pedregal, D.; Trapero, J. Adjusted combination of moving averages: A forecasting system for medium-term solar irradiance. Appl. Energy 2021, 298, 117155. [Google Scholar] [CrossRef]
- Bu, X.; Wu, Q.; Zhou, B.; Li, C. Hybrid short-term load forecasting using CGAN with CNN and semi-supervised regression. Appl. Energy 2023, 338, 120920. [Google Scholar] [CrossRef]
- Zhang, Q.; Chen, J.; Xiao, G.; He, S.; Deng, K. TransformGraph: A novel short-term electricity net load forecasting model. Energy Rep. 2023, 9, 2705–2717. [Google Scholar] [CrossRef]
- Liao, Z.; Huang, J.; Cheng, Y.; Li, C.; Liu, P. A novel decomposition-based ensemble model for short-term load forecasting using hybrid artificial neural networks. Appl. Intell. 2022, 52, 11043–11057. [Google Scholar] [CrossRef]
- Talaat, M.; Farahat, M.; Mansour, N.; Hatata, A. Load forecasting based on grasshopper optimization and a multilayer feed-forward neural network using regressive approach. Energy 2020, 196, 117087. [Google Scholar] [CrossRef]
- Mohammed, N.; Al-Bazi, A. An adaptive backpropagation algorithm for long-term electricity load forecasting. Neural Comput. Appl. 2022, 34, 477–491. [Google Scholar] [CrossRef] [PubMed]
- Fekri, M.; Patel, H.; Grolinger, K.; Sharma, V. Deep learning for load forecasting with smart meter data: Online adaptive recurrent neural network. Appl. Energy 2021, 282, 116177. [Google Scholar] [CrossRef]
- Jagait, R.; Fekri, M.; Grolinger, K.; Mir, S. Load forecasting under concept drift: Online ensemble learning with recurrent neural network and ARIMA. IEEE Access 2021, 9, 98992–99008. [Google Scholar] [CrossRef]
- Bui, V.; Pham, T.; Kim, J.; Jang, Y. RNN-based deep learning for one-hour ahead load forecasting. In Proceedings of the 2020 International Conference on Artificial Intelligence in Information and Communication (ICAIIC), Fukuoka, Japan, 19–21 February 2020; pp. 587–589. [Google Scholar]
- Huang, Y.; Huang, Z.; Yu, J.; Dai, X.; Li, Y. Short-term load forecasting based on IPSO-DBiLSTM network with variational mode decomposition and attention mechanism. Appl. Intell. 2023, 53, 12701–12718. [Google Scholar] [CrossRef]
- Zang, H.; Xu, R.; Cheng, L.; Ding, T.; Liu, L.; Wei, Z.; Sun, G. Residential load forecasting based on LSTM fusing self-attention mechanism with pooling. Energy 2021, 229, 120682. [Google Scholar] [CrossRef]
- Bashir, T.; Haoyong, C.; Tahir, M.F.; Liqiang, Z. Short term electricity load forecasting using hybrid prophet-LSTM model optimized by BPNN. Energy Rep. 2022, 8, 1678–1686. [Google Scholar] [CrossRef]
- Memarzadeh, G.; Keynia, F. Short-term electricity load and price forecasting by a new optimal LSTM-NN based prediction algorithm. Electr. Power Syst. Res. 2021, 192, 106995. [Google Scholar] [CrossRef]
- Khan, S.; Javaid, N.; Chand, A.; Khan, A.; Rashid, F.; Afridi, I. Electricity load forecasting for each day of week using deep CNN. In Proceedings of the Workshops of the International Conference on Advanced Information Networking and Applications, Matsue, Japan, 27–29 March 2019; pp. 1107–1119. [Google Scholar]
- Singh, N.; Vyjayanthi, C.; Modi, C. Multi-step short-term electric load forecasting using 2D convolutional neural networks. In Proceedings of the 2020 IEEE-HYDCON, Hyderabad, India, 11–12 September 2020; IEEE: New York, NY, USA, 2020; pp. 1–5. [Google Scholar]
- Imani, M. Electrical load-temperature CNN for residential load forecasting. Energy 2021, 227, 120480. [Google Scholar] [CrossRef]
- Wang, Z.; Oates, T. Imaging time-series to improve classification and imputation. In Proceedings of the 24th International Conference on Artificial Intelligence, Buenos Aires, Argentina, 25–31 July 2015; pp. 3939–3945. [Google Scholar]
- Wang, Z.; Oates, T. Spatially encoding temporal correlations to classify temporal data using convolutional neural networks. arXiv 2015, arXiv:1509.07481. [Google Scholar]
- Chen, W.; Shi, K. A deep learning framework for time series classification using relative position matrix and convolutional neural network. Neurocomputing 2019, 359, 384–394. [Google Scholar] [CrossRef]
- Barra, S.; Carta, S.; Corriga, A.; Podda, A.; Recupero, D. Deep learning and time series-to-image encoding for financial forecasting. IEEE/CAA J. Autom. Sin. 2020, 7, 683–692. [Google Scholar] [CrossRef]
- Acikgoz, H.; Budak, U.; Korkmaz, D.; Yildiz, C. WSFNet: An efficient wind speed forecasting model using channel attention-based densely connected convolutional neural network. Energy 2021, 233, 121121. [Google Scholar] [CrossRef]
- Hong, Y.Y.; Martinez, J.J.F.; Fajardo, A.C. Day-ahead solar irradiation forecasting utilizing gramian angular field and convolutional long short-term memory. IEEE Access 2020, 8, 18741–18753. [Google Scholar] [CrossRef]
- Himeur, Y.; Alsalemi, A.; Bensaali, F.; Amira, A. An intelligent nonintrusive load monitoring scheme based on 2D phase encoding of power signals. Int. J. Intell. Syst. 2021, 36, 72–93. [Google Scholar] [CrossRef]
- Azza, A.; Ienco, D.; Abbes, A.B.; Farah, I.R. Combining 2D Encoding and Convolutional Neural Network to Enhance Land Cover Mapping from Satellite Image Time Series. Eng. Appl. Artif. Intell. 2023, 122, 106152. [Google Scholar]
- Lan, D.; Zhu, H.; Wu, J.; Li, F.; Zhang, J.; Sun, H. A short-term load forecasting method of distribution network based on improved AlexNet-GRU deep learning network. In Proceedings of the 2021 IEEE 5th Conference on Energy Internet and Energy System Integration (EI2), Taiyuan, China, 22–24 October 2021; pp. 3004–3010. [Google Scholar]
- Zheng, X.; Wang, B.; Du, X.; Lu, X. Mutual attention inception network for remote sensing visual question answering. IEEE Trans. Geosci. Remote Sens. 2022, 60, 5606514. [Google Scholar] [CrossRef]
- Zhang, W.; Quan, H.; Gandhi, O.; Rajagopal, R.; Tan, C.W.; Srinivasan, D. Improving probabilistic load forecasting using quantile regression NN with skip connections. IEEE Trans. Smart Grid 2020, 11, 5442–5450. [Google Scholar] [CrossRef]
- Sheng, Z.; Wang, H.; Chen, G.; Zhou, B.; Sun, J. Convolutional residual network to short-term load forecasting. Appl. Intell. 2021, 51, 2485–2499. [Google Scholar] [CrossRef]
- Xie, S.; Girshick, R.; Dollar, P.; Tu, Z.; He, K. Aggregated residual transformations for deep neural networks. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Honolulu, HI, USA, 21–26 July 2017; pp. 1492–1500. [Google Scholar]
- Vaswani, A.; Shazeer, N.; Parmar, N.; Uszkoreit, J.; Jones, L.; Gomez, A.; Kaiser, Ł.; Polosukhin, I. Attention is all you need. Adv. Neural Inf. Process. Syst. 2017, 30, 5998–6008. [Google Scholar]
- Woo, S.; Park, J.; Lee, J.Y.; Kweon, I. Cbam: Convolutional block attention module. In Proceedings of the European Conference on Computer Vision (ECCV), Munich, Germany, 8–14 September 2018; pp. 3–19. [Google Scholar]
- He, K.; Zhang, X.; Ren, S.; Sun, J. Deep residual learning for image recognition. In Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition, Las Vegas, NV, USA, 27–30 June 2016; pp. 770–778. [Google Scholar]
- Tang, X.; Chen, H.; Xiang, W.; Yang, J.; Zou, M. Short-term load forecasting using channel and temporal attention based temporal convolutional network. Electr. Power Syst. Res. 2022, 205, 107761. [Google Scholar] [CrossRef]
- Wang, S.; Li, R.; Wang, X.; Shen, S.; Zhou, B.; Wang, Z. Multiscale residual network based on channel spatial attention mechanism for multilabel ECG classification. J. Healthc. Eng. 2021, 2021, 6630643. [Google Scholar] [CrossRef]
- Zhao, S.; Wu, Q.; Zhang, Y.; Wu, J.; Li, X.A. An asymmetric bisquare regression for mixed cyberattack-resilient load forecasting. Expert Syst. Appl. 2022, 210, 118467. [Google Scholar] [CrossRef]
Max (Mw) | Min (Mw) | Med (Mw) | Mean (Mw) | Std (Mw) | CV (%) | Skew | Kurt | |
---|---|---|---|---|---|---|---|---|
Dataset | 12591.59 | 6823.94 | 9391.1 | 9335.93 | 1068.91 | 0.1145 | −0.0571 | −0.858 |
Training | 12591.59 | 6883.69 | 9551.95 | 6568.26 | 1053.28 | 0.1114 | −0.0725 | −0.782 |
Testing | 11390.69 | 6823.94 | 8995.8 | 9065.98 | 1056.53 | 0.1165 | −0.0114 | −1.131 |
Metric | Horizon | CNN | CNN-CA | CNN-SA | ELFNet |
---|---|---|---|---|---|
RMSE | 1 h | 0.0465 | 0.0349 | 0.0409 | 0.0316 |
2 h | 0.0442 | 0.0402 | 0.0441 | 0.0346 | |
3 h | 0.0542 | 0.0479 | 0.0482 | 0.0417 | |
MAE | 1 h | 0.0373 | 0.0274 | 0.0321 | 0.0254 |
2 h | 0.0354 | 0.0317 | 0.0348 | 0.0270 | |
3 h | 0.0440 | 0.0377 | 0.0379 | 0.0333 | |
SMAPE | 1 h | 0.2806 | 0.2259 | 0.2652 | 0.2246 |
2 h | 0.2777 | 0.2525 | 0.2753 | 0.2402 | |
3 h | 0.3225 | 0.3050 | 0.2983 | 0.2813 | |
MAPE | 1 h | 0.3769 | 0.3179 | 0.4021 | 0.3323 |
2 h | 0.3939 | 0.3846 | 0.4941 | 0.3689 | |
3 h | 0.5631 | 0.4151 | 0.4495 | 0.4118 | |
R | 1 h | 0.9899 | 0.9916 | 0.9892 | 0.9920 |
2 h | 0.9895 | 0.9888 | 0.9869 | 0.9911 | |
3 h | 0.9779 | 0.9840 | 0.9836 | 0.9892 |
Metrics | Horizon | ResNet-18 | ResNeXt-50 | GoogleLeNet | ELFNEt |
---|---|---|---|---|---|
1 h | 0.0569 | 0.0514 | 0.0506 | 0.0316 | |
RMSE | 2 h | 0.0700 | 0.0586 | 0.0464 | 0.0346 |
3 h | 0.0836 | 0.0661 | 0.0541 | 0.0417 | |
1 h | 0.0445 | 0.0404 | 0.0395 | 0.0254 | |
MAE | 2 h | 0.0563 | 0.0460 | 0.0353 | 0.0270 |
3 h | 0.0671 | 0.0522 | 0.0415 | 0.0333 | |
1 h | 0.3322 | 0.3070 | 0.3013 | 0.2246 | |
SMAPE | 2 h | 0.4161 | 0.3612 | 0.2697 | 0.2402 |
3 h | 0.4996 | 0.4186 | 0.3009 | 0.2813 | |
1 h | 0.4498 | 0.4520 | 0.3812 | 0.3323 | |
MAPE | 2 h | 0.5449 | 0.6055 | 0.3762 | 0.3689 |
3 h | 0.6703 | 0.6727 | 0.4141 | 0.4118 | |
1 h | 0.9752 | 0.9812 | 0.9806 | 0.9920 | |
R | 2 h | 0.9738 | 0.9792 | 0.9841 | 0.9911 |
3 h | 0.9657 | 0.9754 | 0.9784 | 0.9892 |
Metric | Horizon | SNR20 | SNR30 | SNR40 | SNR50 | SNR60 | SNR70 | ELFNet |
---|---|---|---|---|---|---|---|---|
RMSE | 1 h | 0.03742 | 0.03317 | 0.03162 | 0.03317 | 0.03461 | 0.03606 | 0.0316 |
2 h | 0.05657 | 0.03873 | 0.03606 | 0.03873 | 0.03742 | 0.04 | 0.0346 | |
3 h | 0.05916 | 0.05521 | 0.05477 | 0.04359 | 0.04583 | 0.4472 | 0.0417 |
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content. |
© 2024 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/).
Share and Cite
Zhao, P.; Ling, G.; Song, X. ELFNet: An Effective Electricity Load Forecasting Model Based on a Deep Convolutional Neural Network with a Double-Attention Mechanism. Appl. Sci. 2024, 14, 6270. https://doi.org/10.3390/app14146270
Zhao P, Ling G, Song X. ELFNet: An Effective Electricity Load Forecasting Model Based on a Deep Convolutional Neural Network with a Double-Attention Mechanism. Applied Sciences. 2024; 14(14):6270. https://doi.org/10.3390/app14146270
Chicago/Turabian StyleZhao, Pei, Guang Ling, and Xiangxiang Song. 2024. "ELFNet: An Effective Electricity Load Forecasting Model Based on a Deep Convolutional Neural Network with a Double-Attention Mechanism" Applied Sciences 14, no. 14: 6270. https://doi.org/10.3390/app14146270
APA StyleZhao, P., Ling, G., & Song, X. (2024). ELFNet: An Effective Electricity Load Forecasting Model Based on a Deep Convolutional Neural Network with a Double-Attention Mechanism. Applied Sciences, 14(14), 6270. https://doi.org/10.3390/app14146270