Hyperparameter Optimization with Hyperband for Tuberculosis Classification - Yovi Ibnu Nasikhin; Basuki Rahmat; Chrystia Aji Putra (Komunitas Dosen Indonesia, 2025)
Tuberculosis (TB) is an infectious illness that continues to be a major global health challenge due to its high rates of disease and death. Early detection of TB using chest X-ray images often faces challenges related to subjective interpretation by radiologists and limited sensitivity and specificity. This study develops a Convolutional Neural Network (CNN) model to classify chest X-ray images into Normal and Tuberculosis classes, using a total of 2,198 chest X-ray images consisting of 1,173 Normal and 1,025 Tuberculosis samples. Hyperparameter optimization was carried out using the Hyperband algorithm implemented in the Keras Tuner framework to obtain the best parameter combination that produced optimal model performance. The main hyperparameters tuned included the number of dense layers, the number of units per layer, dropout rate, and learning rate. The optimization process yielded the best configuration consisting of two dense layers with 160 and 64 units, a dropout rate of 0.3, and a learning rate of 0.0011. The optimization process increased the model’s accuracy from 0.84 to 0.88 and reduced the validation loss from 0.44 to 0.34, indicating a more stable and effective learning outcome after optimization using Hyperband. The application of Hyperband successfully enhanced learning stability, accelerated convergence, and improved overall model performance. These results indicate that hyperparameter optimization using Hyperband not only enhances CNN-based TB classification accuracy but also strengthens its potential clinical utility by supporting more consistent, rapid, and objective early diagnosis in real-world healthcare settings.