Journal of Artificial Intelligence and Engineering Applications (JAIEA)
Vol. 5 No. 2 (2026): February 2026

Classification of Pneumonia Using CNN and Vision Transformer

Shomsomi, Ma`dan (Unknown)
Triawan, Widhaksa (Unknown)
Purwadi (Unknown)



Article Info

Publish Date
15 Feb 2026

Abstract

Pneumonia remains one of the leading causes of mortality among children worldwide. This study aims to evaluate the performance of two deep learning architectures, Convolutional Neural Network (CNN) and Vision Transformer (ViT), for pneumonia classification using chest X-ray images. Four training scenarios were examined, consisting of MobileNetV2 baseline, MobileNetV2 fine-tuned, ViT baseline, and ViT fine-tuned models. The dataset was obtained from the Chest X-Ray Images (Pneumonia) collection and was processed through augmentation and preprocessing to produce a balanced set of 9,000 images. Baseline models were trained using a feature extraction approach, while fine-tuning was conducted by selectively unfreezing internal layers. Experimental results show that all models achieved accuracy above 95%. The MobileNetV2 baseline reached 97.63%, while its fine-tuned counterpart did not yield further improvement, achieving 97.41%. In contrast, the Vision Transformer demonstrated substantial performance gains, where partial fine-tuning produced the highest accuracy of 98.59% with an f1-score of 0.99. These findings indicate that ViT with targeted fine-tuning is more effective in capturing global representations within X-ray images, making it a strong candidate for computer-aided pneumonia detection systems supported by artificial intelligence.

Copyrights © 2026






Journal Info

Abbrev

JAIEA

Publisher

Subject

Automotive Engineering Computer Science & IT Control & Systems Engineering

Description

The Journal of Artificial Intelligence and Engineering Applications (JAIEA) is a peer-reviewed journal. The JAIEA welcomes papers on broad aspects of Artificial Intelligence and Engineering which is an always hot topic to study, but not limited to, cognition and AI applications, engineering ...