Review Article
Austin J Pulm Respir Med. 2023; 10(1): 1096.
Post-COVID Chest Disease Monitoring Using Self Adaptive Convolutional Neural Network
Vamsi Kakani¹; B Varun¹; Jyostna Devi Bodapati¹*; Konda Raja Sekhar²
¹Dept of ACSE, VFSTR Deemed to be University, Vadlamudi, India
²IEEE Senior Member, India
*Corresponding author: Jyostna Devi Bodapati Department of ACSE, VFSTR Deemed to be University, Vadlamudi, India. Email: jyostna.bodapati82@gmail.com
Received: March 28, 2023 Accepted: May 05, 2023 Published: May 12, 2023
Abstract
Due to the post-Covid effect, several people are experiencing respiratory problems, with Pneumonia being a common and frequent issue. Chest X-rays can easily identify this, but regular monitoring is necessary for older people with respiratory issues. To address this issue, we have developed a model that predicts four different class of chest diseases: Covid, Pneumonia, Tuberculosis, and Normal. The proposed transfer learning based convolutional neural network model utilizes a collaborative dataset consisting of all these four disease X-ray images and is trained using the early stopping approach to ensure optimal performance. The self-adaptive CNN achieves an accuracy of 95-97% on the train split and 90-95% on the test split. Our model performs well on the collaborative dataset of chest X-ray images, making it an effective tool for identifying respiratory problems in post-Covid patients and elder oldage people.
Keywords: Transfer learning; Lung Infection; Covid detection
Introduction
The COVID-19 pandemic is ongoing, and the long-term effects of the disease can weaken the respiratory system, leading to pneumonia, asthma, and chest pain, especially during cold weather. Regular check-ups are necessary to monitor these conditions and manually conducting these checkups may not be practical. In order to simplify the diagnostic process, automated tools can be used to support the physicians. It is true that medical imaging techniques can present several challenges for accurate diagnosis and treatment, and there has been a growing interest in applying deep learning methods to overcome these difficulties.
Since 2020, several inquiries about establishing approaches and models to separate those who are at risk for these diseases from those who are not. Most of these studies use Convolutional Neural Networks (CNNs) to classify chest X-rays as normal or abnormal, enabling the identification of possible chest disease cases. Not only for the chest diseases, CNNs often yield high accuracy for several disease recognition tasks such as diabetic retinopathy recognition, pediatric disease identification, tumor prediction and many other real-time problems. CNNs are good at learning hidden features from the images through multiple hidden layers and offers better image representations compared to the conventional image representations.
CNNs have shown superior performance for various real-time tasks and are far better than fully connected Deep Neural Networks (DNNs) for chest pathology identification. The use of deep CNN-based architectures such as Inception V3 has shown promising results in the categorization of skin cancer, as demonstrated in Andre's study. Similarly, Grewal's work on detecting brain haemorrhage in computed tomography images and Lakhani's approach for automated categorization of pulmonary TB using a neural network-based approach (CNN) have also shown potential for improving medical image analysis. CNNs with deep architectures need large data for training which can be considered as a weakness of CNN for their application in disease recognition. In such cases, transfer learning approaches are preferrable to training of a deep CNN model from scratch.Razaaket et al’s work emphasized on the presenting various challenges involved in medical imaging, such as low image resolution, noise, artifacts, and variability in the appearance of anatomical structures and pathological conditions. Additionally, accurate prediction of the presence or absence of the disease in the images was demonstrated as it involves a simple binary classification task. Accurately predicting different types of diseases from medical images is a complex multi-class classification task, and most of the existing works are not suitable for this purpose as it is complex compared to the earlier task.
With the requirement of the range of common diseases, we focus on developing an efficient model to process the chest X-ray images and classify them into COVID-19, pneumonia, and tuberculosis categories. The proposed model uses different types of image pre-processing techniques such as scaling, resizing and then extracts deep features from chest X-ray images. Deep pre-trained Convolutional Neural Network (CNN) models are used for feature extraction. The proposed approach shows promising in addressing the challenges of medical imaging techniques and improves the accuracy and efficiency of medical image analysis. The experimental studies carried out on benchmark dataset leads to the validation accuracy of 93.15%. The proposed model is also trained on cross data sets and merged datasets, including chest X-ray pneumonia, tuberculosis TB chest X-ray dataset, chest X-ray COVID-19 pneumonia, and COVID-19 chest X-ray dataset.
Literature Survey
The pipeline of image based respiratory disease prediction models involve image pre-processing techniques aiming for improvement of the image data that suppresses unwilling distortions and enhances image features important for further processing. This follows the deep neural network model training.
It's common for researchers to compare different deep learning models and techniques for the task of lung disease prediction using Chest X-ray datasets. Table 1 provides a summary of recent research in this area, highlighting the performance of different models and techniques. These studies typically compare different deep learning models and techniques and evaluate their performance on Chest X-ray datasets.
Title
Datasets
Model
Accuracy
Covid-19-Diagnosis-with-deep learning
Chest X-ray (Covid-19 and Pneumonia)
CNN
86.37%
Classification of Respiratory Diseases
Chest X-ray Images (Normal, Bacterial Pneumonia, Viral Pneumonia, Covid-19)
VGG16
64.03%
Covid19_Diagnosis
Chest X-ray Images (covid-19)
CNN
87.59%
Covid-19 detection from three classes
Radiography (Covid-19) and Chest X-ray (Pneumonia and Covid-19)
VGG16
63.22%
Tuberculosis classification
Chest X-ray Images (Tuberculosis)
DenseNet21
92.06%
Table 1: Summary of the Literature on Lung Disease prediction.
Convolution Size
Train
Test
Parameters
4,4
97
94
13,570,180
4,1/1,4
83
80
6,572,804
Table 2: Comparison of parameters.
It's important to note that the choice of model and technique will depend on the specific dataset, task, and performance metrics of interest. Some common deep learning models used in the literature for lung disease prediction include VGG16, ResNet, DenseNet, and Inception. Additionally, techniques such as transfer learning, data augmentation, and ensemble were also explored in literature to improve performance.
Overall, the field of deep learning for lung disease prediction is an active area of research, and there are many promising approaches being developed and evaluated. However, it's important to carefully consider the limitations and potential biases in the data, as well as the generalizability of the models to different populations and imaging modalities. Top of Form
After training the model using training data, the accuracy is evaluated on a separate set of test data, resulting in an accuracy of 64.03%. The accuracy metric is commonly used to assess the performance of machine learning models. However, it's important to note that accuracy alone may not provide a complete picture of model performance, and other evaluation metrics such as precision, recall, and F1-score may be useful in assessing the model's performance on different classes.
Additionally, it's important to consider other factors such as the quality and representativeness of the training data, the choice of hyper parameters in the model, and the potential for over-fitting or under-fitting scenarios. These factors can all impact the performance of the model and should be carefully considered when developing and evaluating machine learning pipelines. When comparing the two types of Deep Neural Networks (DNN) models, there are some key differences in terms of the input data, the classification task, and the performance metrics. For example, Tuberculosis classification typically involves binary classification of chest X-ray images, while COVID-19 classification involves multi-class classification of chest X-ray images. Additionally, the metrics used to evaluate the performance of the models may differ, with Tuberculosis models often reporting accuracy, sensitivity, specificity, and AUC, while COVID-19 models may also report precision, recall, and F1-score.
In terms of performance, both types of models have shown promising results in the detection of their respective diseases. However, it is important to note that the accuracy of the models may vary depending on the dataset used for training and testing, as well as the specific implementation and optimization of the Deep Neural Networks (DNN) architecture.
Overall, these comparative studies suggest that DNN models can be effective tools for the classification of chest X-ray images into COVID-19 positive and pneumonia positive. However, the performance of these models can vary depending on the specific Deep Neural Networks (DNN) architecture used and the dataset used for training and testing.
Confirming Covid virus may require diagnostic tests, including sputum culture, chest CT scan, and bronchoscopy. The RT-PCR test, which stands for real-time reverse transcription-polymerase chain reaction, is the most often used approach for diagnosing Covid-19 illness. This procedure is frequently time-consuming because taking the test and transferring samples takes more than half a day. This type of exam typically takes 3-6 days to complete. The symptoms of the covid 19 are cough, fever, throat pain, and headache. The use of Artificial Intelligence (AI) techniques for medical diagnosis has accelerated rapidly over the past decades, with AI-assisted deep learning neural networks for the analysis of medical images such as chest x-rays and radiographs. Chest X-ray is recommended by WHO as a screening and triage tool for tuberculosis, which in 2020 killed almost as many people as COVID-19 worldwide.
Pneumonia is an acute pulmonary disease caused by bacteria, virus, or fungi that impacts the lungs, trying to stoke the air sacs and resulting to pericardial effusion, a condition in which the lung is filled with fluid. It is responsible for more than 15% of all fatalities in kids under the age of five. Most cases of pneumonia occur in impoverished and emerging nations, where there is a shortage of medical resources, excessive population, pollution, and unclean environmental conditions.
Therefore, avoiding the condition from turning deadly can be greatly aided by early diagnosis and care. The diagnosis of lung disorders typically involves radiological evaluation of the lungs using Computed Tomography (CT), Magnetic Resonance Imaging (MRI), or Radiography (X-rays). X-ray imaging is a minimally invasive and reasonably priced. A non-invasive and reasonably priced way to examine the lungs is with X-ray images. To understand it betters an example of both a healthy lung X-ray and pneumonic is shown in Figure above. Pneumonia may be distinguished from a healthy condition by the white patches on the pneumonic X-ray, known as infiltrates (shown with red arrows). The identification of pneumonia by chest X-rays is subject to subjective fluctuation, albeit. Therefore, the need for an automated pneumonia detection system exists. For the proper categorization of chest X-ray images in this work, we created a Computer-Aided Diagnosis (CAD) system that makes use of an ensemble of deep transfer learning models.
Proposed Approach
The objective of the proposed model is to predict multiple posts Covid diseases related to chest based on X-ray images. As a dataset supporting the target task is not available, it focuses on combining 4 datasets Chest X-ray images each containing a different disease. Then the proposed model is trained on the combined dataset. A custom Convolution Neural Network model is designed and the merged dataset is then used to train the proposed CNN. The proposed CNN model is designed with four Convolutional layers each paired with activation and Batch Normalization layers. These convolutional layers are used for representation learning and, for classification a dense layer is attached at the end with softmax activation. We proposed to use the Elu activation function with convoutional layers of this model to get better generalization on the hybrid chest X-ray images of the combination dataset.
The objective of the proposed model is to predict multiple post covid diseases related to chest based on X-ray images. As a dataset supporting the target task is not available, it focuses on combining 4 datasets Chest X-ray images each containing a different disease. Then the proposed model is trained on the combined dataset. A custom Convolution Neural Network model is designed and the merged dataset is then used to train the proposed CNN. The proposed CNN model is designed with four Convolutional layers each paired with activation and Batch Normalization layers. These convolutional layers are used for representation learning and for classification, a dense layer is attached at the end with softmax activation. We proposed to use the Elu activation function with convolutional layers of this model to get better generalization on the hybrid chest X-ray images of the combination dataset.
The proposed approach makes use of several image preprocessing techniques such as scaling on chest X-ray images. This study also investigates performance of the model when transfer learning-based approaches are used for feature extraction. Instead of building a CNN from scratch, it is preferable to use one that has already been trained on very large datasets like Image Net, which contains 1.2 million image data and 1000 groups. Transfer learning is the idea of using a deep learned model for a similar task which has fewer samples. In this approach, the deep pre-trained model is used to acquire and learn the important characteristics and features that will be able to produce a fine performance on similar problems associated to the model. On CNNs, there are three typical ways to pass learning strategies. In order to fine-tune our method for this investigation, we observed the most prevalent.
Pre-processing- The class-wise distribution of the dataset used to evaluate the proposed study can be observed in Figure 3. From this figure it can be observed that the dataset is imbalanced, and may lead to biased results, if it is considered in the original form. Hence the dataset is properly balanced by under-sampling where 566 Chest Xray images are randomly picked up from each class. The dataset is shuffled before training, this helps in unbiased results. Further, each image is reshaped into 224x224 pixel size.
Undoubtedly, the most well-known deep learning architecture in the computer vision field is CNN. These CNNs, were initially proposed by LeCun et al for the identification of handwritten zip. These CNNs belong to the group of feed-forward networks and are known for their spatial representation leaning from images. The convolution operation used in the network is the primary component of CNN and leads to the capturing of spatial features from the input images. Each feature map dimensionality is reduced by the pooling layer used after the convolution layer. The network architecture is presented in Figure 2 as a sequence of convolution, pooling, dense and other layers. The SoftMax layer is utilized at the network's end for image categorization.
Figure 1: Proposed Architecture.
Figure 2: Layer wise configuration details of the custom Convolutional neural Network used in the proposed work.
IV Experimental Studies
Dataset – We used four distinct sources to create our dataset used for experimental studies. The first is chest-Xray-pneumonia, from which we extracted X-Ray images of the covid and pneumonia tests. The second source is the TB-tb-chest-Xray-dataset from Kaggle, from which we extracted X-Rays of healthy lungs and lungs affected by tuberculosis. The database maintained by JP Cohen is built from a variety of public sources. The Covid Chest Xray pictures are gathered using the chest-xray-covid19-pnemonia. Also, the validation images are gathered from the GitHub repository's covid-chest Xray dataset. There are 3 folders (train, test, and val) made up of subfolders for each picture type (normal/pneumonia/covid-19/tuberculosis), totaling 7135 chest X-ray images.
Figure 3: Class-wise distribution of images in the hybrid dataset.
Early stopping is a technique used to prevent overfitting in machine learning models. As a model becomes more complex, it may fit the training data too closely, causing a decrease in performance on new, unseen data. Early stopping helps address this issue by monitoring the model's performance on a validation set during training. If the validation error starts to increase, training is stopped, and the best-performing model is saved. This approach helps prevent overfitting, allows the model to generalize better to new data, and saves time and computational resources by avoiding unnecessary training epochs. Inspired by the GoogleNet architecture, we attempted to reduce the number of parameters in our model. We were able to reduce the parameter count by half, but we found that the accuracy of the model decreased as a result. The model was not able to identify features as effectively with fewer parameters. This highlights the trade-off between parameter count and accuracy. To reduce the number of parameters, we may need to accept some decrease in accuracy.
Using the early stopping approach, our model achieved a test accuracy of 93% over 15 epochs. However, we observed that the learning rate of the model was not stable, during the early stopping process which is shown in the Graph 1. To gain a better understanding of the model's performance, confusion matrix. The confusion matrix is shown in the Figure 4 is obtained by the model on test split of the data set and provides a clear understanding of how the prediction vector of the four classes was misclassified with each other. This information can help us improve the model's performance by identifying which classes are being misclassified and adjusting the model's parameters accordingly.
Figure 4: Confusion matrix obtained by the model on test split of the data set.
Graph 1: Accuracy vs Loss plot over the epochs on train and validation splits of the dataset.
Comparison Study: We conducted a comparison study by performing feature extraction from different blocks of VGG16 and the results are reported on the same dataset in table 3. This allowed us to evaluate the performance of each layer and gain a better understanding of the features learned by the model. Following are the three models used for validation.
Random Forest
S V M
Block 3
93.0
95.42
Block 4
94.78
96.5
Block 5
93.66
93.41
Table 3: Comparing the results obtained from different blocks of VGG16 trained using conventional ML approaches.
Dataset
Accuracy on train split
Accuracy on test split
D1(covid)
92
87
D2(Pneumonia)
94
93
D3(tuberculosis)
88
91
Table 4: Comparing the results obtained using conventional ML approaches when different pooling approaches are used.
Random Forest
SVM
Max
93.17
96.76
Min
89.3
91.2
Avg
91.7
94.4
Table 5: Comparing the results of train and test sets.
Model 1: Logistic Regression
Model 2: Random Forest
Model 3: Support Vector Machine
AS per the results shown in Table 3, it can be claimed that the features obtained from block 4 when trained using SVM leads to better accuracy. The high accuracy achieved by each model demonstrates the effectiveness of transfer learning and feature extraction using VGG16 blocks. By understanding the features learned by the model at each layer, we can optimize our machine learning models and improve their performance.
The results of our study are summarized below: The operations of Fully Connected layer of the VGG16 are show in the table without ravel on machine learning models. These features help in building the Machine Learning models that extract all the features from various layers and classify the classes they belongs to. The ML models used are Random Forest and Support Vector Machine. Random Forest is a classification algorithm that uses a collection of decision trees on different subsets of the provided dataset and averages them to increase the dataset's prediction accuracy. Instead, than depending on a single decision tree, the random forest uses forecasts from each tree and predicts the result based on the votes of the majority of predictions. Support Vector Machines (SVMs) are supervised machine learning models that are both powerful and adaptable. They are used for classification and regression. Nonetheless, they are typically employed in categorization issues. SVMs were initially presented in the 1960s, however they were later improved in 1990. SVMs are implemented in a different way than other algorithms used in machine learning. They have recently gained a lot of popularity because to their capacity to manage several categorical and continuous variables at the same time.
With the analysis of the results obtained by the CNN model we had tested the accuracy of each independent dataset of the child Dataset test and train samples.
Conclusion
Through this experimental study, we have gained an understanding that the CNN model can perform well when properly scaled and compiled. The data processing of each layer, both pre-defined and in the Convolution Neural Network, relies on appropriate dimension analysis and feature understanding. As a result, the model produced shows good performance on the validation and testing sets, even with previously unseen data.
Our model utilizes a self-adaptive Convolution Neural Network, capable of detecting four specified classes of chest X-ray diseases. Compared to the VGG16 pretrained model, the current model produces significantly better results in terms of feature extraction. Moreover, our model can handle both binary and multi-class classification tasks.
Future Scope
The potential for this model could extend to the inclusion of additional parameters such as heart rate, air volume intake and exhale, as well as the presence of allergy and infection symptoms. Additionally, the patient's age could be considered to provide a more comprehensive assessment. Given sufficient data, it may also be possible to estimate the likelihood of survival.
References
- Razzak MI, Naz S, Zaib A. Deep learning for medical image processing: overview, challenges and the future. 2017.
- Bodapati JD, Rohith VN. ChxCapsNet: Deep capsule network with transfer learning for evaluating pneumonia in paediatric chest radiographs. Measurement. 2022; 188: 110491.
- Bodapati JD, Rohith VN, Dondeti V. Ensemble of deep capsule neural networks: an application to pediatric pneumonia prediction. Physical and Engineering Sciences in Medicine. 2022; 45: 949-959.
- Shen D, Wu G, Suk HI. Deep learning in medical image analysis. Annual review of biomedical engineering. 2017; 19: 221–248.
- Naralasetti V, Shaik RK, Katepalli G, Bodapati JD. Deep Learning Models for Pneumonia Identification and Classification Based on X-Ray Images. Traitement du Signal. 2021; 38: 903-909.
- Andre E, Brett K, Roberto A, Justin K, Susan MS, et al. Dermatologist-level classification of skin cancer with deep neural networks. Nature. 2017; 542: 115–118.
- Milletari F, Navab N, Ahmadi S. V-net: fully convolu-tional neural networks for volumetric medical imagesegmentation. 2016 fourth International Conference on 3D Vision (3DV); Stanford, CA; 2016: 565–571.
- Grewal M, Srivastava MM, Kumar P, et al. Radiologist level accuracy using deep learning forhaemorrhage dete. 2017.
- Zhi Zhen Qin, Shahriar Ahmed, Mohammed SS, Kishor P, Ahammad SSA, et al. Tuberculosis detection from chest x-rays for triaging in a high tuberculosis-burden setting: an evaluation of five artificial intelligence algorithms. Lancet Digit Health. 2021; 3: e543-e554.
- “Covid AID: COVID-19 Detection Using Chest X-Ray”, Proceedings of the Fifth International Conference on Computing Methodologies and Communication (ICCMC 2021) IEEE Xplore Part Number: CFP21K25-ART.
- Arpan Mangal, Surya Kalia, Harish Rajagopal. Pneumonia detection in chest X-ray images using compound scaled deep learning model.
- Mohammad Farukh Hashmia, Satyarth Katiyarb, Abdul Wahab Hashmi, Avinash G Kesar. Pneumonia detection in chest X-ray images using an ensemble of deep learning models. 2021; 62: 397-406.
- Rohit Kundu, Ritacheta Das, Zong Woo Geem, Gi-Tae H, Ram Sarkar. Pneumonia Detection on Chest X-ray Images Using Ensemble of Deep Convolutional Neural Networks. PloS One. 2021; 16: e0256630.
- Naralasetti V, Shaik RK, Katepalli G, Bodapati JD. Deep Learning Models for Pneumonia Identification and Classification Based on X-Ray Images. Traitement du Signal. 2021; 38: 903-909.
- Bodapati JD, Rohith VN, Dondeti V. Ensemble of deep capsule neural networks: an application to pediatric pneumonia prediction. Physical and Engineering Sciences in Medicine. 2022; 45: 949-959.
- Bodapati JD, Rohith VN, Dondeti V. Ensemble of deep capsule neural networks: an application to pediatric pneumonia prediction. Physical and Engineering Sciences in Medicine. 2022; 45: 949-959.
- Bodapati JD, Rohith VN. ChxCapsNet: Deep capsule network with transfer learning for evaluating pneumonia in paediatric chest radiographs. Measurement. 2022; 188: 110491.