AI for Good: CNN for COVID-19 Detection, Diagnosis, and Personalized Treatment
Written by Muhammad Azeem1, Shumaila Javaid2, Hamza Fahim2, and Nasir Saeed3
The coronavirus disease (COVID-19) was first identified in Wuhan, China, in 2019. It has since been spreading across the entire world and affecting both people’s daily lives and the global economy. According to the latest report of the World Health Organization (WHO), COVID-19 has infected more than 80 million people and has caused 1 million deaths around the globe. The COVID-19 pandemic has also exposed the vulnerability of current public health systems.
Scientific communities have put considerable efforts into finding the cure for this life-threatening disease. So far, social distancing is considered as one of the most effective ways of containing its spread. Besides, timely detection has crucial importance for affected patient isolation and treatment to mitigate the spread of COVID-19. Therefore, substantial efforts are made toward advancing screening and detection methods for fast and accurate detection of COVID-19.
Currently, the most widely adopted screening method for COVID-19 detection is polymerase chain reaction (PCR) testing, which can detect the presence of SARS-CoV-2 pathogen from respiratory fluid samples. While PCR testing is known to exhibit high sensitivity, it requires an extended time to yield a test result and entails a complicated manual process. An alternative screening process that is less commonly used is radiography examination, where a radiologist analyzes chest radiography images, like X-rays or computed tomography (CT), to look at the pictorial gauges related to SARS-CoV-2 viral infection. Since diagnostic communities can observe abnormalities in the chest, specifically in the lungs of COVID-19 patients, it is suggested that radiography examination can be used as a primary tool for detecting COVID-19 , especially under the current epidemic situation. Therefore, computer-aided diagnostic systems can help radiologists examine the X-ray or CT images quickly and accurately to spot COVID-19. However, identifying COVID-19 from the chest X-beam pictures is a difficult task – compared to PCR testing – that requires experienced radiologists and advanced methods for accurate diagnosis.
Figure 1: AI Applications in Healthcare
Therefore, digital technologies, especially artificial intelligence (AI), can play a crucial role in the accurate detection of COVID-19 [2-4]. In these challenging times, when the COVID-19 has jeopardized the ability to provide essential medical care due to limitation of healthcare resources, AI-based diagnostic techniques can improve diagnostic accuracy thereby enhancing the efficiency of healthcare resources when combating the COVID-19 pandemic. In addition, AI can be a promising tool for numerous other healthcare applications to advance computer-aided diagnostic and detection accuracy, as shown in Figure 1. For instance, AI-based X-ray screening can provide a better diagnosis and address radiologist's uncertainties due to the ambiguous appearance of the virus. Moreover, disease diagnostics and prognostics are improved with clinical imaging through the utilization of various AI tools .
For example, AI contributes to brain tumor detection using Fuzzy C-means, k-means clustering, and Otsu edge techniques [6, 7]. Additionally, Alzheimer’s disease detection and continuous remote sensing applications have also been improved with AI, explicitly using deep neural networks. Furthermore, recent literature shows various AI-based solutions that were designed to improve the diagnosis of the X-ray based screening process. In , the authors present a COVID-Net that improves the test accuracy by up to 92.4%. However, COVID-Net experiences limitations in Positive Predictive Value (PPV) and risk satisfaction. Moreover, Convolutional Neural Networks (CNN) and Support Vector Machines (SVM) also have a high potential for COVID-19 diagnosis automation , with the Decompose Transfer and Composes Model (DeTraC) achieving an accuracy of 95.12 % . However, it only exhibits optimal results for small data sets. The detection accuracy is further improved in  to 96.1% by using pre-trained CNN.
Figure 2: Proposed CNN Architecture
Motivated by the importance of CNN in faster and more accurate detection of COVID-19, we have developed a four-layer CNN model for analyzing CT images. The first three layers have input sizes of (254, 254, 3), (127, 127, 3), and (124, 124, 3), respectively, with the Relu activation function running at each layer. The polling size of 2 x 2 is used at the first two layers, while the third layer has a filter size of 3 x 3. The proposed CNN model is also represented in Figure 2 to visually elaborate the system architecture. Table 1 highlights the configuration details of the proposed CNN model.
In our experiments, we used two datasets, collected from two different sources, to evaluate the model's performance. The first dataset is freely available at the Kaggle Images Dataset website that consists of 5,427 COVID images and 2,628 non-COVID images. The second dataset is obtained from GitHub Dataset Images, containing 349 COVID images and 397 non-COVID images.
We have used TensorFlow to implement the proposed CNN model and cross-validate via the K-Fold procedure . We first divided the dataset into four groups of data samples (4-fold cross-validation) and used four metrics, i.e., accuracy, precision, F1-score, and confusion matrix, to evaluate the model's performance with the training set, validation set, and testing set of 80%, 10%, and 10% respectively. Moreover, with a K-fold of 4, the maximum accuracy of 99.73% is achieved. Table 2 and Table 3 further demonstrate the training and testing results, respectively. The confusion matrix is represented in Figure 3 is used to highlight the performance and accuracy of the proposed model.
Table 1: Configuration detail of proposed CNN model
Table 2: 5-fold cross-validation training results
Table 3: 4-fold cross-validation testing results
This study highlights the role of AI in the medical domain and demonstrates a deep convolutional neural network (CNN) model for chest radiography images to detect COVID-19. The proposed model is trained and tested on chest x-ray images and CT images, showing promising performance with a mean accuracy of 98.16% and a testing accuracy of 96.47%. The predictions of the proposed model can lead to insights about crucial factors associated with COVID-19 and may assist clinicians in improved screening when using computer-aided imaging.
- Rao, B. P., Doddavarapu, V. S., & Kande, G. B. (2021). Artificial Intelligence for the Detection of Coronavirus Disease (COVID-19) from Chest X-Ray Images. European Journal of Molecular & Clinical Medicine, 7(11), 2781-2790.
- Saeed, N., Bader, A., Al-Naffouri, T. Y., & Alouini, M. S. (2020). When wireless communication faces COVID-19: Combating the pandemic and saving the economy. Frontiers in Communications and Networks,
- Dlamini, Z., Francies, F. Z., Hull, R., & Marima, R. (2020). “Artificial intelligence (AI) and big data in cancer and precision oncology.” Computational and Structural Biotechnology Journal.
- Saba, T. (2020). “Recent advancement in cancer detection using machine learning: Systematic survey of decades, comparisons and challenges.” Journal of Infection and Public Health, 13(9), 1274-1289.
- Myszczynska, M. A., Ojamies, P. N., Lacoste, A. M., Neil, D., Saffari, A., Mead, R., ... & Ferraiuolo, L. (2020). “Applications of machine learning to diagnosis and treatment of neurodegenerative diseases.” Nature Reviews Neurology, 16(8), 440-456.
- Javaid, S., Wu, Z., Fahim, H., Mabrouk, I. B., Al-Hasan, M., & Rasheed, M. B. (2020). Feedforward Neural Network-Based Data Aggregation Scheme for Intrabody Area Nanonetworks. IEEE Systems Journal.
- Fahim, H., Li, W., Javaid, S., Sadiq Fareed, M. M., Ahmed, G., & Khattak, M. K. (2019). Fuzzy logic and bio-inspired firefly algorithm based routing scheme in intrabody nanonetworks. Sensors, 19(24), 5526.
- Wang, L. and A. Wong (2020). "COVID-Net: A Tailored Deep Convolutional Neural Network Design for Detection of COVID-19 Cases from Chest X-Ray Images." arXiv preprint arXiv:2003.09871.
- Fong, B., Fong, A. C. M., & Li, C. K. (2020). Telemedicine Technologies: Information Technologies in Medicine and Digital Health. John Wiley & Sons.
- Abbas, A., M. M. Abdelsamea, et al. (2020). "Classification of COVID-19 in chest X-ray images using DeTraC deep convolutional neural network." arXiv preprint arXiv:2003.13815.
- Hall, L. O., R. Paul, et al. (2020). "Finding covid-19 from chest x-rays using deep learning on a small dataset." arXiv preprint arXiv:2004.02060.
- Kuang, L., Zhao, H., Wang, L., Xuan, Z., & Pei, T. (2019). A novel approach based on point cut set to predict associations of diseases and LncRNAs. Current Bioinformatics, 14(4), 333-343.
This article was edited by Bernard Fong
For a downloadable copy of the July 2021 eNewsletter which includes this article, please visit the IEEE Smart Cities Resource Center.