Facial chick sexing: An automated chick sexing system from chick facial image

Mathieu Rodriguez, Tran-Dac-Thinh Phan, Arthur Fernandes, Vivian Breen, Jesus Arango, Michael T. Kidd, Ngan Le

TL;DR

This paper introduces an automated, non-invasive system for sexing day-old chicks using facial image analysis, inspired by human gender recognition techniques. By leveraging deep learning models like ResNet-50, they achieve promising accuracy, offering a more humane and efficient alternative to traditional methods.

What Problem Does This Paper Address?

Accurately determining the sex of day-old chicks (chick sexing) is crucial for the poultry industry, impacting production efficiency and profitability. Traditional methods like vent sexing are invasive, require extensive expert training, and can cause stress or injury to the chicks. Wing feather sexing is limited to specific breeds. This paper addresses the need for a non-invasive, automated, and expert-free method that can be applied universally, aiming to improve animal welfare and operational efficiency.

Methods

The authors developed a comprehensive system with five key components:

  1. Chick Face Localization: They employed a pre-trained YOLOv5 object detection model, fine-tuned on manually annotated chick faces, to accurately identify and draw bounding boxes around the chicks' faces.
  2. Keypoint Detection: A High-Resolution Network (HRNet) model, adapted from human pose estimation, was trained to detect seven crucial facial landmarks (eyes, beak, nose).
  3. Face Alignment: A geometric algorithm was developed to align the chick's face to a frontal or near-frontal pose, correcting for variations in head position and pose (pitch, yaw, roll).
  4. Data Preparation: Two types of image crops were generated: "Cropped Full Face" (entire face within the bounding box) and "Cropped Middle Face" (focusing on the central facial features).
  5. Gender Classification: Several deep learning backbone networks (AlexNet, EfficientNet-B0, Inception-V3, ResNet-50, ResNet-101, VGG-16) were trained and evaluated. These models, pre-trained on ImageNet, were fine-tuned with modified fully connected layers and a sigmoid function for binary classification.

Datasets

The study utilized a newly created dataset of 5,727 facial images of day-old chicks, captured from 184 female and 169 male chicks. This dataset was meticulously annotated by poultry experts and computer vision experts for face location, keypoints, and gender.

Key Insights and Ideas

  • Human-inspired approach works for chicks: The core idea of adapting human facial gender recognition techniques to chicks proved viable, demonstrating that facial features, even in young birds, hold discriminative information.
  • ResNet-50 excels: The ResNet-50 architecture consistently outperformed other models across various metrics, highlighting its robustness in extracting relevant facial features for chick sexing.
  • Cropping matters: The "Cropped Full Face" dataset generally yielded better results than the "Cropped Middle Face," suggesting that while focusing on key features is important, over-cropping might lead to the loss of crucial gender-differentiating information.
  • Grad-CAM++ reveals attention: Visualizations using Grad-CAM++ showed that the ResNet-50 model primarily focuses on the beak and comb areas, which are key anatomical features for sex determination.

Key Results

The system achieved a promising 81.89% accuracy on the "Cropped Full Face" dataset. Specifically, the ResNet-50 model achieved the highest accuracy of 81.98% on the "Cropped Full Face" dataset and 80.46% on the "Cropped Middle Face" dataset. The study also demonstrated that the ResNet-50 model exhibited a more balanced distribution of misclassifications between genders compared to other backbones.

Limitations and Future Work

The authors acknowledge several limitations:

  • Dataset Size: The dataset, while carefully annotated, was not extensive. A larger and more diverse dataset could improve model robustness.
  • Hyperparameter Tuning: Further tuning of hyperparameters might be necessary to optimize model performance.
  • Environmental Factors: Variations in lighting, background, and chick stillness can impact accuracy.

Future work could focus on:

  • Integration with Vaccination: Integrating the system into existing vaccination machinery to capture frontal faces during the process, enabling simultaneous vaccination and sexing.
  • Real-time Processing: Developing high-speed image processing and real-time capabilities for industrial application.
  • Addressing Cropping Impact: Further research into optimal cropping strategies to retain essential features without losing critical information.

Summary updated

Abstract

Chick sexing, the process of determining the gender of day-old chicks, is a critical task in the poultry industry due to the distinct roles that each gender plays in production. While effective traditional methods achieve high accuracy, color, and wing feather sexing is exclusive to specific breeds, and vent sexing is invasive and requires trained experts. To address these challenges, we propose a novel approach inspired by facial gender classification techniques in humans: facial chick sexing . This new method does not require expert knowledge and aims to reduce training time while enhancing animal welfare by minimizing chick manipulation. We develop a comprehensive system for training and inference that includes data collection, facial and keypoint detection, facial alignment, and classification. We evaluate our model on two sets of images: Cropped Full Face and Cropped Middle Face, both of which maintain essential facial features of the chick for further analysis. Our experiment demonstrates the promising viability, with a final accuracy of 81.89% on the Cropped Full Face set, of this approach for future practices in chick sexing by making them more universally applicable. • Dataset: 5,727 one-day-old chick face images, annotated by poultry and vision experts. • Automated chick sexing: Uses deep learning for accurate gender classification. • Method: Chick face localization, keypoint detection, alignment and classification. • End-to-End framework: provides efficient and automated chick sexing solution.
BibTeX
@misc{rodriguez2024facial,
  author = {Mathieu Rodriguez and Tran-Dac-Thinh Phan and Arthur Fernandes and Vivian Breen and Jesus Arango and Michael T. Kidd and Ngan Le},
  title = {{Facial chick sexing: An automated chick sexing system from chick facial image}},
  year = {2024},
  eprint = {2410.09155},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2410.09155},
}
Figure