Interpretable Deep Learning Model for Tuberculosis Detection Using X-Ray Images

  • Chapter
  • First Online:
Surveillance, Prevention, and Control of Infectious Diseases

Abstract

Tuberculosis (TB) is a worldwide severe health concern that causes numerous deaths yearly. Detecting TB promptly and precisely is crucial for limiting its effects and preventing fatalities. Chest X-ray (CXR) images play a critical role in TB diagnosis, but identifying the disease in its early stages is complex and can result in lengthy and expensive treatments. This study introduces a novel approach for TB detection by implementing a lightweight parallel CNN model (LP-CNN) with fewer parameters and computational requirements. This model boasts exceptional efficiency in distinguishing between normal, non-TB (bacterial and viral pneumonia), and TB cases. To discover the model’s comprehension, we employ the Shapley Additive Explanations (SHAP) direction to clarify the prediction process. The transfer learning (TL) models evaluated include DenseNet169, DenseNet201, InceptionResNetV2, VGG19, and Xception, and their performances are evaluated based on accuracy, precision, recall, F1-score, and AUC metrics. The LP-CNN model shows outstanding performance, achieving high scores in precision (99 ± 1.36E-16%), recall (98.33 ± 0.0115%), F1-score (99.33 ± 0.0057%), accuracy (99.46%), and AUC (99.93%). It is worth noting that LP-CNN has a compact design, consisting of only 1.658 million parameters, eight convolutional layers (CL), and a size of 19.1 MB. The results of this research provide an effective way to analyze chest X-rays to detect tuberculosis quickly and accurately. With the higher accuracy of the LP-CNN model and the interpretability of SHAP, there is significant potential to improve TB diagnosis and thereby reduce consequences and disease spread. This outcome highlights the revolutionary effect of AI-driven diagnostics in practical tuberculosis analysis, providing a potential step toward efficient disease treatment without radiologists.

This is a preview of subscription content, log in via an institution to check access.

Access this chapter

Subscribe and save

Springer+ Basic
EUR 32.99 /Month
  • Get 10 units per month
  • Download Article/Chapter or Ebook
  • 1 Unit = 1 Article or 1 Chapter
  • Cancel anytime
Subscribe now

Buy Now

Chapter
USD 29.95
Price excludes VAT (USA)
  • Available as PDF
  • Read on any device
  • Instant download
  • Own it forever
eBook
USD 139.00
Price excludes VAT (USA)
  • Available as EPUB and PDF
  • Read on any device
  • Instant download
  • Own it forever
Hardcover Book
USD 149.99
Price excludes VAT (USA)
  • Durable hardcover edition
  • Dispatched in 3 to 5 business days
  • Free ship** worldwide - see info

Tax calculation will be finalised at checkout

Purchases are for personal use only

Institutional subscriptions

