In recent years, convolutional neural networks (CNNs) have achieved amazing success in a variety of image categorization tasks. However, the architecture of CNNs has a significant impact on their performance. The designs of the most cutting-edge CNNs are frequently hand-crafted by experts in both CNNs and the topics under investigation. As a result, it's tough for users who don't have a lot of experience with CNNs to come up with the best CNN architecture for their individual image categorization challenges. This work investigates the application of the Fibonacci numbers to efficiently solve picture classification challenges by utilizing the hyperparameter of image dimension of COVID and non-COVID x-ray images. The suggested algorithm's greatest strength is the development of a CNN model that can be utilized for COVID viral prognosis using x-ray images to supplement existing COVID pandemic testing techniques. The proposed approach is tested using the metrics of training time, accuracy, precision, recall, and F1-score on commonly used benchmark image classification datasets. According to the experimental data, the CNN model with an image dimension of 55 x 55 surpasses the other CNN models in terms of training time, accuracy, recall, and F1-score. Several issues were raised about how to choose the best CNN models for prognostic picture categorization.