Publications
Sort:
Issue
Night-DETR: Recognizing beef cattle behavior under night environment
Transactions of the Chinese Society of Agricultural Engineering 2026, 42(11): 29-38
Published: 15 June 2026
Abstract PDF (6.6 MB) Collect
Downloads:0

Behavioral information of beef cattle has been widely acknowledged as the critical indicator related to physiological health status, welfare, and production. Therefore, it is often required to accurately recognize cattle behaviors for health evaluation and early abnormality warning in precision livestock farming. However, visual monitoring has been severely restricted under nighttime breeding environments due to the low-illumination imaging. Insufficient lighting, uneven illumination distribution, and motion-induced blur have significantly degraded image quality, thus resulting in blurred appearances and weak behavioral feature representations. Existing machine vision can also suffer from frequent missed detections and false positions during feature extraction and classification. In this study, a behavior recognition framework, named Night-DETR, was proposed to specifically monitor beef cattle under complex nighttime scenarios. First, a low-light image enhancement with SCINet was introduced as a preprocessing module to improve the visual quality of nighttime monitoring images. Image brightness and structural clarity were effectively increased by suppressing noise after enhancement, thereby providing more informative and stable visual inputs for downstream behavior recognition. Second, the baseline RT-DETR architecture was systematically redesigned to improve the detection accuracy and computational efficiency. Particularly, StarNet was adopted as the backbone network to replace conventional heavy feature extractors. Multi-scale features were efficiently represented to reduce parameter redundancy and computation. An Adaptive Interactive Feature Integration module with an Efficient Discriminative Frequency Domain-based FFN (AIFI-EDFFN) was designed to treat feature ambiguity and inter-object interference under low-light conditions. Behavioral features were enhanced to suppress irrelevant background responses to contextual interactions among neighboring cattle, thereby strengthening contour, posture, and spatial relationship representations. In addition, an Intensity Enhance Layer Cross-scale Feature Fusion module (IELC3) was constructed to optimize multi-scale feature aggregation. An illumination enhancement layer was embedded into the cross-scale fusion. Limb structures, body orientation, and posture features were typically obscured to emphasize them in nighttime environments, thus improving the sensitivity to subtle behavioral changes under weak lighting. A series of experiments was conducted to evaluate the Night-DETR model. The performance of Night-DETR was compared with the representative and state-of-the-art object detection frameworks, including Faster R-CNN, TOOD, FCOS, YOLOv11n, YOLOv12n, YOLOv13n, and the original RT-DETR. Experimental results demonstrated that Night-DETR consistently performed best in nighttime detection scenarios. Compared with the baseline RT-DETR model, Night-DETR improved precision, recall, and mean average precision by 5.3, 5.8, and 5.1 percentage points, respectively, thus achieving 93.4% precision, 90.8% recall, and 91.3% mAP@0.5. Moreover, the computational complexity was significantly reduced, with the number of parameters and floating-point operations decreased by 55.8% and 58.2%, respectively. A lightweight architecture was obtained with only 8.8 M and 23.8 G. Cross-scene transfer learning experiments were conducted to verify the generalization of the improved model among different farming scenarios. An average precision of 90.8% was achieved after transfer learning, which was 1.4 percentage points higher than the original. Night-DETR shared strong cross-scene generalization in various farming environments. Additionally, the robustness of the model was evaluated under extremely low-light conditions. The performance curves were plotted for precision, recall, and mAP@50 among different illumination gradients. Night-DETR maintained stable performance even in severely dark scenarios, indicating its strong robustness under extremely low-light environments. Overall, the Night-DETR model can be expected to provide accurate behavioral perception under low-illumination environments with the lightweight deployment in the intelligent nighttime health monitoring and abnormal behavior early-warning systems. The findings can also offer strong technical support for precision livestock farming in breeding environments.

Issue
Regional monitoring and cross-border early warnings of cattle using fence-type breeding
Transactions of the Chinese Society of Agricultural Engineering 2026, 42(4): 281-290
Published: 28 February 2026
Abstract PDF (4.8 MB) Collect
Downloads:4

