Journal of Artificial Intelligence and Metaheuristics cover
Journal of Artificial Intelligence and Metaheuristics

Online ISSN 2833-5597

Full Length Article

Volume 3 • Issue 2 • PP: 28-37 • 2023

Automated Detection and Segmentation of COVID-19 Infection using Machine Learning

S. K. Towfek 1* ,
Ehsaneh khodadadi 2 ,
Fatma M. Talaat 3
1Computer Science and Intelligent Systems Research Center, Blacksburg 24060, Virginia, USA
2Department of Chemistry and Biochemistry, University of Arkansas, Fayetteville, AR 72701, USA
3Faculty of Artificial Intelligence, Kafrelsheikh University, Kafrelsheikh, Egypt
* Corresponding Author.
verified

Open Access & Copyright

© 2023 The Author(s). Published by ASPG. This article is licensed under the Creative Commons Attribution 4.0 International License (CC BY 4.0).

Abstract

The accurate and timely segmentation of COVID-19 infection areas from CT scans is crucial for effective diagnosis and treatment planning. In this paper, we propose an automated approach utilizing machine learning techniques for COVID-19 infection segmentation. The proposed framework utilizes a convolutional neural network (CNN) architecture to extract informative features from CT scan images. These features are then fed into a segmentation model, which employs a combination of U-Net and attention mechanisms for accurate delineation of infection regions. To enhance the model's performance, we employ a transfer learning strategy by pretraining the CNN on a large dataset of general medical images. To evaluate the effectiveness of our approach, we conducted experiments on a diverse dataset consisting of CT scans from COVID-19 patients. The results demonstrate the superiority of our method in accurately segmenting infection areas, achieving an average Dice coefficient of 0.92 and a Jaccard index of 0.88. The proposed automated segmentation method offers significant potential for aiding radiologists and clinicians in identifying COVID-19 infection regions from CT scans rapidly and accurately. It can contribute to improved diagnosis, patient management, and treatment planning in the fight against the ongoing pandemic.

Full Text

This HTML version is generated from the article PDF. The PDF remains the version of record.

1. Introduction

For the header and the footer, just change the journal name and the abbreviation, then leave all other information for our production team at the ASPG editorial office to be updated after your paper acceptance.

The COVID-19 pandemic has emerged as a global health crisis, impacting millions of lives worldwide. The rapid spread of the virus has strained healthcare systems, leading to an urgent need for accurate and efficient diagnosis. COVID-19 predominantly affects the respiratory system, and the severity of the disease varies from mild symptoms to acute respiratory distress syndrome. In this context, computed tomography (CT) scans have shown great potential in aiding diagnosis by providing detailed imaging of lung abnormalities associated with COVID-19 infection. CT scans offer valuable insights into the extent and severity of lung involvement, allowing healthcare professionals to make informed decisions regarding patient management and treatment strategies [1]. CT scans have emerged as an essential diagnostic tool for COVID-19 due to their ability to visualize lung abnormalities caused by the infection. Unlike other diagnostic techniques, CT scans provide highresolution images that enable the identification and characterization of COVID-19-related lung lesions, such as ground-glass opacities, consolidations, and interstitial thickening. The radiological findings from CT scans can complement other diagnostic methods, such as polymerase chain reaction (PCR) testing, especially in cases where PCR results are inconclusive or delayed. Moreover, CT scans have been particularly useful in identifying lung involvement even in asymptomatic or early-stage COVID-19 cases, facilitating timely intervention and reducing the risk of further transmission [2].

Manual segmentation of COVID-19 infection regions in CT scans presents several challenges. Firstly, it is a time-consuming and labor-intensive process, requiring extensive expertise and training. Additionally, subjective variations among radiologists may result in inconsistent segmentations and subjective biases. Inter-observer variability further hampers the reliability and reproducibility of manual segmentations [3]. Furthermore, in the context of a rapidly spreading pandemic, the time and effort required for manual segmentation can hinder the prompt delivery of diagnosis and subsequent treatment decisions. Therefore, there is a pressing need for automated segmentation methods that can provide accurate and efficient identification of COVID-19 infection regions from CT scans [4]. Machine learning (ML) techniques, particularly deep learning algorithms, have shown significant promise in automating the segmentation of various medical conditions, including COVID-19 infection. By leveraging large datasets and powerful neural network architectures, ML models can learn complex patterns and features from CT scans, enabling accurate and objective identification of infection regions [5]. Automated segmentation not only eliminates the subjectivity and inter-observer variability associated with manual segmentation but also speeds up the process, allowing for rapid analysis of large volumes of CT scan data. These advancements hold great potential for enhancing the diagnostic accuracy and efficiency of COVID-19 infection segmentation.

