# YoloSortC3D: A YOLOv8, DeepSort, and C3D-Based Method for Sheep Rumination Behavior Recognition
## 1 Introduction  
Sheep, classified under the class Mammalia, order Artiodactyla, and family Bovidae, are among the most prevalent livestock globally. In regions such as the Middle East, Africa, South Asia, and Central Asia, sheep serve as a primary source of meat and textiles. Notably, the wool industry is of significant global importance, particularly in Australia and New Zealand. In mountainous and remote areas of Europe and the Americas, sheep's ability to adapt to complex terrains makes them essential livestock [1]. Additionally, sheep milk, a nutrient-dense dairy product, has gained increasing popularity in recent years, emerging as a growing segment within the dairy industry. It not only meets consumer demand but also plays a vital role in promoting rural revitalization [2]. Moreover, sheep farming has a substantial impact on ecological management, contributing to the mitigation of grassland degradation and the enhancement of biodiversity. As sheep farming scales up and intensifies, accurately monitoring sheep behavior has become essential for assessing their physiological health [3]. The early detection of abnormal behavior, followed by timely interventions, can help mitigate economic losses for farms [4]. Rumination is a characteristic behavior of ruminants, such as cattle and sheep, and monitoring sheep rumination is crucial for effective health surveillance. Changes in rumination duration are closely linked to the health and physiological status of sheep [5]. Healthy sheep typically exhibit continuous and vigorous rumination; whereas, sick sheep ruminate more slowly or may cease ruminating entirely. The gradual recovery of rumination after treatment is a key indicator of health improvement [6]. Currently, rumination monitoring predominantly relies on manual observation by farm workers or contact-based devices equipped with sensors, such as pressure sensors [7; 8; 9], acoustic sensors [10; 11; 12], and triaxial accelerometers [13; 14; 15; 16]. While these contact-based devices can accurately capture rumination behavior to some extent, their use may induce stress in animals, potentially compromising animal welfare. Furthermore, the high cost and fragility of such devices limit their feasibility in large-scale farming operations. In this context, using computer vision methods to automatically detect and recognize sheep rumination behavior without direct contact with the animals is more appropriate. Research on the application of computer vision to animal rumination behavior remains relatively limited. [PERSON] et al. [17] developed a rumination detection algorithm for dairy cows by combining the YOLO algorithm with Kernel correlation filters (KCF) and using the frame difference method, achieving effective rumination recognition. [PERSON] et al. [18] applied Kalman filtering and the Hungarian algorithm to track the upper jaw region of cows and correlated it with the lower jaw to generate mouth movement curves, which were then used to extract rumination information. [PERSON] et al. [19] integrated an improved faster R-CNN with an enhanced GMFlowNet to extract optical flow curves from mouth movements in multiple cows, allowing for the identification of rumination behavior and the calculation of chewing duration. [PERSON] et al. [20] utilized the mean shift algorithm to track jaw movements in target animals, generating centroid movement curves of the mouth to recognize rumination. Most of these methods rely on traditional computer vision techniques, which are limited in their ability to fully leverage the rich information contained in large video datasets and lack the capability for automatic learning and optimization. Furthermore, these approaches demonstrate poor adaptability to varying environments and conditions, reducing their suitability for practical applications. In contrast, computer vision methods incorporating deep learning offer enhanced adaptability, allowing for high-precision recognition across diverse scenarios through techniques such as data augmentation and diversified training data.