Ensemble Deep Learning with Attention Mechanism and Explainable AI for Enhanced Brain Tumor Classification from MRI Images

  • Krisna Nuresa Qodri Universitas Muhammadiyah Klaten, Klaten, Indonesia
  • Ardiansyah Ardiansyah Universitas Muhammadiyah Klaten, Klaten, Indonesia
  • Nisrina Akbar Rizky Putri Universitas Muhammadiyah Klaten, Klaten, Indonesia
  • Adika Sri Widagdo Universitas Muhammadiyah Klaten, Klaten, Indonesia
  • Fachruddin Edi Nugroho Saputro Universitas Muhammadiyah Klaten, Klaten, Indonesia
Keywords: Attention Mechanism, Brain Tumor, Deep Learning, Ensemble Learning, Explainable AI

Abstract

Brain tumors represent a significant clinical challenge, with accurate classification being essential for treatment planning. Current deep learning approaches face two critical limitations: insufficient robust-ness across diverse imaging conditions and lack of clinical interpretability. Here we present an ensemble deep learning framework integrating three complementary architectures (MobileNetV2, EfficientNetB3, and DenseNet121) with spatial attention mechanisms and explainability features. Using 7,023 MRI images across four diagnostic categories (glioma, meningioma, pituitary tumor, and tumor-absent), our approach achieved 98.47% classification accuracy with balanced performance across all classes (F1-scores: 98.12% for glioma, 97.89% for meningioma, 98.76% for pituitary, 99.21% for tumor-absent cases). The ensemble demonstrated statistically significant improvement over individual models (p < 0.01, McNemar’s test), with gains of 1.24-1.75 percentage points. Integration of Gradient-weighted Class Activation Map-ping provided interpretable visual explanations with activation patterns consistently focusing on tumor regions. The findings demonstrate the potential of combining ensemble learning, attention, and visual explanation for brain tumor classification. However, the results represent internal validation on a single partition of aggregated public datasets and require confirmation through repeated validation and independent clinical evaluation.

References

S. Kim et al., “Global burden of brain and central nervous system cancer in 185 countries, and projections up to 2050: a population-based systematic analysis of GLOBOCAN 2022,” J. Neurooncol., vol. 175, no. 2, pp. 673–685, Nov. 2025, https://doi.org/10.1007/s11060-025-05164-0.

E. G. Van Meir, C. G. Hadjipanayis, A. D. Norden, H. K. Shu, P. Y. Wen, and J. J. Olson, “Exciting New Advances in Neuro-Oncology: The Avenue to a Cure for Malignant Glioma,” CA Cancer J. Clin., vol. 60, no. 3, pp. 166–193, May 2010, https://doi.org/10.3322/caac.20069.

A. M. Eraky, R. T. Beck, R. W. Treffy, D. M. Aaronson, and H. Hedayat, “Role of Advanced MR Imaging in Diagnosis of Neurological Malignancies: Current Status and Future Perspective.,” J. Integr. Neurosci., vol. 22, no. 3, p. 73, May 2023, https://doi.org/10.31083/j.jin2203073.

M. Rizwan, A. Shabbir, A. R. Javed, M. Shabbir, T. Baker, and D. Al-Jumeily Obe, “Brain Tumor and Glioma Grade Classification Using Gaussian Convolutional Neural Network,” IEEE Access, vol. 10, pp. 29731–29740, 2022, https://doi.org/10.1109/ACCESS.2022.3153108.

X. Jiang, Z. Hu, S. Wang, and Y. Zhang, “Deep Learning for Medical Image-Based Cancer Diagnosis,” Cancers (Basel)., vol. 15, no. 14, p. 3608, Jul. 2023, doi: 10.3390/cancers15143608.

D. Shen, G. Wu, and H.-I. Suk, “Deep Learning in Medical Image Analysis,” Annu. Rev. Biomed. Eng., vol. 19, no. 1, pp. 221–248, Jun. 2017, https://doi.org/10.1146/annurev-bioeng-071516-044442.

S. Saeedi, S. Rezayi, H. Keshavarz, and S. R. Niakan Kalhori, “MRI-based brain tumor detection using convolutional deep learning methods and chosen machine learning techniques,” BMC Med. Inform. Decis. Mak., vol. 23, no. 1, p. 16, Jan. 2023, https://doi.org/10.1186/s12911-023-02114-6.

K. Muhammad, S. Khan, N. Kumar, J. Del Ser, and S. Mirjalili, “Vision-based personalized Wireless Capsule Endoscopy for smart healthcare: Taxonomy, literature review, opportunities and challenges,” Future Generation Computer Systems, vol. 113, pp. 266–280, Dec. 2020, https://doi.org/ 10.1016/j.future.2020.06.048.

