Research Article Volume 5 Issue 8

Study of Vision Transformers for Covid-19 Detection from Chest X-rays

Sandeep Angara* and Sharath Thirunagaru

Department of Computer Sciences, USA

*Corresponding Author: Sandeep Angara, Department of Computer Sciences, USA

Received: July 06, 2023; Published: July 21, 2023


The COVID-19 pandemic has led to a global health crisis, highlighting the need for rapid and accurate virus detection. This research paper examines transfer learning with vision transformers for COVID-19 detection, known for its excellent performance in image recognition tasks. We leverage the capability of Vision Transformers to capture global context and learn complex patterns from chest X-ray images. In this work, we explored the recent state-of-art transformer models to detect Covid-19 using CXR images such as vision transformer (ViT), Swin-transformer, Max vision transformer (MViT), and Pyramid Vision transformer (PVT). Through the utilization of transfer learning with IMAGENET weights, the models achieved an impressive accuracy range of 98.75% to 99.5%. Our experiments demonstrate that Vision Transformers achieve state-ofthe-art performance in COVID-19 detection, outperforming traditional methods and even Convolutional Neural Networks (CNNs). The results highlight the potential of Vision Transformers as a powerful tool for COVID-19 detection, with implications for improving the efficiency and accuracy of screening and diagnosis in clinical settings.