Cattle monitoring can rely mainly on manual inspections in the fence farming. Once the cattle escaped near the edge of the fence, the conventional regulatory system could not fully detect and intervene in time, resulting in the loss of cattle. In this study, a cattle area monitoring and boundary-crossing early warning system was proposed for the cattle using fence-type breeding. Instance segmentation and multi-object tracking, named STWBD (Segment Tracking with Boundary Detection), were also utilized to monitor the cattle activities in real time within the fenced area. Intelligent early warnings of the potential boundary-crossing behaviors were then provided to enhance the safety level of the fenced cattle farming. Firstly, an improved RDL-YOLO11n-seg instance segmentation was constructed into the framework. The C3K2-RetBlock module was also introduced to the original YOLO11n-seg, in order to enhance the response capability to the spatial displacement of the cattle. The C2DA structure was combined to improve the expression of the multi-scale features. The Segment-LSCD module was employed to optimize the segmentation head. The object detection and instance segmentation were facilitated to accurately capture the cattle contours and postures. As a result, the spatial perception and real-time monitoring of the cattle were enhanced within the fenced area. Secondly, the DeepOCSORT algorithm was assigned an identity ID to each cattle, particularly for the continuous tracking in different scenarios. Some challenges were effectively handled, such as the small target scale, severe occlusion, low lighting, and cattle close to the boundary. The continuity and stability of the multi-object tracking were provided for the reliable trajectory data to detect the later boundary-crossing behavior. In terms of the fence boundary design, the actual structure of the cattle shed fences was combined to construct a polygonal electronic fence. The safe activity area of the cattle was defined for the continuous analysis of the movement trajectories and position distribution of the cattle. The system was integrated with some functions, such as the trajectory visualization, real-time speed tracking, and statistics of the cattle population. The STWBD was used to monitor the boundary-crossing behavior of the cattle in real time and promptly trigger the intelligent early warnings. Experimental results showed that the precision, recall, and segmentation accuracy of the RDL-YOLO11n-seg model reached 94.9%, 87.4%, and 92.5%, respectively, which were 2.0, 3.1, and 3.1 percentage points higher than the original, and the parameters were reduced by 17.8%, with a floating-point operation count of 8.6 G. The high-order tracking accuracy (HOTA), multiple object tracking accuracy (MOTA), and identity F1-Score (IDFI) of DeepOCSORT were 81.4%, 91.6%, and 95.8%, respectively, while the precision, recall, and F1 score of the escape event detection were 96.2 %, 100.0 %, and 98.1 %, respectively. The movement trajectories of the cattle were efficiently monitored in the small-scale fenced farming environments. The boundary-crossing escape events were effectively identified to provide the reliable technical support for the intelligent early warning and supervision of the cattle. This finding can provide real-time access to the cattle population, distribution, and movement patterns. While the risk was predicted after trajectory and speed analysis. The finding can offer a scientific basis for the secure and efficient management of the confined cattle farming.

Issue
Nighttime beef cattle behavior recognition method based on improved YOLOv11n under low-light image enhancement
Transactions of the Chinese Society of Agricultural Engineering 2025, 41(19): 176-184
Published: 01 September 2025
Abstract PDF (2.1 MB) Collect
Downloads:1

Behavior recognition of beef cattle has been one of the most essential means in the intelligent breeding and health monitoring of cattle sheds. Its recognition often depended on the breeding environment, including the lighting conditions, stocking density, and ground conditions. However, the behavioral identification can be challenging due to the blurred boundary of individual cattle. The beef cattle, as a group animal, can usually tend to rest in groups of 3 to 5. The behavioral patterns and movement of the cattle can interfere with the accuracy of behavior recognition. Especially, the image visibility is significantly reduced during monitoring at night. In addition, the noise interference can further reduce the performance of the traditional behavior recognition under night breeding environments. Conventional recognition of beef cattle behavior can also be limited to the low image visibility, fuzzy and variable behavior, as well as the noise interference. In this study, a framework of recognition was proposed for the beef cattle at night using low-light image enhancement. Firstly, the Lighten Diffusion model was used to enhance the behavior image of beef cattle at night. The clarity and visibility of the image enhanced the target detection. Secondly, the YOLOv11n model was utilized to construct the C3k2-CAFormerCGLU module. Local important features of beef cattle were obtained using the gating mechanism. The noise and irrelevant information were suppressed to avoid misjudgment on the individual boundary of beef cattle. The beef cattle behaviors were effectively distinguished against the background noise or cattle overlapping area. The spatial-to-depth conversion convolution (SPDConv) was used to improve the original subsampling of the model. The spatial and depth information flow was optimized in the convolution operation. There was a more accurate feature expression of the beef cattle at a long distance. The recognition accuracy of the beef cattle behavior was improved from a far perspective. Finally, a Feature Focusing module was introduced into the neck Network. The feature focusing pyramid network (FFPN) was constructed to enhance the feature expression of the target region. The fine-grained feature was extracted under different receptive fields. At the same time, a cross-scale feature fusion was adopted to make the features with rich context information, in order to propagate effectively between different detection scales. Furthermore, the multi-scale target recognition was improved in complex environments. The experimental results showed that the image enhancement was achieved in the four unsupervised low-light enhancement algorithms, including Zero-DCE, Zero-DCE++, Enlighten GAN, and Lighten Diffusion, compared with the low-light image enhancement dataset. The Lighten Diffusion algorithm performed best in the low-light image enhancement tasks, with the highest peak signal to noise ratio (19.79), the highest structural similarity index measure (91.7%), and the lowest mean squared error (691.46). The dataset of beef cattle behavior before and after the enhancement of the Lighten Diffusion was sent into the YOLOv11n target detection model for training. The average recognition accuracy of beef cattle behavior increased by 2.5 percentage points after the enhancement. The precision, recall, and mAP@0.5 of the improved CSF-YOLOv11n model reached 93.9, 87.3, and 94.3, respectively, in terms of the target detection. Compared with the Faster-RCNN, RT-DETR, YOLOv5n, YOLOv7, YOLOv8n, YOLOv9t, YOLOv10n, and YOLOv11n, the mAP@0.5 of the model increased by 8.4, 7.4, 5.9, 6.4, 5.6, 6.4, 5.7, and 4.9 percentage points, respectively. The finding can also provide a strong reference to realize the healthy breeding of beef cattle under all weather conditions.

Total 3