IDEAS home Printed from https://ideas.repec.org/a/gam/jeners/v18y2025i6p1468-d1613979.html
   My bibliography  Save this article

Deep Learning Framework Using Transformer Networks for Multi Building Energy Consumption Prediction in Smart Cities

Author

Listed:
  • Samuel Moveh

    (Engineering Faculty, Transport and Telecommunication Institute, 1019 Riga, Latvia)

  • Emmanuel Alejandro Merchán-Cruz

    (Engineering Faculty, Transport and Telecommunication Institute, 1019 Riga, Latvia)

  • Maher Abuhussain

    (Department of Civil and Environmental Engineering, College of Engineering and Computing in Al-Qunfudhah, Umm Al-Qura University, Mecca 24221, Saudi Arabia)

  • Yakubu Aminu Dodo

    (Architectural Engineering Department, College of Engineering, Najran University, Najran 66426, Saudi Arabia)

  • Saleh Alhumaid

    (Department of Mechanical Engineering, University of Hail, Hail 81481, Saudi Arabia)

  • Ali Hussain Alhamami

    (Civil Engineering Department, College of Engineering, Najran University, Najran 66454, Saudi Arabia)

Abstract

The increasing complexity of urban building energy systems necessitates advanced prediction methods for efficient energy management. Urban buildings account for approximately 40% of global energy consumption, making accurate prediction crucial for sustainability goals. This research develops a novel transformer-based deep learning framework for multi-building energy consumption forecasting. Despite recent advances in energy prediction techniques, existing models struggle with multi-building scenarios due to limited ability to capture cross-building correlations, inadequate integration of diverse data streams, and poor scalability when deployed at urban scale—gaps this research specifically addresses. The study implemented a modified transformer architecture with hierarchical attention mechanisms, processing data from 100 commercial buildings across three climate zones over three years (2020–2023). The framework incorporated weather parameters, occupancy patterns, and historical energy consumption data through multi-head attention layers, employing a 4000-step warm-up period and adaptive regularization techniques. The evaluation included a comparison with the baseline models (ARIMA, LSTM, GRU) and robustness testing. The framework achieved a 23.7% improvement in prediction accuracy compared to traditional methods, with a mean absolute percentage error of 3.2%. Performance remained stable across building types, with office complexes showing the highest accuracy (MAPE = 2.8%) and healthcare facilities showing acceptable variance (MAPE = 3.5%). The model-maintained prediction stability under severe data perturbations while demonstrating near-linear computational scaling. The transformer-based approach significantly enhances building energy prediction capabilities, enabling more effective demand-side management strategies, though future research should address long-term adaptability.

