journal article·2025-08-19Open access

Video-Based CSwin Transformer Using Selective Filtering Technique for Interstitial Syndrome Detection

Khalid Moafa, Maria Antico, Christopher Edwards, Marian Steffens, Jason Dowling, David Canty, Davide Fontanarosa

Applied Sciences· Volume 15· Issue 16

Abstract

Interstitial lung diseases (ILD) significantly impact health and mortality, affecting millions of individuals worldwide. During the COVID-19 pandemic, lung ultrasonography (LUS) became an indispensable diagnostic and management tool for lung disorders. However, utilising LUS to diagnose ILD requires significant expertise. This research aims to develop an automated and efficient approach for diagnosing ILD from LUS videos using AI to support clinicians in their diagnostic procedures. We developed a binary classifier based on a state-of-the-art CSwin Transformer to discriminate between LUS videos from healthy and non-healthy patients. We used a multi-centric dataset from the Royal Melbourne Hospital (Australia) and the ULTRa Lab at the University of Trento (Italy), comprising 60 LUS videos. Each video corresponds to a single patient, comprising 30 healthy individuals and 30 patients with ILD, with frame counts ranging from 96 to 300 per video. Each video is annotated using the corresponding medical report as ground truth. The datasets used for training the model underwent selective frame filtering, including reduction in frame numbers to eliminate potentially misleading frames in non-healthy videos. This step was crucial because some ILD videos included segments of normal frames, which could be mixed with the pathological features and mislead the model. To address this, we eliminated frames with a healthy appearance, such as frames without B-lines, thereby ensuring that training focused on diagnostically relevant features. The trained model was assessed on an unseen, separate dataset of 12 videos (3 healthy and 9 ILD) with frame counts ranging from 96 to 300 per video. The model achieved an average classification accuracy of 91%, calculated as the mean of three testing methods: Random Sampling (92%), Key Featuring (92%), and Chunk Averaging (89%). In RS, 32 frames were randomly selected from each of the 12 videos, resulting in a classification with 92% accuracy, with specificity, precision, recall, and F1-score of 100%, 100%, 90%, and 95%, respectively. Similarly, KF, which involved manually selecting 32 key frames based on representative frames from each of the 12 videos, achieved 92% accuracy with a specificity, precision, recall, and F1-score of 100%, 100%, 90%, and 95%, respectively. In contrast, the CA method, where the 12 videos were divided into video segments (chunks) of 32 consecutive frames, with 82 video segments, achieved an 89% classification accuracy (73 out of 82 video segments). Among the 9 misclassified segments in the CA method, 6 were false positives and 3 were false negatives, corresponding to an 11% misclassification rate. The accuracy differences observed between the three training scenarios were confirmed to be statistically significant via inferential analysis. A one-way ANOVA conducted on the 10-fold cross-validation accuracies yielded a large F-statistic of 2135.67 and a small p-value of 6.7 × 10−26, indicating highly significant differences in model performance. The proposed approach is a valid solution for fully automating LUS disease detection, aligning with clinical diagnostic practices that integrate dynamic LUS videos. In conclusion, introducing the selective frame filtering technique to refine the dataset training reduced the effort required for labelling.
Source: crossref · Quality: baseline

Research context

OpenAlex topics: Neuroscience and Neural Engineering · Advanced Chemical Sensor Technologies · Microbial Inactivation Methods

SciVX discovery tags are terminology-based. OpenAlex topics are source-provided classifications.

Affiliations

School of Clinical Sciences, Faculty of Health, Queensland University of Technology, Brisbane, QLD 4000, Australia

College of Nursing and Health Sciences, Jazan University, Jazan 82911, Saudi Arabia

Centre for Biomedical Technologies (CBT), Queensland University of Technology, Brisbane, QLD 4000, Australia

Australian e-Health Research Centre, The Commonwealth Scientific and Industrial Research Organisation (CSIRO), Brisbane, QLD 4029, Australia

Department of Surgery (Royal Melbourne Hospital), University of Melbourne, Royal Parade, Parkville, VIC 3050, Australia

References (44)

