Image-Based Classification of Healthy and Unhealthy Goats Using ResNet-18 Deep Learning Model - Amin, Nurrochim Amin Putra; Wardhana, Ajie Kusuma (Journal of Applied Informatics and Computing, 2025)
Early detection of livestock health conditions is a critical factor in maintaining animal productivity and welfare. This study aims to develop an image-based classification system for identifying healthy and unhealthy goats using deep learning techniques. The dataset of goat images was obtained from Roboflow and processed through a series of augmentation, normalization, and feature extraction stages using the ResNet-18 convolutional neural network architecture pretrained on ImageNet. The dataset was divided into training and testing sets with a 70:30 stratified split to ensure balanced class distribution. To address class imbalance, a random undersampling technique was applied. The model was trained using optimally tuned hyperparameters, including the Adam optimizer, cross-entropy loss function, a batch size of 32, and 20 epochs. Evaluation results showed that the model achieved an accuracy of 95.97%, with a precision of 96.22%, recall of 95.97%, and F1-score of 95.92%. The confusion matrix and evaluation curves demonstrated that the model is both stable and reliable. These findings indicate that the proposed system has strong potential to be implemented in automated and real-time livestock health monitoring applications, providing a fast, accurate, and non-invasive solution for precision livestock farming.