Attention-driven Diagnosis: Enhancing Chicken Disease Prediction from Fecal Imagery

Kenechukwu Sylvanus Anigbogu

Department of Computer Science, Nnamdi Azikiwe University, Nigeria.

Joshua Makuo Nwankpa

Department of Computer Science, Nnamdi Azikiwe University, Nigeria.

Okwuchukwu Ejike Chukwuogo

Department of Computer Science, Nnamdi Azikiwe University, Nigeria.

Chinedu Emmanuel Mbonu *

Department of Computer Science, Nnamdi Azikiwe University, Nigeria and Department of Computer Science, Nazarbayev University, Astana, Kazakhstan.

*Author to whom correspondence should be addressed.


Abstract

Background: Poultry farming is essential for food security, but traditional disease detection is inefficient, making AI-driven CNN models a powerful solution for accurate and automated diagnosis.

Aims: This study aims to develop and evaluate an enhanced deep learning-based framework for the automated classification of poultry diseases using fecal images to address the limitations of traditional manual inspection.

Study Design: The research utilizes a comparative experimental design, evaluating two distinct deep learning architectures; ResNet50 and Vision Transformer (ViT) on a multiclass dataset.

Methodology: A dataset of 8,067 annotated fecal images representing four classes (Coccidiosis, Healthy, Newcastle Disease, and Salmonella) was partitioned using a stratified 80/20 split. Both models were initialized with pretrained ImageNet weights and subjected to selective fine-tuning (unfreezing the last two layers of ResNet50 and the last two encoder blocks of ViT) alongside data augmentation and 5-fold cross-validation.

Results: The Vision Transformer (ViT) outperformed the ResNet50 model, achieving a state-of-the-art accuracy of 96.16% and a macro F1-score of 0.96, compared to 94.49% accuracy and a 0.94 F1-score for ResNet50. Notably, ViT showed superior performance in detecting Newcastle Disease (NCD), increasing recall to 0.91, a 6% improvement over ResNet50.

Conclusion: The results demonstrate that while traditional CNNs like ResNet50 provide strong baselines, transformer-based architectures excel at capturing global contextual relationships, making them more robust for accurate real-time poultry disease diagnostics.

Our code is available on https://github.com/NedumCares/Chicken-Disease-Prediction.

Keywords: Vision transformer (ViT), ResNet50, poultry disease classification, fecal image analysis, deep learning, avian health monitoring, precision agriculture, Newcastle disease


How to Cite

Anigbogu, Kenechukwu Sylvanus, Joshua Makuo Nwankpa, Okwuchukwu Ejike Chukwuogo, and Chinedu Emmanuel Mbonu. 2026. “Attention-Driven Diagnosis: Enhancing Chicken Disease Prediction from Fecal Imagery”. Journal of Engineering Research and Reports 28 (5):71-84. https://doi.org/10.9734/jerr/2026/v28i51884.

Downloads

Download data is not yet available.