Show source-provided references
1. Usefulness of lung ultrasound B-lines in connective tissue disease-associated interstitial lung disease: A literature review10.1186/s13075-017-1409-7 ↗
2. Jeganathan, N., Corte, T.J., and Spagnolo, P. (2024). Editorial: Epidemiology and risk factors for interstitial lung diseases. Front. Med., 11.10.3389/fmed.2024.1384825 ↗
3. Lung B-line artefacts and their use10.21037/jtd.2016.04.55 ↗
4. State of the Art in Lung Ultrasound, Shifting from Qualitative to Quantitative Analyses10.1016/j.ultrasmedbio.2022.07.007 ↗
5. International evidence-based recommendations for point-of-care lung ultrasound10.1007/s00134-012-2513-4 ↗
6. The comet tail artifact10.7863/jum.1982.1.1.1 ↗
7. The Comet-tail Artifact. An ultrasound sign of alveolar-interstitial syndrome10.1164/ajrccm.156.5.96-07096 ↗
8. What’s new in lung ultrasound during the COVID-19 pandemic10.1007/s00134-020-06048-9 ↗
9. Lung Ultrasonography May Provide an Indirect Estimation of Lung Porosity and Airspace Geometry10.1159/000368086 ↗
10. Lung ultrasound: Are we diagnosing too much?10.1186/s13089-023-00313-w ↗
11. Lung ultrasound: The essentials10.1148/ryct.2021200564 ↗
12. Wang, J., Yang, X., Zhou, B., Sohn, J.J., Zhou, J., Jacob, J.T., Higgins, K.A., Bradley, J.D., and Liu, T. (2022). Review of Machine Learning in Lung Ultrasound in COVID-19 Pandemic. J. Imaging, 8.10.3390/jimaging8030065 ↗
13. A Review of Deep Learning Applications in Lung Ultrasound Imaging of COVID-19 Patients10.34133/2022/9780173 ↗
14. Machine Learning Algorithm Detection of Confluent B-Lines10.1016/j.ultrasmedbio.2023.05.016 ↗
15. Quantitative lung ultrasonography: A putative new algorithm for automatic detection and quantification of B-lines10.1186/s13054-019-2569-4 ↗
16. Automated detection of pneumonia in lung ultrasound using deep video classification for COVID-1910.1016/j.imu.2021.100687 ↗
17. Kulhare, S., Zheng, X., Mehanian, C., Gregory, C., Zhu, M., Gregory, K., Xie, H., Jones, J.M., and Wilson, B. (2018). Ultrasound-Based Detection of Lung Abnormalities Using Single Shot Detection Convolutional Neural Networks. Simulation, Image Processing, and Ultrasound Systems for Assisted Diagnosis and Navigation, Springer.10.1007/978-3-030-01045-4_8 ↗
18. Ultrasound on the Frontlines of COVID-19: Report from an International Webinar10.1111/acem.14004 ↗
19. Deep Learning for Detection and Localization of B-Lines in Lung Ultrasound10.1109/JBHI.2023.3282596 ↗
20. Pare, J.R., Gjesteby, L.A., Telfer, B.A., Tonelli, M.M., Leo, M.M., Billatos, E., Scalera, J., and Brattain, L.J. (2022, January 11–15). Transfer Learning for Automated COVID-19 B-Line Classification in Lung Ultrasound. Proceedings of the 2022 44th Annual International Conference of the IEEE Engineering in Medicine & Biology Society (EMBC), Glasgow, UK.10.1109/EMBC48229.2022.9871894 ↗
21. Quantitative Analysis of Pleural Line and B-Lines in Lung Ultrasound Images for Severity Assessment of COVID-19 Pneumonia10.1109/TUFFC.2021.3107598 ↗
22. Development of a convolutional neural network to differentiate among the etiology of similar appearing pathological B lines on lung ultrasound: A deep learning study10.1136/bmjopen-2020-045120 ↗
23. Perera, S., Adhikari, S., and Yilmaz, A. (2021, January 19–22). Pocformer: A Lightweight Transformer Architecture for Detection of COVID-19 Using Point Of Care Ultrasound. Proceedings of the 2021 IEEE International Conference on Image Processing (ICIP), Anchorage, AK, USA.10.1109/ICIP42928.2021.9506353 ↗
24. Real-time automatic tumor segmentation for ultrasound-guided breast-conserving surgery navigation10.1007/s11548-022-02658-4 ↗
25. Kumar, V., Webb, J.M., Gregory, A., Denis, M., Meixner, D.D., Bayat, M., Whaley, D.H., Fatemi, M., Alizad, A., and Fan, Y. (2018). Automated and real-time segmentation of suspicious breast masses using convolutional neural network. PLoS ONE, 13.10.1371/journal.pone.0195816 ↗
26. Real-time carotid plaque recognition from dynamic ultrasound videos based on artificial neural network10.1055/a-2180-8405 ↗
27. Nurmaini, S., Nova, R., Sapitri, A.I., Rachmatullah, M.N., Tutuko, B., Firdaus, F., Darmawahyuni, A., Islami, A., Mandala, S., and Partan, R.U. (2024). A Real-Time End-to-End Framework with a Stacked Model Using Ultrasound Video for Cardiac Septal Defect Decision-Making. J. Imaging, 10.10.3390/jimaging10110280 ↗
28. Zhang, T.-T., Shu, H., Tang, Z.-R., Lam, K.-Y., Chow, C.-Y., Chen, X.-J., Li, A., and Zheng, Y.-Y. (2023). Weakly supervised real-time instance segmentation for ultrasound images of median nerves. Comput. Biol. Med., 162.10.1016/j.compbiomed.2023.107057 ↗
29. Ou, Z., Bai, J., Chen, Z., Lu, Y., Wang, H., Long, S., and Chen, G. (2024). RTSeg-net: A lightweight network for real-time segmentation of fetal head and pubic symphysis from intrapartum ultrasound images. Comput. Biol. Med., 175.10.1016/j.compbiomed.2024.108501 ↗
30. Khan, U., Afrakhteh, S., Mento, F., Mert, G., Smargiassi, A., Inchingolo, R., Tursi, F., Macioce, V.N., Perrone, T., and Iacca, G. (2024). Low-complexity lung ultrasound video scoring by means of intensity projection-based video compression. Comput. Biol. Med., 169.10.1016/j.compbiomed.2023.107885 ↗
31. Dong, X., Bao, J., Chen, D., Zhang, W., Yu, N., Yuan, L., and Guo, B. (2021). CSWin Transformer: A General Vision Transformer Backbone with Cross-Shaped Windows. arXiv.10.1109/CVPR52688.2022.01181 ↗
32. Al-Hammuri, K., Gebali, F., Kanan, A., and Chelvan, I.T. (2023). Vision transformer architecture and applications in digital health: A tutorial and survey. Vis. Comput. Ind. Biomed. Art, 6.10.1186/s42492-023-00140-9 ↗
33. He, K., Gan, C., Li, Z., Rekik, I., Yin, Z., Ji, W., Gao, Y., Wang, Q., Zhang, J., and Shen, D. (2022). Transformers in Medical Image Analysis: A Review. arXiv.
34. Transforming medical imaging with Transformers? A comparative review of key properties, current progresses, and future perspectives10.1016/j.media.2023.102762 ↗
35. Vafaeezadeh, M., Behnam, H., and Gifani, P. (2024). Ultrasound Image Analysis with Vision Transformers—Review. Diagnostics, 14.10.20944/preprints202401.0309.v1 ↗
36. Privacy Image Secrecy Scheme Based on Chaos-Driven Fractal Sorting Matrix and Fibonacci Q-Matrix10.1007/s00371-025-04014-4 ↗
37. Image privacy protection scheme based on high-quality reconstruction DCT compression and nonlinear dynamics10.1016/j.eswa.2024.124891 ↗
38. Intrusion detection-embedded chaotic encryption via hybrid modulation for data center interconnects10.1364/OL.566608 ↗
39. Lung ultrasound in the assessment of interstitial lung disease in patients with connective tissue disease: Performance in comparison with high-resolution computed tomography10.1093/mr/roae053 ↗
40. TransMorph: Transformer for unsupervised medical image registration10.1016/j.media.2022.102615 ↗
41. SciPy 1.0: Fundamental algorithms for scientific computing in Python10.1038/s41592-019-0686-2 ↗
42. Seabold, S., and Perktold, J. (July, January 28). Statsmodels: Econometric and Statistical Modeling with Python. Proceedings of the 9th Python in Science Conference, Austin, TX, USA.
43. The sound of air: Point-of-care lung ultrasound in perioperative medicine10.1007/s12630-018-1062-x ↗
44. Vertical Artifacts as Lung Ultrasound Signs: Trick or Trap? Part 2-An Accademia di Ecografia Toracica Position Paper on B-Lines and Sonographic Interstitial Syndrome10.1002/jum.16116 ↗