AI-Powered Poultry Farming: Enhancing Accuracy with Synthetic Data
Modern poultry farming increasingly incorporates deep learning techniques to automate tasks such as bird detection, animal counting, behavior analysis, and mortality detection, aiming to optimize production and ensure animal welfare. While these technologies offer significant potential for improving efficiency, sustainability, and resource management, their effective implementation faces challenges. Key among these are the variable conditions in farm environments, the scarcity of data for training robust models, and the labor-intensive nature of traditional monitoring practices. To address these challenges, this study explores the use of computer vision and generative artificial intelligence (GenAI) to enhance animal detection and tracking, enabling more accurate and scalable farm management. By leveraging AI-driven solutions, farmers can gain data-driven insights and automate processes, reducing costs and improving productivity in modern poultry farming. The following experiments were part of PhD research efforts by mr Stevan Cakic and resultet in a publication in a scientific journal [link].

Solution
This research introduces a solution that combines real and synthetic images to train deep learning models for improved poultry monitoring. A hybrid dataset was created, blending real images from a poultry farm with synthetic images generated by the FLUX.1 model, to mitigate the need for extensive real-world data collection. The YOLOv9 model, chosen for its strong performance in object detection tasks, was trained on this dataset to accurately detect chickens. To streamline the dataset preparation process, automated annotation techniques utilizing Grounding DINO and SAM2 were employed to label the images, significantly reducing the manual effort typically required. This resaearch was done in the context of HPC4S3ME project [link] with a support from NCC Montenegro (EuroCC2 and EuroCC4SEE).

The computational demands of training deep learning models and generating synthetic data can be substantial. In this context, High-Performance Computing (HPC) plays a crucial role. In this study, A100 GPUs were used for efficient model training, and Replicate was employed for fine-tuning FLUX.1 with H100 GPUs. HPC resources can expedite the training process, allowing for faster experimentation and optimization of models. Furthermore, HPC can facilitate the generation of larger synthetic datasets and enable the processing of high-resolution images, potentially leading to more accurate and robust AI solutions for poultry farming.

The experiments demonstrated that models trained on a balanced combination of real and synthetic images achieved comparable accuracy to those trained on larger real-only datasets. Notably, the model trained on a mix of 300 real and 100 synthetic images achieved a mean average precision (mAP) of 0.829.
Benefits
This research demonstrates several benefits of using AI and synthetic data in poultry farming:
- Reduced data dependency: The use of synthetic data reduces the need for extensive and costly real-world image collection.
- Improved model generalization: Combining synthetic and real data enhances the model’s ability to generalize across different conditions, leading to more robust performance.
- Streamlined annotation: Automated annotation tools decrease the manual effort required for dataset labeling, saving time and resources.
- Enhanced efficiency: AI-driven monitoring can automate tasks such as chicken counting, growth assessment, and mortality detection, improving overall farm efficiency and productivity.