References

  1. Tuberculosis, (n.d.). https://www.who.int/news-room/fact-sheets/detail/tuberculosis. Accessed 14 Aug 2023

  2. S.K. Sharma, A. Mohan, Tuberculosis: From an incurable scourge to a curable disease-journey over a millennium. Indian J. Med. Res. 137, 455 (2013)

    Google Scholar 

  3. C. Silverman, An appraisal of the contribution of mass radiography in the discovery of pulmonary tuberculosis. Am. Rev. Tuberc. 60, 466–482 (1949)

    Google Scholar 

  4. A.H. van’t Hoog, H.K. Meme, K.F. Laserson, J.A. Agaya, B.G. Muchiri, W.A. Githui, L.O. Odeny, B.J. Marston, M.W. Borgdorff, Screening strategies for tuberculosis prevalence surveys: The value of chest radiography and symptoms. PLoS One 7, e38691 (2012)

    Article  Google Scholar 

  5. A.P. Brady, Error and discrepancy in radiology: Inevitable or avoidable? Insights Imaging 8, 171–182 (2017)

    Article  Google Scholar 

  6. A.J. Degnan, E.H. Ghobadi, P. Hardy, E. Krupinski, E.P. Scali, L. Stratchko, A. Ulano, E. Walker, A.P. Wasnik, W.F. Auffermann, Perceptual and interpretive error in diagnostic radiology—Causes and potential solutions. Acad. Radiol. 26, 833–845 (2019)

    Article  Google Scholar 

  7. H. Greenspan, B. Van Ginneken, R.M. Summers, Guest editorial deep learning in medical imaging: Overview and future promise of an exciting new technique. IEEE Trans. Med. Imaging 35, 1153–1159 (2016)

    Article  Google Scholar 

  8. V. Acharya, G. Dhiman, K. Prakasha, P. Bahadur, A. Choraria, M. Sushobhitha, J. Sowjanya, S. Prabhu, K. Chadaga, W. Viriyasitavat, S. Kautish, AI-assisted tuberculosis detection and classification from chest X-rays using a deep learning normalization-free network model. Comput. Intell. Neurosci. 2022, 2399428 (2022). https://doi.org/10.1155/2022/2399428

    Article  Google Scholar 

  9. M.E.H. Chowdhury, T. Rahman, A. Khandakar, S. Al-Madeed, S.M. Zughaier, S.A.R. Doi, H. Hassen, M.T. Islam, An early warning tool for predicting mortality risk of COVID-19 patients using machine learning. Cogn. Comput. (2021). https://doi.org/10.1007/s12559-020-09812-7

  10. A. Iqbal, M. Usman, Z. Ahmed, An efficient deep learning-based framework for tuberculosis detection using chest X-ray images. Tuberculosis 136, 102234 (2022). https://doi.org/10.1016/j.tube.2022.102234

    Article  Google Scholar 

  11. M.E.H. Chowdhury, T. Rahman, A. Khandakar, R. Mazhar, M.A. Kadir, Z.B. Mahbub, K.R. Islam, M.S. Khan, A. Iqbal, N.A. Emadi, M.B.I. Reaz, M.T. Islam, Can AI help in screening viral and COVID-19 pneumonia? IEEE Access 8, 132665–132676 (2020). https://doi.org/10.1109/ACCESS.2020.3010287

    Article  Google Scholar 

  12. M. Nahiduzzaman, M.R. Islam, R. Hassan, ChestX-Ray6: Prediction of multiple diseases including COVID-19 from chest X-ray images using convolutional neural network. Expert Syst. Appl. 211, 118576 (2023). https://doi.org/10.1016/j.eswa.2022.118576

    Article  Google Scholar 

  13. M.R. Islam, M. Nahiduzzaman, Complex features extraction with deep learning model for the detection of COVID19 from CT scan images using ensemble based machine learning approach. Expert Syst. Appl. 195, 116554 (2022). https://doi.org/10.1016/j.eswa.2022.116554

    Article  Google Scholar 

  14. M. Yamaç, M. Ahishali, A. Degerli, S. Kiranyaz, M.E.H. Chowdhury, M. Gabbouj, Convolutional sparse support estimator-based COVID-19 recognition from X-ray images. IEEE Trans. Neural Netw. Learn. Syst. 32, 1810–1820 (2021). https://doi.org/10.1109/TNNLS.2021.3070467

    Article  Google Scholar 

  15. A.M. Tahir, M.E.H. Chowdhury, A. Khandakar, T. Rahman, Y. Qiblawey, U. Khurshid, S. Kiranyaz, N. Ibtehaz, M.S. Rahman, S. Al-Maadeed, S. Mahmud, M. Ezeddin, K. Hameed, T. Hamid, COVID-19 infection localization and severity grading from chest X-ray images. Comput. Biol. Med. 139, 105002 (2021). https://doi.org/10.1016/j.compbiomed.2021.105002

    Article  Google Scholar 

  16. A.M. Ismael, A. Şengür, Deep learning approaches for COVID-19 detection based on chest X-ray images. Expert Syst. Appl. 164, 114054 (2021). https://doi.org/10.1016/J.ESWA.2020.114054

    Article  Google Scholar 

  17. S. Kazemzadeh, J. Yu, S. Jamshy, R. Pilgrim, Z. Nabulsi, C. Chen, N. Beladia, C. Lau, S.M. McKinney, T. Hughes, A.P. Kiraly, S.R. Kalidindi, M. Muyoyeta, J. Malemela, T. Shih, G.S. Corrado, L. Peng, K. Chou, P.-H.C. Chen, Y. Liu, K. Eswaran, D. Tse, S. Shetty, S. Prabhakara, Deep learning detection of active pulmonary tuberculosis at chest radiography matched the clinical performance of radiologists. Radiology 306, 124–137 (2022). https://doi.org/10.1148/radiol.212213

    Article  Google Scholar 

  18. A.M. Tahir, Y. Qiblawey, A. Khandakar, T. Rahman, U. Khurshid, F. Musharavati, M.T. Islam, S. Kiranyaz, S. Al-Maadeed, M.E.H. Chowdhury, Deep learning for reliable classification of COVID-19, MERS, and SARS from chest X-ray images. Cogn. Comput., 1–21 (2022)

    Google Scholar 

  19. Y. Qiblawey, A. Tahir, M.E.H. Chowdhury, A. Khandakar, S. Kiranyaz, T. Rahman, N. Ibtehaz, S. Mahmud, S.A. Maadeed, F. Musharavati, M.A. Ayari, Detection and severity classification of COVID-19 in CT images using deep learning. Diagnostics 11 (2021). https://doi.org/10.3390/diagnostics11050893

  20. M. Nahiduzzaman, M.O. Faruq Goni, M. Robiul Islam, A. Sayeed, M. Shamim Anower, M. Ahsan, J. Haider, M. Kowalski, Detection of various lung diseases including COVID-19 using extreme learning machine algorithm based on the features extracted from a lightweight CNN architecture. Biocybern. Biomed. Eng. 43, 528–550 (2023). https://doi.org/10.1016/j.bbe.2023.06.003

    Article  Google Scholar 

  21. T. Rahman, A. Khandakar, Y. Qiblawey, A. Tahir, S. Kiranyaz, S. Bin Abul Kashem, M.T. Islam, S. Al Maadeed, S.M. Zughaier, M.S. Khan, M.E.H. Chowdhury, Exploring the effect of image enhancement techniques on COVID-19 detection using chest X-ray images. Comput. Biol. Med. 132, 104319 (2021). https://doi.org/10.1016/j.compbiomed.2021.104319

    Article  Google Scholar 

  22. S. Hansun, A. Argha, S.-T. Liaw, B.G. Celler, G.B. Marks, Machine and deep learning for tuberculosis detection on chest X-rays: Systematic literature review. J. Med. Internet Res. 25, e43154 (2023). https://doi.org/10.2196/43154

    Article  Google Scholar 

  23. O. Sarkar, M.R. Islam, M.K. Syfullah, M.T. Islam, M.F. Ahamed, M. Ahsan, J. Haider, Multi-scale CNN: An explainable AI-integrated unique deep learning framework for lung-affected disease classification. Technologies 11 (2023). https://doi.org/10.3390/technologies11050134

  24. T. Rahman, A. Khandakar, M.A. Kadir, K.R. Islam, K.F. Islam, R. Mazhar, T. Hamid, M.T. Islam, S. Kashem, Z.B. Mahbub, M.A. Ayari, M.E.H. Chowdhury, Reliable tuberculosis detection using chest X-ray with deep learning, segmentation and visualization. IEEE Access 8, 191586–191601 (2020). https://doi.org/10.1109/ACCESS.2020.3031384

    Article  Google Scholar 

  25. T. Rahman, M.E.H. Chowdhury, A. Khandakar, K.R. Islam, K.F. Islam, Z.B. Mahbub, M.A. Kadir, S. Kashem, Transfer learning with deep convolutional neural network (CNN) for pneumonia detection using chest X-ray. Appl. Sci. 10 (2020). https://doi.org/10.3390/app10093233

  26. S.I. Nafisah, G. Muhammad, Tuberculosis detection in chest radiograph using convolutional neural network architecture and explainable artificial intelligence. Neural Comput. & Applic. (2022). https://doi.org/10.1007/s00521-022-07258-6

  27. J. Melendez, B. Van Ginneken, P. Maduskar, R.H.H.M. Philipsen, K. Reither, M. Breuninger, I.M.O. Adetifa, R. Maane, H. Ayles, C.I. Sánchez, A novel multiple-instance learning-based approach to computer-aided detection of tuberculosis on chest X-rays. IEEE Trans. Med. Imaging 34, 179–192 (2014)

    Article  Google Scholar 

  28. S. Jaeger, A. Karargyris, S. Antani, G. Thoma, Detecting tuberculosis in radiographs using combined lung masks, in 2012 Annual International Conference of the IEEE Engineering in Medicine and Biology Society, (2012), pp. 4978–4981

    Chapter  Google Scholar 

  29. B. Van Ginneken, S. Katsuragawa, B.M. ter Haar Romeny, K. Doi, M.A. Viergever, Automatic detection of abnormalities in chest radiographs using local texture analysis. IEEE Trans. Med. Imaging 21, 139–149 (2002)

    Article  Google Scholar 

  30. H. Das, A. Nath, An efficient detection of tuberculosis from chest X-rays. Int. J. Adv. Res. Comput. Sci. Manag. Stud. 3, 149–154 (2015)

    Google Scholar 

  31. T. Nishtar, S. Burki, F.S. Ahmad, T. Ahmad, Diagnostic accuracy of computer aided reading of chest x-ray in screening for pulmonary tuberculosis in comparison with Gene-Xpert. Pakistan J. Med. Sci. 38, 62–68 (2022). https://doi.org/10.12669/pjms.38.1.4531

    Article  Google Scholar 

  32. N. Singh, S. Hamde, Tuberculosis detection using shape and texture features of chest X-rays, in Innovations in Electronics and Communication Engineering Proceedings 7th ICIECE 2018, (2019), pp. 43–50

    Google Scholar 

  33. A. Hernández, Á. Panizo, D. Camacho, An ensemble algorithm based on deep learning for tuberculosis classification, in Intelligent Data Engineering and Automated Learning—IDEAL 2019, 20th International Conference, Manchester, UK, November 14–16, 2019, Proceedings, Part I 20, (2019), pp. 145–154

    Google Scholar 

  34. U.K. Lopes, J.F. Valiati, Pre-trained convolutional neural networks as feature extractors for tuberculosis detection. Comput. Biol. Med. 89, 135–143 (2017)

    Article  Google Scholar 

  35. M. Ahsan, R. Gomes, A. Denton, Application of a convolutional neural network using transfer learning for tuberculosis detection, in 2019 IEEE International Conference on Electro Information Technology (EIT), (2019), pp. 427–433

    Chapter  Google Scholar 

  36. O. Yadav, K. Passi, C.K. Jain, Using deep learning to classify X-ray images of potential tuberculosis patients, in 2018 IEEE International Conference on Bioinformatics and Biomedicine (BIBM), (2018), pp. 2368–2375

    Chapter  Google Scholar 

  37. A. Abbas, M.M. Abdelsamea, M.M. Gaber, Detrac: Transfer learning of class decomposed medical images in convolutional neural networks. IEEE Access 8, 74901–74913 (2020)

    Article  Google Scholar 

  38. R.-I. Chang, Y.-H. Chiu, J.-W. Lin, Two-stage classification of tuberculosis culture diagnosis using convolutional neural network with transfer learning. J. Supercomput. 76, 8641–8656 (2020)

    Article  Google Scholar 

  39. F. Pasa, V. Golkov, F. Pfeiffer, D. Cremers, D. Pfeiffer, Efficient deep network architectures for fast chest X-ray tuberculosis screening and visualization. Sci. Rep. 9, 6268 (2019)

    Article  Google Scholar 

  40. Q.H. Nguyen, B.P. Nguyen, S.D. Dao, B. Unnikrishnan, R. Dhingra, S.R. Ravichandran, S. Satpathy, P.N. Raja, M.C.H. Chua, Deep learning models for tuberculosis detection from chest X-ray images, in 2019 26th International Conference on Telecommunications (ICT), (2019), pp. 381–385

    Chapter  Google Scholar 

  41. A. Rosenthal, A. Gabrielian, E. Engle, D.E. Hurt, S. Alexandru, V. Crudu, E. Sergueev, V. Kirichenko, V. Lapitskii, E. Snezhko, V. Kovalev, A. Astrovko, A. Skrahina, J. Taaffe, M. Harris, A. Long, K. Wollenberg, I. Akhundova, S. Ismayilova, A. Skrahin, E. Mammadbayov, H. Gadirova, R. Abuzarov, M. Seyfaddinova, Z. Avaliani, I. Strambu, D. Zaharia, A. Muntean, E. Ghita, M. Bogdan, R. Mindru, V. Spinu, A. Sora, C. Ene, S. Vashakidze, N. Shubladze, U. Nanava, A. Tuzikov, M. Tartakovsky, The TB portals: An open-access, web-based platform for global drug-resistant- tuberculosis data sharing and analysis. J. Clin. Microbiol. 55, 3267–3282 (2017). https://doi.org/10.1128/JCM.01013-17

    Article  Google Scholar 

  42. D.S. Kermany, M. Goldbaum, W. Cai, C.C.S. Valentim, H. Liang, S.L. Baxter, A. McKeown, G. Yang, X. Wu, F. Yan, J. Dong, M.K. Prasadha, J. Pei, M. Ting, J. Zhu, C. Li, S. Hewett, J. Dong, I. Ziyar, A. Shi, R. Zhang, L. Zheng, R. Hou, W. Shi, X. Fu, Y. Duan, V.A.N. Huu, C. Wen, E.D. Zhang, C.L. Zhang, O. Li, X. Wang, M.A. Singer, X. Sun, J. Xu, A. Tafreshi, M.A. Lewis, H. **a, K. Zhang, Identifying medical diagnoses and treatable diseases by image-based deep learning. Cell 172, 1122–1131.e9 (2018). https://doi.org/10.1016/j.cell.2018.02.010

    Article  Google Scholar 

  43. K. Koonsanit, S. Thongvigitmanee, N. Pongnapang, P. Thajchayapong, Image enhancement on digital x-ray images using N-CLAHE, in 2017 10th Biomedical Engineering International Conference (BMEiCON), (2017), pp. 1–4. https://doi.org/10.1109/BMEiCON.2017.8229130

    Chapter  Google Scholar 

  44. C. Szegedy, W. Liu, Y. Jia, P. Sermanet, S. Reed, D. Anguelov, D. Erhan, V. Vanhoucke, A. Rabinovich, Going deeper with convolutions, in Proceedings of the 2015 IEEE Conference on Computer Vision and Pattern Recognition (CVPR), (2015), pp. 1–9

    Google Scholar 

  45. M. Nahiduzzaman, M. Robiul Islam, M. Omaer Faruq Goni, M. Shamim Anower, M. Ahsan, J. Haider, M. Kowalski, Diabetic retinopathy identification using parallel convolutional neural network based feature extractor and ELM classifier. Expert Syst. Appl. 217, 119557 (2023). https://doi.org/10.1016/j.eswa.2023.119557

    Article  Google Scholar 

  46. M. Nahiduzzaman, M.O.F. Goni, R. Hassan, M.R. Islam, M.K. Syfullah, S.M. Shahriar, M.S. Anower, M. Ahsan, J. Haider, M. Kowalski, Parallel CNN-ELM: A multiclass classification of chest X-ray images to identify seventeen lung diseases including COVID-19. Expert Syst. Appl. 229, 120528 (2023). https://doi.org/10.1016/j.eswa.2023.120528

    Article  Google Scholar 

  47. A. Krizhevsky, I. Sutskever, G.E. Hinton, ImageNet classification with deep convolutional neural networks. Commun. ACM 60, 84–90 (2017). https://doi.org/10.1145/3065386

    Article  Google Scholar 

  48. R. Tri Wahyuningrum, A. Kusumaningsih, W. Putra Rajeb, I.K. Eddy Purnama, Classification of corn leaf disease using the optimized DenseNet-169 model, in Proceedings of the 2021 the 9th International Conference on Information Technology: IoT and Smart City, (2021), pp. 67–73

    Google Scholar 

  49. C. Zhao, R. Shuai, L. Ma, W. Liu, D. Hu, M. Wu, Dermoscopy image classification based on StyleGAN and DenseNet201. IEEE Access 9, 8659–8679 (2021)

    Article  Google Scholar 

  50. Y. Bhatia, A. Bajpayee, D. Raghuvanshi, H. Mittal, Image captioning using Google’s inception-resnet-v2 and recurrent neural network, in 2019 Twelfth International Conference on Contemporary Computing (IC3), (2019), pp. 1–6

    Google Scholar 

  51. T.R.G.V. Sudha, A convolutional neural network classifier VGG-19 architecture for lesion detection and grading in diabetic retinopathy based on deep learning. Comput. Mater. Contin. 66, 827–842 (2021). https://doi.org/10.32604/cmc.2020.012008

    Article  Google Scholar 

  52. F. Chollet, Xception: Deep learning with depthwise separable convolutions, in Proceedings of the IEEE Conference on Computer Vision and Pattern Recognition (CVPR), (Institute of Electrical and Electronics Engineers Inc, 2017), pp. 1251–1258. https://doi.org/10.1109/CVPR.2017.195

    Chapter  Google Scholar 

  53. S. Jaeger, O.H. Juarez-Espinosa, S. Candemir, M. Poostchi, F. Yang, L. Kim, M. Ding, L.R. Folio, S. Antani, A. Gabrielian, Others, detecting drug-resistant tuberculosis in chest radiographs. Int. J. Comput. Assist. Radiol. Surg. 13, 1915–1925 (2018)

    Article  Google Scholar 

  54. S.S. Meraj, R. Yaakob, A. Azman, S. Rum, A. Shahrel, A. Nazri, N.F. Zakaria, Detection of pulmonary tuberculosis manifestation in chest X-rays using different convolutional neural network (CNN) models. Int. J. Eng. Adv. Technol. (IJEAT) 9, 2270–2275 (2019)

    Article  Google Scholar 

  55. Y.H. Bhosale, K.S. Patnaik, IoT deployable lightweight deep learning application for COVID-19 detection with lung diseases using RaspberryPi, in 2022 International Conference on IoT and Blockchain Technology (ICIBT), (2022), pp. 1–6

    Google Scholar 

  56. F. Yang, H. Yu, K. Kantipudi, M. Karki, Y.M. Kassim, A. Rosenthal, D.E. Hurt, Z. Yaniv, S. Jaeger, Differentiating between drug-sensitive and drug-resistant tuberculosis with machine learning for clinical and radiological features. Quant. Imaging Med. Surg. 12, 675–687 (2022). https://doi.org/10.21037/qims-21-290

    Article  Google Scholar 

Download references

Author information

Authors and Affiliations

Authors

Corresponding author

Correspondence to Muhammad E. H. Chowdhury .

Editor information

Editors and Affiliations

Rights and permissions

Reprints and permissions

Copyright information

© 2024 The Author(s), under exclusive license to Springer Nature Switzerland AG

About this chapter

Check for updates. Verify currency and authenticity via CrossMark

Cite this chapter

Ahamed, M.F. et al. (2024). Interpretable Deep Learning Model for Tuberculosis Detection Using X-Ray Images. In: Chowdhury, M.E.H., Kiranyaz, S. (eds) Surveillance, Prevention, and Control of Infectious Diseases. Springer, Cham. https://doi.org/10.1007/978-3-031-59967-5_8

Download citation

  • DOI: https://doi.org/10.1007/978-3-031-59967-5_8

  • Published:

  • Publisher Name: Springer, Cham

  • Print ISBN: 978-3-031-59966-8

  • Online ISBN: 978-3-031-59967-5

  • eBook Packages: Computer ScienceComputer Science (R0)

Publish with us

Policies and ethics

Navigation