Previous research efforts have explored the application of ML techniques for automated segmentation of COVID-19 infection from CT scans. Several studies have utilized convolutional neural network (CNN) architectures to extract features from CT images and perform segmentation [7]. These approaches have demonstrated promising results in accurately identifying infection regions, contributing to improved diagnosis and patient management. However, existing studies have focused on specific aspects of the segmentation process, such as architecture design or feature extraction methods, and there is still room for further advancements and refinement of the techniques [8]. Moreover, the generalizability and robustness of these methods across diverse datasets and variations in imaging protocols need to be explored.

Despite the progress in automated segmentation techniques for COVID-19 infection, there remains a research gap in developing a comprehensive and robust ML-based approach that can accurately and efficiently segment infection regions from CT scans [9]. In this study, we propose a machine learningbased approach for automated segmentation of COVID-19 infection from CT scans. Our framework integrates a convolutional neural network (CNN) architecture, which extracts discriminative features from CT images, with a segmentation model based on U-Net and attention mechanisms. Through joining these components, our method aims to achieve accurate and precise delineation of infection regions. Additionally, to enhance the performance of the model, we employ transfer learning by pretraining the CNN on a large dataset of general medical images, enabling the network to leverage learned representations and adapt them to the task of COVID-19 infection segmentation.

The remainder of this paper is structured as follows. Section 2 presents the propose approach, detailing the architecture and components of the proposed machine learning framework. Section 3 describes the experimental setup, including the dataset, evaluation metrics, and implementation details. Section 4 presents the results and discusses the findings. Finally, Section 5 concludes the paper, summarizing the contributions and highlighting the significance of the proposed automated segmentation method for COVID-19 infection from CT scans.

2. Proposed Approach

In this section, we present our proposed approach for automated segmentation of COVID-19 infection from CT scans, leveraging the power of machine learning and advanced image processing techniques.

In the proposed approach, one of the preprocessing steps in our proposed approach is the application of the Contrast Limited Adaptive Histogram Equalization (CLAHE) enhancer to the COVID-19 CT scans. The goal of this preprocessing step is to enhance the contrast and improve the visibility of relevant features in the images, aiding the subsequent segmentation process. CLAHE is used to enhance local contrast by redistributing the pixel intensity values within small image regions. It works by dividing the image into smaller tiles and applying histogram equalization to each tile individually. However, to avoid over-amplification of noise, CLAHE incorporates a contrast limiting mechanism, ensuring that the enhancement is controlled and adaptive to the local characteristics of the image. As shown in Figure 1, applying CLAHE to the COVID-19 CT scans can enhance the visibility of subtle details and abnormalities associated with COVID-19 infection, such as ground-glass opacities and consolidations. This preprocessing step can ensure that the enhanced images are used as input to the CNN architecture [8-10].

Figure 1. visualization of CLAHE enhancement on CT scans of COVID-19
Figure 1. visualization of CLAHE enhancement on CT scans of COVID-19

In addition, our proposed approach also incorporates the cropping of the region of interest (ROI) from the CLAHE enhanced COVID-19 CT scan. This additional preprocessing step aims to focus the segmentation process on the relevant lung area, improving the efficiency and accuracy of the subsequent segmentation model [11]. This helps to eliminate potential noise and distractions that may exist outside the lung region, enabling the segmentation model to focus solely on the lung tissue and COVID-19 infection regions. The cropping of the ROI is performed after applying the CLAHE enhancer, ensuring that the enhanced image is used for accurate delineation of the lung boundaries. This step involves identifying the approximate location of the lung region and applying a bounding box or mask to crop out the relevant area of interest (See Figure 2).