P. Afshar, A. Mohammadi, and K. N. Plataniotis, “Brain Tumor Type Classification via Capsule Networks,” in 2018 25th IEEE International Conference on Image Processing (ICIP), IEEE, Oct. 2018, pp. 3129–3133. https://doi.org/10.1109/ICIP.2018.8451379.

F. J. Díaz-Pernas, M. Martínez-Zarzuela, M. Antón-Rodríguez, and D. González-Ortega, “A Deep Learning Approach for Brain Tumor Classification and Segmentation Using a Multiscale Convolutional Neural Network,” Healthcare, vol. 9, no. 2, p. 153, Feb. 2021, https://doi.org/ 10.3390/healthcare9020153.

G. S. Tandel, A. Tiwari, O. G. Kakde, N. Gupta, L. Saba, and J. S. Suri, “Role of Ensemble Deep Learning for Brain Tumor Classification in Multiple Magnetic Resonance Imaging Sequence Data,” Diagnostics, vol. 13, no. 3, p. 481, Jan. 2023, https://doi.org/10.3390/diagnostics13030481.

S. M, Mathivanan, and M. A. Shah, “Efficient brain tumor grade classification using ensemble deep learning models,” BMC Med. Imaging, vol. 24, no. 1, p. 297, Nov. 2024, https://doi.org/10.1186/s12880-024-01476-1.

S. M. Lundberg et al., “Explainable machine-learning predictions for the prevention of hypoxaemia during surgery,” Nat. Biomed. Eng., vol. 2, no. 10, pp. 749–760, Oct. 2018, https://doi.org/ 10.1038/s41551-018-0304-0.

A. Holzinger, A. Saranti, C. Molnar, P. Biecek, and W. Samek, “Explainable AI Methods - A Brief Overview,” 2022, pp. 13–38. https://doi.org/10.1007/978-3-031-04083-2_2.

K.-Y. Liu et al., “Majority Voting Ensemble of Deep CNNs for Robust MRI-Based Brain Tumor Classification,” Diagnostics, vol. 15, no. 14, p. 1782, Jul. 2025, https://doi.org/10.3390/diagnostics15141782.

T. Rahman et al., “Reliable Tuberculosis Detection Using Chest X-Ray with Deep Learning, Segmentation and Visualization,” IEEE Access, vol. 8, pp. 191586–191601, 2020, https://doi.org/10.1109/ACCESS.2020.3031384.

J. Hu, L. Shen, S. Albanie, G. Sun, and E. Wu, “Squeeze-and-Excitation Networks,” IEEE Trans. Pattern Anal. Mach. Intell., vol. 42, no. 8, pp. 2011–2023, Aug. 2020,

https://doi.org/ 10.1109/TPAMI.2019.2913372.

R. R. Selvaraju, M. Cogswell, A. Das, R. Vedantam, D. Parikh, and D. Batra, “Grad-CAM: Visual Explanations from Deep Networks via Gradient-Based Localization,” Int. J. Comput. Vis., vol. 128, no. 2, pp. 336–359, Feb. 2020, https://doi.org/10.1007/s11263-019-01228-7.

A. Chattopadhay, A. Sarkar, P. Howlader, and V. N. Balasubramanian, “Grad-CAM++: Generalized Gradient-Based Visual Explanations for Deep Convolutional Networks,” in 2018 IEEE Winter Conference on Applications of Computer Vision (WACV), IEEE, Mar. 2018, pp. 839–847. https://doi.org/10.1109/WACV.2018.00097.

R. A. Zeineldin et al., “Explainability of deep neural networks for MRI analysis of brain tumors,” Int. J. Comput. Assist. Radiol. Surg., vol. 17, no. 9, pp. 1673–1683, Apr. 2022, https://doi.org/10.1007/s11548-022-02619-x.

M. M. Zahoor et al., “Brain Tumor MRI Classification Using a Novel Deep Residual and Regional CNN,” Biomedicines, vol. 12, no. 7, p. 1395, Jun. 2024, https://doi.org/10.3390/biomedicines12071395.

J. Cheng, “Brain tumor dataset,” 2017. https://doi.org/10.6084/m9.figshare.1512427.v5.

S. Bhuvaji, A. Kadam, P. Bhumkar, S. Dedge, and S. Kanchan, “Brain Tumor Classification (MRI),” 2020. https://doi.org/10.34740/KAGGLE/DSV/1183165.

A. Hamada, “Br35H: Brain Tumor Detection 2020,” 2020. Accessed: Jul. 22, 2025. [Online]. Available: https://www.kaggle.com/datasets/ahmedhamada0/brain-tumor-detection