Keywords: Vision Transformers; Swin-Transformers; Covid-19; Chest X-rays


  1. C Huang., et al. “Clinical features of patients infected with 2019 novel coronavirus in Wuhan, China”. The Lancet10223 (2020).
  2. H Guo., et al. “The impact of the COVID-19 epidemic on the utilization of emergency dental services”. Journal of Dental Sciences 4 (2020).
  3. T Struyf., et al. “Signs and symptoms to determine if a patient presenting in primary care or hospital outpatient settings has COVID-19”. Cochrane Database of Systematic Reviews2 (2021).
  4. BD Kevadiya., et al. “Diagnostics for SARS-CoV-2 infections”. Nature Materials5 (2021).
  5. G Rong., et al. “COVID-19 Diagnostic Methods and Detection Techniques”. in Encyclopedia of Sensors and Biosensors (2023).
  6. J Dinga., et al. “WITHDRAWN: Experience on radiological examinations and infection prevention for COVID-19 in radiology department”. Radiology of Infectious Diseases (2020).
  7. MY Ng., et al. “Imaging profile of the covid-19 infection: Radiologic findings and literature review”. Radiology: Cardiothoracic Imaging 1 (2020).
  8. LJM Kroft., et al. “Added value of ultra-low-dose computed tomography, dose equivalent to chest x-ray radiography, for diagnosing chest pathology”. Journal of Thoracic Imaging 3 (2019).
  9. IU Khan and N Aslam. “A deep-learning-based framework for automated diagnosis of COVID-19 using X-ray images”. Information (Switzerland)9 (2020).
  10. M Z Islam., et al. “A combined deep CNNLSTM network for the detection of novel coronavirus (COVID-19) using X-ray images”. Informatics in Medicine Unlocked 20 (2020).
  11. P K Sethy., et al. “Computer aid screening of COVID-19 using X-ray and CT scan images: An inner comparison”. Journal of X-Ray Science and Technology 2 (2021).
  12. P K Chaudhary and R B Pachori. “FBSED based automatic diagnosis of COVID-19 using X-ray and CT images”. Computers in Biology and Medicine 134 (2021).
  13. A Narin., et al. “Automatic detection of coronavirus disease (COVID-19) using X-ray images and deep convolutional neural networks”. Pattern Analysis and Applications3 (2021).
  14. Prof NP Tembhare., et al. “Chest X-ray Analysis using Deep Learning”. International Journal for Research in Applied Science and Engineering Technology 1 (2023).
  15. F Ślazyk., et al. “CXR-FL: Deep Learning-Based Chest X-ray Image Analysis Using Federated Learning”. in Lecture Notes in Computer Science (including subseries Lecture Notes in Artificial Intelligence and Lecture Notes in Bioinformatics) (2022).
  16. E Çallı., et al. “Deep learning for chest X-ray analysis: A survey”. Medical Image Analysis 72 (2021).
  17. J Feng and J Jiang. “Deep Learning-Based Chest CT Image Features in Diagnosis of Lung Cancer”. Computational and Mathematical Methods in Medicine 2022, (2022).
  18. C Yang., et al. “Deep learning in CT image segmentation of cervical cancer: a systematic review and meta-analysis”. Radiation Oncology1 (2022).
  19. X Fan., et al. “Deep Learning on MRI Images for Diagnosis of Lung Cancer Spinal Bone Metastasis”. Contrast Media and Molecular Imaging 2021 (2021).
  20. W Shao., et al. “ProsRegNet: A deep learning framework for registration of MRI and histopathology images of the prostate”. Medical Image Analysis 68 (2021).
  21. MA Naser and M J Deen. “Brain tumor segmentation and grading of lower-grade glioma using deep learning in MRI images”. Computers in Biology and Medicine 121 (2020).
  22. J Liu., et al. “Applications of deep learning to MRI Images: A survey”. Big Data Mining and Analytics1 (2018).
  23. T Imaizumi., et al. “Deep learning based 3-dimensional liver motion estimation using 2-dimensional ultrasound images”. in 2019 IEEE International Conference on Cyborg and Bionic Systems, CBS 2019, (2019).
  24. A Negi., et al. “RDA-UNET-WGAN: An Accurate Breast Ultrasound Lesion Segmentation Using Wasserstein Generative Adversarial Networks”. The Arabian Journal for Science and Engineering 8 (2020).
  25. L Wang., et al. “COVID-Net: a tailored deep convolutional neural network design for detection of COVID-19 cases from chest X-ray images”. Scientific Report1 (2020).
  26. N Das N., et al. “Automated Deep Transfer Learning-Based Approach for Detection of COVID-19 Infection in Chest X-rays”. Irbm (2020).
  27. K S Krishnan and K S Krishnan. “Vision Transformer based COVID-19 Detection using Chest X-rays”. in Proceedings of IEEE International Conference on Signal Processing, Computing and Control, (2021).
  28. S Guefrechi., et al. “Deep learning based detection of COVID-19 from chest X-ray images”. Multimedia Tools and Applications 21–23 (2021).
  29. K Simonyan and A Zisserman. “Very deep convolutional networks for large-scale image recognition”. in 3rd International Conference on Learning Representations, ICLR 2015 - Conference Track Proceedings, (2015).
  30. K He., et al. “Deep residual learning for image recognition”. in Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition, (2016).
  31. C Szegedy., et al. “Rethinking the Inception Architecture for Computer Vision”. in Proceedings of the IEEE Computer Society Conference on Computer Vision and Pattern Recognition (2016).
  32. M Pavlova., et al. “COVID-Net CXR-2: An Enhanced Deep Convolutional Neural Network Design for Detection of COVID-19 Cases From Chest X-ray Images”. Frontiers in Medicine (Lausanne) 9 (2022).
  33. G Li., et al. “COVID-19 Detection Based on Self-Supervised Transfer Learning Using Chest X-Ray Images”. Dec. (2022).
  34. J Park., et al. “A Deep Learning Model with Self Supervised Learning and Attention Mechanism for COVID-19 Diagnosis Using Chest X-ray Images”. Electronics (Basel)16 (1996): 2021.
  35. D Shome., et al. “Covid-transformer: Interpretable covid-19 detection using vision transformer for healthcare”. International Journal of Environmental Research and Public Health 21 (2021).
  36. SM Anwar., et al. “SS-CXR: Multitask Representation Learning using Self Supervised Pre-training from Chest X-Rays”. Nov. (2022).
  37. A Dosovitskiy., et al. “An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale”. Oct. (2020).
  38. Z Liu., et al. “Swin Transformer: Hierarchical Vision Transformer using Shifted Windows”. Mar. (2021).
  39. H Fan., et al. “Multiscale Vision Transformers”. Apr. (2021).
  40. W Wang., et al. “PVT v2: Improved Baselines with Pyramid Vision Transformer”. Jun. (2021).
  41. M Pavlova., et al. “COVIDx CXR-3: A Large-Scale, Open-Source Benchmark Dataset of Chest X-ray Images for Computer-Aided COVID-19 Diagnostics”. Jun. (2022).
  42. A Vaswani., et al. “Attention Is All You Need”. Jun. (2017).
  43. F Shamshad., et al. “Transformers in Medical Imaging: A Survey”. Jan. (2022).
  44. S Angara., et al. “An Empirical Study of Vision Transformers for Cervical Precancer Detection”. in Communications in Computer and Information Science, (2022).
  45. ZR Murphy., et al. “Visual Transformers and Convolutional Neural Networks for Disease Classification on Radiographs: A Comparison of Performance, Sample Efficiency, and Hidden Stratification”. Radiology: Artificial Intelligence6 (2022).
  46. Z Tu., et al. “MaxViT: Multi-Axis Vision Transformer”. Apr. (2022).
  47. W Wang., et al. “Pyramid Vision Transformer: A Versatile Backbone for Dense Prediction without Convolutions”. Feb. (2021).
  48. , et al. “ImageNet Large Scale Visual Recognition Challenge”. Sep. (2014).
  49. DP Kingma and J Ba. “Adam: A Method for Stochastic Optimization”. (2014).
  50. I Loshchilov and F Hutter. “SGDR: Stochastic Gradient Descent with Warm Restarts”. (2016).
  51. R Wightman., et al. “rwightman/pytorch-image-models: v0.8.10dev0 Release”. (2023).
  52. H Aboutalebi., et al. “MEDUSA: Multi-scale Encoder-Decoder SelfAttention Deep Neural Network Architecture for Medical Image Analysis”. (2021).


Citation: Sandeep Angara and Sharath Thirunagaru. “Study of Vision Transformers for Covid-19 Detection from Chest X-rays".Acta Scientific Computer Sciences 5.8 (2023): 17-25.


Copyright: © 2023 Sandeep Angara and Sharath Thirunagaru. This is an open-access article distributed under the terms of the Creative Commons Attribution License, which permits unrestricted use, distribution, and reproduction in any medium, provided the original author and source are credited.


Acceptance rate35%
Acceptance to publication20-30 days

Indexed In

News and Events

  • Certification for Review
    Acta Scientific certifies the Editors/reviewers for their review done towards the assigned articles of the respective journals.
  • Submission Timeline for Upcoming Issue
    The last date for submission of articles for regular Issues is July 10, 2024.
  • Publication Certificate
    Authors will be issued a "Publication Certificate" as a mark of appreciation for publishing their work.
  • Best Article of the Issue
    The Editors will elect one Best Article after each issue release. The authors of this article will be provided with a certificate of "Best Article of the Issue"
  • Welcoming Article Submission
    Acta Scientific delightfully welcomes active researchers for submission of articles towards the upcoming issue of respective journals.

Contact US