Figure 2. visualization of CT scans of COVID-19 after applying CLAHE and ROI cropping
Figure 2. visualization of CT scans of COVID-19 after applying CLAHE and ROI cropping

In the methodology section, our proposed approach utilizes an attention-based U-Net architecture for the segmentation of COVID-19 infection regions from CT scans. This architecture combines the U-Net framework, known for its effectiveness in medical image segmentation, with attention mechanisms to enhance the localization and accuracy of the segmentation process. The U-Net architecture is a deep learning model specifically designed for biomedical image segmentation tasks. It consists of an encoder network that captures high-level features from the input image and a corresponding decoder network that performs the upsampling and generates the segmentation output. The skip connections between the encoder and decoder pathways allow for the integration of both high-level and low-level features, improving the model's ability to capture fine details and preserve spatial information. To further improve the performance of the U-Net model, attention mechanisms are incorporated into the architecture. Attention mechanisms enable the model to selectively focus on informative regions while suppressing irrelevant or noisy areas. This attention mechanism can guide the model to attend to the relevant COVID-19 infection regions within the lung and disregard noninfectious regions or artifacts, leading to more precise and accurate segmentation results. The selection of features within the attention gate can be mathematically represented by the following formula:

𝑇 × 𝑓 + 𝑏𝑓) + (𝑊𝑔 𝑇 × 𝑔 + 𝑏𝑔)]                                                                                      (1) 𝐹= 𝜎1[(𝑊𝑓
𝑇 × 𝐹 + 𝑏𝜃)                                                                                                                  (2) 𝛼= 𝜎2(𝑊𝜃
o = 𝑓× 𝛼                                                                                                                                 (3)

The attention-based U-Net architecture leverages the strengths of both the U-Net framework and attention mechanisms, combining their complementary capabilities to achieve robust and accurate segmentation of COVID-19 infection regions. The attention mechanisms enhance the model's ability to adaptively weigh and emphasize informative features, improving the localization and discrimination of infection regions within the CT scans.

By employing the attention-based U-Net architecture, our proposed approach aims to achieve stateof-the-art performance in COVID-19 infection segmentation [12-17]. The combination of the U-Net framework and attention mechanisms provides a powerful tool for accurate and efficient delineation of COVID-19 infection regions, contributing to improved diagnosis and patient management in the context of the COVID-19 pandemic. The network is optimized with Adam optimizer according to the dice loss objective:

2|𝑦|.|𝑦̂| ℒdice(𝑦, 𝑦̂) = 1 −𝑑𝑖𝑐𝑒(𝑦, 𝑦̂) = 1 − |𝑦|2+|𝑦̂|2 (4)

With 𝑦 and 𝑦̂ denote the segmentation maps and corresponding label.

3. Experimental Setup

In this section, we outline the experimental setup conducted to evaluate the performance and effectiveness of our proposed automated segmentation approach for COVID-19 infection from CT scans. The COVID-19 CT Lung and Infection Segmentation dataset [18] used in our study comprises 20 publicly available CT scans sourced from the Coronacases Initiative and Radiopaedia. These scans are freely downloadable under the CC BY-NC-SA license. All the cases in the dataset contain COVID-19 infections, and the proportion of infections within the lungs varies from 0.01% to 59%. To create the annotations for this dataset, a team of annotators, including junior annotators with 1-5 years of experience, refined by two radiologists with 5-10 years of experience, and finally verified and refined by a senior radiologist with over 10 years of experience in chest radiology, delineated the left lung, right lung, and infection regions. The annotations were performed manually using ITK-SNAP software in a slice-by-slice manner on axial images. The dataset includes a total of 300+ infections distributed across 1800+ slices. Additionally, the annotations also provide a whole lung mask, encompassing both normal and pathological regions. On average, it took approximately 400 ± 45 minutes to annotate a single CT scan with 250 slices. Figure 3 presents visualizations of CT data samples and their corresponding labels from the COVID-19 CT Lung and Infection Segmentation Dataset. The visualizations aim to provide a clear understanding of the dataset's characteristics and the annotated regions of interest.

Figure 3. Visualization of random samples of CT scan (axial view) and the corresponding label.
Figure 3. Visualization of random samples of CT scan (axial view) and the corresponding label.

Two common metrics are used to evaluate the segmentation performance in this study namely Jaccard index (JI) and dice similarity coefficient (DSC):

|𝑃∩  𝐿| |𝑃|+|𝐿|−|𝑃∩  𝐿| (4) 𝐽𝐼=
2|𝑃∩  𝐿| |𝑃|+|𝐿| (5) 𝐷𝑆𝐶=

where |𝑃| 𝑎𝑛𝑑 |𝐿| represent the number of voxels in segmentation maps and annotation label.

4. Results and Discussions

This section presents the findings and analysis obtained from the experiments conducted to evaluate the performance of our proposed automated segmentation method for COVID-19 infection from CT scans. Herein, we analyze the learning curves obtained from the training process of our proposed approach for both lung and infection segmentation. The learning curves provide valuable insights into the performance and convergence of the segmentation model during the training phase. These curves typically depict the training and validation metrics as a function of the number of training iterations or epochs (see Figure 4).

Figure 4. visualization of training dice loss for the proposed model
Figure 4. visualization of training dice loss for the proposed model

For lung segmentation, the learning curve demonstrates the progression of the training and validation loss values. A decreasing trend in the loss values indicates that the model is effectively learning to segment the lung regions from the CT scans. As the training progresses, the loss values should ideally converge to a low value, indicating that the model has successfully captured the relevant features and boundaries of the lung regions. Similarly, for infection segmentation, the learning curve reflects the training and validation metrics specifically related to the accuracy and performance of segmenting the COVID-19 infection regions. The curve provides insights into how well the model is able to differentiate between infected and non-infected lung tissue. By analyzing the learning curves, we can gain insights into the performance of our proposed approach at different stages of the training process. We observe the convergence behavior, assess the effectiveness of the chosen loss function, and determine if any overfitting or underfitting is occurring. Additionally, the learning curves help us make informed decisions regarding training hyperparameters and model architecture adjustments, if necessary, to optimize the segmentation performance.

In Table 1, we present a comparison of the segmentation performance between lung segmentation and infection segmentation, showcasing the results obtained from our proposed approach. The segmentation performance metrics used for evaluation include DSC and JI to provide a comprehensive assessment of the model's ability to accurately delineate the lung and infection regions within the CT scans. For lung segmentation, the results in Table 1 demonstrate the DSC of the model in correctly identifying and segmenting the lung regions. Infection segmentation results in Table 1 reflect the model's performance in accurately identifying and segmenting the COVID-19 infection regions within the lung. By comparing the segmentation performance for lung and infection, we can evaluate the model's ability to distinguish between the different regions of interest. A higher accuracy, precision, recall, and Dice coefficient for infection segmentation would indicate that the model is effectively capturing the subtle details and boundaries of the infection regions, despite their complex and heterogeneous appearances.

Table 1. comparison of the proposed approach against previous methods
Table 1. comparison of the proposed approach against previous methods

Figure 5 showcases the visual results of lung segmentation on several CT scans, providing a qualitative evaluation of the performance of our proposed approach. These visualizations offer a glimpse into the accuracy and effectiveness of the lung segmentation process. As shown, multiple CT scan slices are displayed, both as original images and their corresponding segmented lung regions.

Figure 5. visualization of the lung segmentation results from the proposed approach
Figure 5. visualization of the lung segmentation results from the proposed approach

The original images represent the raw CT scans, while the segmented lung regions are depicted using a distinct color or overlay to distinguish them from the surrounding tissues. Similarly, Figure 6 illustrates the visual results of infection segmentation on several CT scans, providing a qualitative assessment of the performance of our proposed approach. These visualizations offer valuable insights into the accuracy and efficacy of the infection segmentation process.

Figure 6. visualization of the infection segmentation results from the proposed approach
Figure 6. visualization of the infection segmentation results from the proposed approach

Table 2 presents a comparison of the segmentation precision under different threshold values, providing insights into the impact of threshold selection on the precision of the segmentation results. By varying the threshold, we can examine the trade-off between including more pixels in the segmented regions and maintaining a higher precision in identifying the true positive pixels. It is notable that the precision values are reported for various threshold values, indicating the precision achieved at each threshold level. By analyzing the precision values at different thresholds, we can assess the sensitivity of the segmentation model to the threshold selection.

Table 2. comparison of the precision value under different thresholds
Table 2. comparison of the precision value under different thresholds

5. Conclusion

In conclusion, this paper proposed a machine learning-based approach for the automated segmentation of COVID-19 infection from CT scans. Our method demonstrated promising results in accurately identifying and delineating both the lung and infection regions. By leveraging the attention-based U-Net architecture and incorporating preprocessing steps such as CLAHE enhancement and ROI cropping, our approach achieved robust segmentation performance. The experimental evaluation on the COVID-19 CT Lung and Infection Segmentation Dataset showcased the effectiveness of our proposed approach. The segmentation results exhibited high precision and accuracy, as validated through quantitative metrics and visual comparisons with ground truth annotations. The proposed approach holds significant potential in supporting clinical decision-making, facilitating accurate diagnosis, monitoring disease progression, and assisting in treatment planning for COVID-19 cases. The automated segmentation of lung and infection regions from CT scans enables efficient and objective analysis, contributing to improved patient management and healthcare outcomes. Future research directions may involve further refinement of the segmentation model, exploration of additional preprocessing techniques, and validation on larger and more diverse datasets. Overall, this work contributes to the growing body of knowledge in using machine learning for COVID-19 infection segmentation, advancing the field towards more accurate and efficient diagnostic tools.

Funding: “This research received no external funding”

Conflicts of Interest: “The authors declare no conflict of interest.”

References

[1] Zhang, Hai-tao, et al., Automated detection and quantification of COVID-19 pneumonia: CT imaging analysis by a deep learning-based software. European journal of nuclear medicine and molecular imaging 47, 2525-2532, 2020.

[2] Medhi Kishore, Md Jamil, and Md Iftekhar Hussain, Automatic detection of COVID-19 infection from chest X-ray using deep learning. Medrxiv, 2020.

[3] Ding W., Abdel-Basset M., & Hawash H., RCTE: A reliable and consistent temporal-ensembling framework for semi-supervised segmentation of COVID-19 lesions. Information sciences, 578, 559-573, 2021.

[4] Shoeibi A., Khodatars M., Alizadehsani R., Ghassemi N., Jafari M., Moridian P., Gorriz J. M., Automated detection and forecasting of covid-19 using deep learning techniques: A review. arXiv preprint arXiv:2007.10785, 2020.

[5] Ding W., Abdel-Basset M., Hawash H., & Elkomy O. M., Mt-ncov-net: a multitask deep-learning framework for efficient diagnosis of covid-19 using tomography scans. IEEE Transactions on Cybernetics, 2021.

[6] Gozes Ophir, Maayan Frid-Adar, Hayit Greenspan, Patrick D. Browning, Huangqi Zhang, Wenbin Ji, Adam Bernheim, and Eliot Siegel, Rapid ai development cycle for the coronavirus (covid-19) pandemic: Initial results for automated detection & patient monitoring using deep learning ct image analysis. arXiv preprint arXiv: 2003.05037, 2020.

[7] Lokwani, Rohit, et al., Automated detection of COVID-19 from CT scans using convolutional neural networks. arXiv preprint arXiv:2006.13212, 2020.

[8] Hasan M. J., Alom M. S., & Ali M. S., Deep learning based detection and segmentation of COVID-19 & pneumonia on chest X-ray image. In 2021 International Conference on Information and Communication Technology for Sustainable Development (ICICT4SD), 210-214, 2021.

[9] Ding W., Abdel-Basset M., Hawash H., & Elkomy O. M., Mt-ncov-net: a multitask deep-learning framework for efficient diagnosis of covid-19 using tomography scans. IEEE Transactions on Cybernetics, 2021.

[10] Rohila V. S., Gupta N., Kaul A., & Sharma, D. K., Deep learning assisted COVID-19 detection using full CT-scans. Internet of Things, 14, 100377, 2021.

[11] Zhao C., Xu Y., He Z., Tang J., Zhang Y., Han J., Zhou W., Lung segmentation and automatic detection of COVID-19 using radiomic features from chest CT images. Pattern Recognition, 119, 108071, 2021.

[12] Abdar Abolfazl Karimiyan, et al., Automatic detection of coronavirus (COVID-19) from chest CT images using VGG16-based deep-learning. 2020 27th National and 5th International Iranian Conference on Biomedical Engineering (ICBME), 2020.

[13] Rahman Sejuti, et al., Deep learning–driven automated detection of Covid-19 from radiography images: A comparative analysis. Cognitive Computation, 1-30, 2020.

[14] Abdel-Basset M., Chang V., Hawash H., Chakrabortty R. K., & Ryan, M., FSS-2019-nCov: A deep learning architecture for semi-supervised few-shot segmentation of COVID-19 infection. Knowledge-Based Systems, 212, 106647, 2021.

[15] Abdel-Basset M., Hawash H., Moustafa N.,Elkomy O. M., Two-stage deep learning framework for discrimination between COVID-19 and community-acquired pneumonia from chest CT scans. Pattern recognition letters, 152, 311-319, 2021.

[16] Castiglione Aniello, et al., Covid-19: automatic detection of the novel coronavirus disease from ct images using an optimized convolutional neural network. IEEE Transactions on Industrial Informatics 17(9), 6480-6488, 2021.

[17] Ding W., Abdel-Basset M., Hawash H., Elkomy, O. M., Mt-ncov-net: a multitask deep-learning framework for efficient diagnosis of covid-19 using tomography scans. IEEE Transactions on Cybernetics, 2021.

[18] Ma Jun, et al., Towards Data-Efficient Learning: A Benchmark for COVID-19 CT Lung and Infection Segmentation. arXiv preprint arXiv:2004.12537, 2020.

Continue Reading

View the full issue arrow_forward

Cite This Article

Choose your preferred format

format_quote
Towfek, S. K., et al. “Automated Detection and Segmentation of COVID-19 Infection using Machine Learning.” Journal of Artificial Intelligence and Metaheuristics, vol. 3, no. 2, 2023, pp. 28–37. https://doi.org/10.54216/JAIM.030203.
Towfek, S. K., khodadadi, E., & Talaat, F. M. (2023). Automated Detection and Segmentation of COVID-19 Infection using Machine Learning. Journal of Artificial Intelligence and Metaheuristics, 3(2), 28–37. https://doi.org/10.54216/JAIM.030203
Towfek, S. K., Ehsaneh khodadadi, and Fatma M. Talaat. “Automated Detection and Segmentation of COVID-19 Infection using Machine Learning.” Journal of Artificial Intelligence and Metaheuristics 3, no. 2 (2023): 28–37. https://doi.org/10.54216/JAIM.030203.
Towfek, S.K., khodadadi, E. and Talaat, F.M. (2023) ‘Automated Detection and Segmentation of COVID-19 Infection using Machine Learning’, Journal of Artificial Intelligence and Metaheuristics, 3(2), pp. 28–37. Available at: https://doi.org/10.54216/JAIM.030203.
Towfek SK, khodadadi E, Talaat FM. Automated Detection and Segmentation of COVID-19 Infection using Machine Learning. Journal of Artificial Intelligence and Metaheuristics. 2023;3(2):28-37. doi:10.54216/JAIM.030203
S. K. Towfek, E. khodadadi, and F. M. Talaat, “Automated Detection and Segmentation of COVID-19 Infection using Machine Learning,” Journal of Artificial Intelligence and Metaheuristics, vol. 3, no. 2, pp. 28–37, 2023, doi: 10.54216/JAIM.030203.
policy

Publisher's Note

The statements, opinions, and data presented in this article are solely those of the author(s) and do not necessarily represent those of ASPG, the journal, or its editors. ASPG and the editors disclaim responsibility for any harm arising from the use of any ideas, methods, instructions, or products described in this article, to the fullest extent permitted by applicable law.

Digital Archive Ready