H. Zhang, M. Cisse, Y. N. Dauphin, and D. Lopez-Paz, “mixup: Beyond Empirical Risk Minimization,” Apr. 2018. https://doi.org/10.48550/arXiv.1710.09412

S. Yun, D. Han, S. Chun, S. J. Oh, Y. Yoo, and J. Choe, “CutMix: Regularization Strategy to Train Strong Classifiers With Localizable Features,” in 2019 IEEE/CVF International Conference on Computer Vision (ICCV), IEEE, Oct. 2019, pp. 6022–6031. https://doi.org/10.1109/ICCV.2019.00612.

M. Sandler, A. Howard, M. Zhu, A. Zhmoginov, and L.-C. Chen, “MobileNetV2: Inverted Residuals and Linear Bottlenecks,” in 2018 IEEE/CVF Conference on Computer Vision and Pattern Recognition, IEEE, Jun. 2018, pp. 4510–4520. https://doi.org/10.1109/CVPR.2018.00474.

M. Tan and Q. V. Le, “EfficientNet: Rethinking Model Scaling for Convolutional Neural Networks,” in 36th Int. Conf. Mach. Learn. (ICML), Sep. 2020. https://doi.org/10.48550/arXiv.1905.11946

G. Huang, Z. Liu, L. Van Der Maaten, and K. Q. Weinberger, “Densely Connected Convolutional Networks,” in 2017 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), IEEE, Jul. 2017, pp. 2261–2269. https://doi.org/10.1109/CVPR.2017.243.

S. Woo, J. Park, J.-Y. Lee, and I. S. Kweon, “CBAM: Convolutional Block Attention Module,” in Computer Vision - ECCV 2018, V. Ferrari, M. Hebert, C. Sminchisescu, and Y. Weiss, Eds., Springer International Publishing, 2018, pp. 3–19.

https://doi.org/10.1007/978-3-030-01234-2_1.

I. Loshchilov and F. Hutter, “Decoupled Weight Decay Regularization,” in ICLR 2019, Jan. 2019. https://doi.org/10.48550/arXiv.1711.05101

T.-Y. Lin, P. Goyal, R. Girshick, K. He, and P. Dollar, “Focal Loss for Dense Object Detection,” in 2017 IEEE International Conference on Computer Vision (ICCV), IEEE, Oct. 2017, pp. 2999–3007. https://doi.org/10.1109/ICCV.2017.324.

M. O. Khairandish, M. Sharma, V. Jain, J. M. Chatterjee, and N. Z. Jhanjhi, “A Hybrid CNN-SVM Threshold Segmentation Approach for Tumor Detection and Classification of MRI Brain Images,” IRBM, vol. 43, no. 4, pp. 290–299, Aug. 2022, https://doi.org/10.1016/j.irbm.2021.06.003.

M. I. Sharif, M. A. Khan, M. Alhussein, K. Aurangzeb, and M. Raza, “A decision support system for multimodal brain tumor classification using deep learning,” Complex & Intelligent Systems, vol. 8, no. 4, pp. 3007–3020, Aug. 2022, https://doi.org/10.1007/s40747-021-00321-0.

S. Anjum et al., “Detecting brain tumors using deep learning convolutional neural network with transfer learning approach,” Int. J. Imaging Syst. Technol., vol. 32, no. 1, pp. 307–323, Jan. 2022, https://doi.org/10.1002/ima.22641.

A. H. Khan et al., “Intelligent Model for Brain Tumor Identification Using Deep Learning,” Applied Computational Intelligence and Soft Computing, vol. 2022, pp. 1–10, Jan. 2022, https://doi.org/10.1155/2022/8104054.

T. Rahman et al., “Exploring the effect of image enhancement techniques on COVID-19 detection using chest X-ray images,” Comput. Biol. Med., vol. 132, p. 104319, May 2021, https://doi.org/10.1016/j.compbiomed.2021.104319.

K. H. Ali, “ViT-BT: Improving MRI Brain Tumor Classification Using Vision Transformer with Transfer Learning,” International Journal of Soft Computing and Engineering, vol. 14, no. 4, pp. 16–26, Sep. 2024, https://doi.org/10.35940/ijsce.D3644.14040924.

How to Cite
Qodri, K. N., Ardiansyah, A., Putri, N. A. R., Widagdo, A. S., & Saputro, F. E. N. (2026). Ensemble Deep Learning with Attention Mechanism and Explainable AI for Enhanced Brain Tumor Classification from MRI Images. International Journal of Engineering, Technology and Natural Sciences, 8(1), 80-96. https://doi.org/10.46923/ijets.v8i1.641