# Detection of Threats to Farm Animals Using Deep Learning Models: A Comparative Study
## 5 Discussion
\begin{table}
\begin{tabular}{c c c} \hline
**Source** & **Dataset** & **Accuracy** \\ \hline [PERSON] et al. [16] & Snapshot Serengeti, 3.2 million images & ResNet-18 93.8\% \\ \hline [PERSON] et al. [17] & Surveillance videos & 92.49\% \\ \hline [PERSON] et al. [15] & 8629 cattle images & NasNet Large 95\% \\ \hline [PERSON] et al. [13] & 11,000 laying hens & Faster R-CNN 89.6\% \\ \hline [PERSON] et al. [14] & Side-view images of dairy cows & AlexNet 96.65\% \\ \hline [PERSON] et al. [18] and [PERSON] et al. [19] & Images captured by UAVs & YoloV2 F-Score of 95.2\% \\ \hline [PERSON] et al. [35] & 7363 fox images & YoloV4 100\% \\ \hline [PERSON] et al. [36] & 1068 deer & HOG-CNN \%91 \\ \hline [PERSON] et al. [20] & Snake detection & YOLOv5 87\% \\ \hline [PERSON] et al. [37] & Websites with publicly available & YoloV5s 94\% \\ \hline [PERSON] et al. [38] & 13 wild spaces & YoloV5 90\% \\ \hline [PERSON] et al. [39] & 164 (cows, deer, and horses) & YoloV7 85\% \\ \hline [PERSON] et al. [40] & 1000 images, 9 specific & YoloV4 98\% \\ \hline [PERSON] et al. [41] & 8407 images & Scaled-YoloV4 82\% \\ \hline Our study & 2462 images, 7 specific & YoloV8 93\% \\ \hline \end{tabular}
\end{table} 
Table 6: Comparative accuracy of different deep learning models in animal detection studies. multiple animal species in various environmental contexts. This performance is notably superior to that of [PERSON] et al. (2019) and [PERSON] et al. (2019), who used other Yolo variants on larger datasets but achieved lower accuracies. This variability in accuracy across studies underscores the importance of model selection tailored to specific data characteristics and detection requirements. The high performance of models like YoloV4 and YoloV5 in our study and others suggests that advancements in Yolo architecture have progressively enhanced the ability to handle complex detection tasks effectively. Moreover, the wide range of accuracies observed highlights the ongoing need for improvements in model robustness and generalization capabilities, ensuring that deep learning tools remain versatile and effective across the evolving challenges of wildlife monitoring and agricultural management. In conclusion, this research underscores the significant potential of deep learning-based object detection technologies in protecting farm animals and enhancing farm security. The class-based performance analysis of the models demonstrates the need to customize the model parameters based on the characteristics to distinguish various animal species effectively. This provides valuable insights for future work on model selection and adjustments. This study once again proves that using deep learning models in animal detection and classification offers valuable solutions for practical applications. Future research on model optimization and customization is expected to play a central role in farm management and animal protection strategies. In this context, the further development and testing of models under real-world conditions will be the focus of future research in this field. Conceptualization, A.K. and M.T.A. ; methodology, A.K. ; software, A.K., M.T.A. and S.K. ; validation, A.K., M.T.A., S.K., T.I. and I.S. ; investigation, A.K., M.T.A., S.K., T.I. and I.S. ; writing--original draft preparation, A.K., M.T.A., S.K., T.I. and I.S. ; writing--review and editing, A.K., M.T.A., S.K., T.I. and I.S. ; visualization, A.K., M.T.A., S.K., T.I. and I.S. All authors have read and agreed to the published version of the manuscript. This study was financed by the European Union-Next Generation EU, through the National Recovery and Resilience Plan of the Republic of Bulgaria, project No BG-RFP-2.013-0001-C01. Not applicable. The authors declare no conflicts of interest.