Object Detection Algorithm for Pigs Based on Dual Dilated Layer and Rotary Box Location
CSTR:
Author:
Affiliation:

Clc Number:

Fund Project:

  • Article
  • |
  • Figures
  • |
  • Metrics
  • |
  • Reference
  • |
  • Related
  • |
  • Cited by
  • |
  • Materials
  • |
  • Comments
    Abstract:

    At present, the target detection algorithm based on horizontal box is applied to pig objection detection. The adhesion and mutual occlusion in the image of pigs bring great difficulty to individual pig detection. The image of pig has a large ratio of length to width and may rotate at any angle. Object detection algorithm for group pig images based on dual dilated layer and rotary box location network (DR-Net) was proposed. Images of pigs was collected in three pig farms. A dynamic clustering method based on histogram feature and singular value decomposition was used to extract the key frames of pig videos, Laplace operator was used to eliminate images with unclear targets. There were 9600 images as the data set after data enhancement. The outline of the pig with rotary box was marked. Data set was divided into training set, verification set and test set according to 8∶1∶1. Dual dilated layer used the residual structure and combined two convolution with different dilation factors. The receptive field was increased exponentially with the increase of layers. Stacking dual dilated layers can obtain very large receptive field, it can help the model understand the global information of the image with fewer parameters. Every pig target was located in a rotary box and represented by five parameters. In training, regression loss calculation method based on Gaussian Wasserstein distance was used. The model can get prediction results more accurate. In DR-Net, the features of the input image was extracted by dual dilated layer. The CSP layer containing multi-layer Res2Net module, which was used to feature fusion and feature extraction of different scales. The prediction results were output through head network. The results showed that the precision, recall, mean average precision, MAE and RMSE of DR-Net were 98.57%, 97.27%, 96.94%, 0.21 and 0.54, respectively. DR-Net was superior to YOLO v5 and YOLO v5 with rotary box location and pig target recognition accuracy was improved. By analyzing the visualization feature map, DR-Net can accurately locate the target using the head, neck, back or tail feature of pigs under occlusion and adhesion condition. The research can contribute to the construction of intelligent pig farm and provide reference for the subsequent research on pig behavior recognition.

    Reference
    Related
    Cited by
Get Citation
Share
Article Metrics
  • Abstract:
  • PDF:
  • HTML:
  • Cited by:
History
  • Received:June 30,2022
  • Revised:
  • Adopted:
  • Online: September 09,2022
  • Published:
Article QR Code