With the continuous expansion of breeding scale, the automatic counting of sheep has attracted a lot of research attention in recent years, which aims to count the number of sheep in real time to rationally use grassland resources and design appropriate agricultural production policies. The traditional method of counting sheep mainly relies on manual work, which is time-consuming and labor-intensive. Thanks to the rapid development of image acquisition equipment and pattern recognition technology, the recognition and counting of sheep based on deep learning has become the current mainstream counting framework. However, for dense flocks of sheep, such as occlusions between sheep, the accuracy of existing methods cannot meet the needs of practical applications. In this paper, we suggest FamNet, a few-shot sheep counting method based on UAV images and density map regression. Specifically, we first collected 190 sheep images with different resolutions, aspect ratios, backgrounds, and sheep numbers; secondly, by selecting count samples to extract objects in the images, and using density map regression to predict the number of sheep, this enables sheep counting in small numbers of samples. A large number of experimental results have verified the effectiveness of the method in this paper, which can achieve an average counting accuracy of 91.02%. In addition, we discuss the impact of sample selection, backbone selection, and feature scaling on model accuracy. All the results show that the FamNet flock counting method proposed in this paper can be applied to flock counting, has good adaptability to flock counting under different background conditions and can count the number of flocks in a timely and effective manner.
Read full abstract