Research Center of Information Technology, Beijing Academy of Agriculture and Forestry Sciences, Beijing, 100097, China.
College of Information Engineering, Northwest A&F University, Yangling, 712100, China.
Sci Rep. 2023 Nov 22;13(1):20519. doi: 10.1038/s41598-023-45211-2.
Behavior is one of the important factors reflecting the health status of dairy cows, and when dairy cows encounter health problems, they exhibit different behavioral characteristics. Therefore, identifying dairy cow behavior not only helps in assessing their physiological health and disease treatment but also improves cow welfare, which is very important for the development of animal husbandry. The method of relying on human eyes to observe the behavior of dairy cows has problems such as high labor costs, high labor intensity, and high fatigue rates. Therefore, it is necessary to explore more effective technical means to identify cow behaviors more quickly and accurately and improve the intelligence level of dairy cow farming. Automatic recognition of dairy cow behavior has become a key technology for diagnosing dairy cow diseases, improving farm economic benefits and reducing animal elimination rates. Recently, deep learning for automated dairy cow behavior identification has become a research focus. However, in complex farming environments, dairy cow behaviors are characterized by multiscale features due to large scenes and long data collection distances. Traditional behavior recognition models cannot accurately recognize similar behavior features of dairy cows, such as those with similar visual characteristics, i.e., standing and walking. The behavior recognition method based on 3D convolution solves the problem of small visual feature differences in behavior recognition. However, due to the large number of model parameters, long inference time, and simple data background, it cannot meet the demand for real-time recognition of dairy cow behaviors in complex breeding environments. To address this, we developed an effective yet lightweight model for fast and accurate dairy cow behavior feature learning from video data. We focused on four common behaviors: standing, walking, lying, and mounting. We recorded videos of dairy cow behaviors at a dairy farm containing over one hundred cows using surveillance cameras. A robust model was built using a complex background dataset. We proposed a two-pathway X3DFast model based on spatiotemporal behavior features. The X3D and fast pathways were laterally connected to integrate spatial and temporal features. The X3D pathway extracted spatial features. The fast pathway with R(2 + 1)D convolution decomposed spatiotemporal features and transferred effective spatial features to the X3D pathway. An action model further enhanced X3D spatial modeling. Experiments showed that X3DFast achieved 98.49% top-1 accuracy, outperforming similar methods in identifying the four behaviors. The method we proposed can effectively identify similar dairy cow behaviors while improving inference speed, providing technical support for subsequent dairy cow behavior recognition and daily behavior statistics.
行为是反映奶牛健康状况的重要因素之一,奶牛在遇到健康问题时会表现出不同的行为特征。因此,识别奶牛的行为不仅有助于评估其生理健康和疾病治疗,还能提高奶牛的福利,这对畜牧业的发展非常重要。依靠人眼观察奶牛行为的方法存在劳动成本高、劳动强度大、疲劳率高等问题。因此,有必要探索更有效的技术手段,以便更快速、准确地识别奶牛的行为,提高奶牛养殖的智能化水平。自动识别奶牛行为已成为诊断奶牛疾病、提高农场经济效益和降低动物淘汰率的关键技术。最近,深度学习在自动化奶牛行为识别方面已成为研究热点。然而,在复杂的养殖环境中,由于场景大、数据采集距离长,奶牛行为具有多尺度特征。传统的行为识别模型无法准确识别奶牛相似行为特征,例如站立和行走。基于 3D 卷积的行为识别方法解决了行为识别中视觉特征差异小的问题。但是,由于模型参数多、推理时间长、数据背景简单,无法满足复杂养殖环境下奶牛行为实时识别的需求。为此,我们开发了一种有效的轻量级模型,用于从视频数据中快速准确地学习奶牛行为特征。我们专注于四种常见行为:站立、行走、躺卧和交配。我们使用监控摄像机在一个拥有一百多头奶牛的奶牛场录制奶牛行为视频。我们使用复杂背景数据集构建了一个强大的模型。我们提出了一种基于时空行为特征的双通道 X3DFast 模型。X3D 和 fast 路径通过横向连接来整合空间和时间特征。X3D 路径提取空间特征。具有 R(2+1)D 卷积的 fast 路径分解时空特征,并将有效的空间特征传输到 X3D 路径。动作模型进一步增强了 X3D 空间建模。实验表明,X3DFast 在识别四种行为时的准确率达到 98.49%,优于类似方法。我们提出的方法可以有效地识别相似的奶牛行为,同时提高推理速度,为后续奶牛行为识别和日常行为统计提供技术支持。