Suggested Citation

  • Samuel Moveh & Emmanuel Alejandro Merchán-Cruz & Maher Abuhussain & Yakubu Aminu Dodo & Saleh Alhumaid & Ali Hussain Alhamami, 2025. "Deep Learning Framework Using Transformer Networks for Multi Building Energy Consumption Prediction in Smart Cities," Energies, MDPI, vol. 18(6), pages 1-22, March.
  • Handle: RePEc:gam:jeners:v:18:y:2025:i:6:p:1468-:d:1613979
    as

    Download full text from publisher

    File URL: https://www.mdpi.com/1996-1073/18/6/1468/pdf
    Download Restriction: no

    File URL: https://www.mdpi.com/1996-1073/18/6/1468/
    Download Restriction: no
    ---><---

    References listed on IDEAS

    as
    1. Hu, Yuqing & Cheng, Xiaoyuan & Wang, Suhang & Chen, Jianli & Zhao, Tianxiang & Dai, Enyan, 2022. "Times series forecasting for urban building energy consumption based on graph convolutional network," Applied Energy, Elsevier, vol. 307(C).
    2. Anujin Bayasgalan & Yoo Shin Park & Seak Bai Koh & Sung-Yong Son, 2024. "Comprehensive Review of Building Energy Management Models: Grid-Interactive Efficient Building Perspective," Energies, MDPI, vol. 17(19), pages 1-25, September.
    3. Jumaboev Sherozbek & Jaewoo Park & Mohammad Shaheer Akhtar & O-Bong Yang, 2023. "Transformers-Based Encoder Model for Forecasting Hourly Power Output of Transparent Photovoltaic Module Systems," Energies, MDPI, vol. 16(3), pages 1-11, January.
    4. Feifan Ji & Chenglong Huang & Tong Wang & Yanjun Li & Shuwen Pan, 2024. "Enhanced Thermal Modeling of Electric Vehicle Motors Using a Multihead Attention Mechanism," Energies, MDPI, vol. 17(12), pages 1-17, June.
    5. Hu, Zehuan & Gao, Yuan & Ji, Siyu & Mae, Masayuki & Imaizumi, Taiji, 2024. "Improved multistep ahead photovoltaic power prediction model based on LSTM and self-attention with weather forecast data," Applied Energy, Elsevier, vol. 359(C).
    6. Zheng, Peijun & Zhou, Heng & Liu, Jiang & Nakanishi, Yosuke, 2023. "Interpretable building energy consumption forecasting using spectral clustering algorithm and temporal fusion transformers architecture," Applied Energy, Elsevier, vol. 349(C).
    7. Hanif, M.F. & Mi, J., 2024. "Harnessing AI for solar energy: Emergence of transformer models," Applied Energy, Elsevier, vol. 369(C).
    8. M. Usman Saleem & Mustafa Shakir & M. Rehan Usman & M. Hamza Tahir Bajwa & Noman Shabbir & Payam Shams Ghahfarokhi & Kamran Daniel, 2023. "Integrating Smart Energy Management System with Internet of Things and Cloud Computing for Efficient Demand Side Management in Smart Grids," Energies, MDPI, vol. 16(12), pages 1-21, June.
    9. Lu, Xiangdong & Zhao, Jianhui & Markov, Vladimir & Wu, Tianyu, 2024. "Study on precise fuel injection under multiple injections of high pressure common rail system based on deep learning," Energy, Elsevier, vol. 307(C).
    10. Gonçalves, Juliana E. & Montazeri, Hamid & van Hooff, Twan & Saelens, Dirk, 2021. "Performance of building integrated photovoltaic facades: Impact of exterior convective heat transfer," Applied Energy, Elsevier, vol. 287(C).
    11. Long Li & Shuqi Wang & Shengxi Zhang & Ding Liu & Shengbin Ma, 2023. "The Hydrogen Energy Infrastructure Location Selection Model: A Hybrid Fuzzy Decision-Making Approach," Sustainability, MDPI, vol. 15(13), pages 1-20, June.
    Full references (including those not matched with items on IDEAS)

    Most related items

    These are the items that most often cite the same works as this one and are cited by the same works as this one.
    1. Hu, Zehuan & Gao, Yuan & Sun, Luning & Mae, Masayuki & Imaizumi, Taiji, 2024. "Self-learning dynamic graph neural network with self-attention based on historical data and future data for multi-task multivariate residential air conditioning forecasting," Applied Energy, Elsevier, vol. 364(C).
    2. He, Jiaming & Tan, Qinliang & Lv, Hanyu, 2025. "Data-driven climate resilience assessment for distributed energy systems using diffusion transformer and polynomial expansions," Applied Energy, Elsevier, vol. 380(C).
    3. Abdullah Alghamdi, 2025. "Leveraging Spectral Clustering and Long Short-Term Memory Techniques for Green Hotel Recommendations in Saudi Arabia," Sustainability, MDPI, vol. 17(5), pages 1-28, March.
    4. Chankook Park & Wan Gyu Heo & Myung Eun Lee, 2024. "Study on Consumers’ Perceived Benefits and Risks of Smart Energy System," International Journal of Energy Economics and Policy, Econjournals, vol. 14(3), pages 288-300, May.
    5. Wenli Dong & Lihan Lin, 2023. "Evaluating the Whole-Process Management of Future Communities Based on Integrated Fuzzy Decision Methods," Sustainability, MDPI, vol. 15(23), pages 1-23, November.
    6. Andreas Lenk & Marcus Vogt & Christoph Herrmann, 2024. "An Approach to Predicting Energy Demand Within Automobile Production Using the Temporal Fusion Transformer Model," Energies, MDPI, vol. 18(1), pages 1-34, December.
    7. Gao, Yuan & Hu, Zehuan & Chen, Wei-An & Liu, Mingzhe & Ruan, Yingjun, 2025. "A revolutionary neural network architecture with interpretability and flexibility based on Kolmogorov–Arnold for solar radiation and temperature forecasting," Applied Energy, Elsevier, vol. 378(PA).
    8. Eduardo Luiz Alba & Gilson Adamczuk Oliveira & Matheus Henrique Dal Molin Ribeiro & Érick Oliveira Rodrigues, 2024. "Electricity Consumption Forecasting: An Approach Using Cooperative Ensemble Learning with SHapley Additive exPlanations," Forecasting, MDPI, vol. 6(3), pages 1-25, September.
    9. Hafize Nurgul Durmus Senyapar & Ramazan Bayindir, 2023. "The Research Agenda on Smart Grids: Foresights for Social Acceptance," Energies, MDPI, vol. 16(18), pages 1-31, September.
    10. Liu, Mingzhe & Guo, Mingyue & Fu, Yangyang & O’Neill, Zheng & Gao, Yuan, 2024. "Expert-guided imitation learning for energy management: Evaluating GAIL’s performance in building control applications," Applied Energy, Elsevier, vol. 372(C).
    11. Yanan Xue & Jinliang Yin & Xinhao Hou, 2024. "Short-Term Wind Power Prediction Based on Multi-Feature Domain Learning," Energies, MDPI, vol. 17(13), pages 1-25, July.
    12. Pei, Jingyin & Dong, Yunxuan & Guo, Pinghui & Wu, Thomas & Hu, Jianming, 2024. "A Hybrid Dual Stream ProbSparse Self-Attention Network for spatial–temporal photovoltaic power forecasting," Energy, Elsevier, vol. 305(C).
    13. Mehmet Das & Erhan Arslan & Sule Kaya & Bilal Alatas & Ebru Akpinar & Burcu Özsoy, 2024. "Performance Evaluation of Photovoltaic Panels in Extreme Environments: A Machine Learning Approach on Horseshoe Island, Antarctica," Sustainability, MDPI, vol. 17(1), pages 1-34, December.
    14. Xu Liang & Huifang Kang & Rui Zeng & Yue Pang & Yun Yang & Yunlu Qiu & Yuanxu Tao & Jun Shen, 2024. "Impact of the Structural Parameters on the Performance of a Regenerative-Type Hydrogen Recirculation Blower for Vehicular Proton Exchange Membrane Fuel Cells," Sustainability, MDPI, vol. 16(5), pages 1-28, February.
    15. Wu, Zhuochun & Kang, Jidong & Mosteiro-Romero, Martín & Bartolini, Andrea & Ng, Tsan Sheng & Su, Bin, 2024. "A distributionally robust optimization model for building-integrated photovoltaic system expansion planning under demand and irradiance uncertainties," Applied Energy, Elsevier, vol. 372(C).
    16. Qing Yin & Chunmiao Han & Ailin Li & Xiao Liu & Ying Liu, 2024. "A Review of Research on Building Energy Consumption Prediction Models Based on Artificial Neural Networks," Sustainability, MDPI, vol. 16(17), pages 1-30, September.
    17. Lee, Ruda & Kim, Dongsu & Yoon, Jongho & Kang, Eunho & Cho, Heejin & Kim, Jinhwi, 2024. "Development and calibration of apartment building energy model based on architectural and energy consumption characteristics," Renewable and Sustainable Energy Reviews, Elsevier, vol. 206(C).
    18. Hu, Yusha & Man, Yi, 2023. "Energy consumption and carbon emissions forecasting for industrial processes: Status, challenges and perspectives," Renewable and Sustainable Energy Reviews, Elsevier, vol. 182(C).
    19. Khan, Zulfiqar Ahmad & Khan, Shabbir Ahmad & Hussain, Tanveer & Baik, Sung Wook, 2024. "DSPM: Dual sequence prediction model for efficient energy management in micro-grid," Applied Energy, Elsevier, vol. 356(C).
    20. Gong, Bin & An, Aimin & Shi, Yaoke & Guan, Haijiao & Jia, Wenchao & Yang, Fazhi, 2024. "An interpretable hybrid spatiotemporal fusion method for ultra-short-term photovoltaic power prediction," Energy, Elsevier, vol. 308(C).

    Corrections

    All material on this site has been provided by the respective publishers and authors. You can help correct errors and omissions. When requesting a correction, please mention this item's handle: RePEc:gam:jeners:v:18:y:2025:i:6:p:1468-:d:1613979. See general information about how to correct material in RePEc.

    If you have authored this item and are not yet registered with RePEc, we encourage you to do it here. This allows to link your profile to this item. It also allows you to accept potential citations to this item that we are uncertain about.

    If CitEc recognized a bibliographic reference but did not link an item in RePEc to it, you can help with this form .

    If you know of missing items citing this one, you can help us creating those links by adding the relevant references in the same way as above, for each refering item. If you are a registered author of this item, you may also want to check the "citations" tab in your RePEc Author Service profile, as there may be some citations waiting for confirmation.

    For technical questions regarding this item, or to correct its authors, title, abstract, bibliographic or download information, contact: MDPI Indexing Manager (email available below). General contact details of provider: https://www.mdpi.com .

    Please note that corrections may take a couple of weeks to filter through the various RePEc services.

    IDEAS is a RePEc service. RePEc uses bibliographic data supplied by the respective publishers.