Welcome to Smart Agriculture 中文

Smart Agriculture

   

Intelligent Inspection Path Planning Algorithm for Large-Scale Cattle Farms

CHEN Ruotong1,2, LIU Jifang1(), ZHANG Zhiyong3, MA Nan1,3, WEI Peigang1,2, WANG Yi1,2   

  1. 1. Agricultural Information Institute of CAAS, Beijing 100081, China
    2. National Agriculture Science Data Center, Beijing 100081, China
    3. College of Computer and Information Engineering, Xinjiang Agricultural University, Urumqi 830052, China
  • Received:2025-04-04 Online:2025-06-12
  • Foundation items:National Key Research and Development Program of China(2024YFD2000305)
  • About author:

    CHEN Ruotong, E-mail:

  • corresponding author:
    LIU Jifang, E-mail:

Abstract:

[Objective] Timely detection and early warning of livestock health issues are critical for green and efficient management within large-scale cattle farms. Traditional manual inspections are time-consuming, labor-intensive, and prone to missed or erroneous detections. Robotic inspections offer significant advantages including all-weather operation, high precision, high efficiency, and low cost. However, existing path planning approaches predominantly focus on dynamic obstacle avoidance and fixed target point inspection path, often failing to address two key challenges in dynamic large-scale farm environments: global traversal of individual large livestock (e.g., beef cattle, dairy cows) and accessibility of local areas compromised by dynamic obstacles. This study aims to overcome the limitations of existing robotic inspection systems in large-scale cattle farms, specifically addressing the lack of comprehensive inspection capability for dynamic individuals, excessive path redundancy, and insufficient proactive obstacle avoidance capability. [Methods] A global-local optimization algorithm was proposed for large-scale cattle farm intelligent inspection path planning, which integrated the traveling salesman problem (TSP), A* and dynamic window approach (DWA), and solved the problems of global multi-objective individual traversal, path redundancy and local passability with proactive obstacle avoidance in dynamic cattle farm scenarios. ​​For global traversal optimization, a global path planning algorithm was introduced which combined ​​improved TSP​​ and ​​optimized A*. Specifically, the ​​inspection status list​​ tracking breeding sheds and individual cattle was maintained to enhance the TSP's Nearest Neighbor Algorithm, dynamically updating targets to avoid re-visits. A ​​dynamic priority mechanism​​ optimized multi-objective inspection, determining the optimal visitation sequence across barns and dynamic paths within barns. Optimize the data structure of the A* algorithm, and introduce a diagonal distance heuristic function to replace Manhattan distance, which more accurately reflected the movement cost in eight directions. Simplify the path obtained by the A* algorithm through greedy strategy, and used Bresenham's line algorithm to check whether there were obstacles in the straight line field of view. If there were no obstacles, redundant inflection points were removed to construct an efficient moving path between sheds. ​​For local passability Optimization,​​ an enhanced DWA-based local path was proposed for planning algorithm. The dynamic safety threshold of obstacle size was introduced to improve the DWA. When the inspection robot judged that the size of the obstacle in the local accessible area was too large and the robot was difficult to pass, it would actively avoid or detour in advance to ensure the safe avoidance of large obstacles in narrow passages. The improved DWA also increases the ​​task progress potential field​​, drives the robot to move to the breeding shed to be visited with the attractive force field model, balances the local obstacle avoidance and global inspection efficiency, and realized the real-time judgment of local area passability caused by dynamic obstacles and proactived obstacle avoidance in advance. [Results and Discussions] The optimized A* algorithm's data structures significantly improved search efficiency. The diagonal distance heuristic and greedy strategy substantially enhanced path smoothness. Compared to the traditional A*, the improved A* achieved average reductions of 90.06% in planning time, 85.13% in path turns, and 1.83% in path length. The global inspection algorithm performance was validated in a simulated dynamic cattle farm environment built in Matlab using discrete grid mapping and cattle movement models. The global inspection algorithm combining improved TSP and optimized A* achieved 100% average coverage of individual cattle. Inspection path length and time were reduced by 17.99% and 20.85%, respectively, compared to the classic ant colony optimization (ACO) algorithm, demonstrating superior efficiency in dynamic multi-objective inspection scenarios. The improved DWA successfully enabled proactive judgment of local path passability based on obstacle size. By adjusting the robot's linear velocity, angular velocity, and attitude angle in real time, the algorithm achieved robust proactive obstacle avoidance. The inspection robot will reduce the linear velocity in advance when encountering obstacles, and realize proactive obstacle avoidance by adjusting the attitude angle. Simulation experiments confirmed that robots equipped with the improved DWA effectively navigated around unknown static and dynamic obstacles while maintaining global path-tracking capability. [Conclusions] This study proposes a dynamic multi-objective inspection path planning algorithm for large-scale cattle farms, integrating an improved TSP, optimized A*, and enhanced DWA. The global inspection algorithm combining improved TSP and optimized A*, utilizing dynamic inspection status lists and path optimization techniques, achieved global inspection coverage of individual cattle, significantly improving inspection quality and efficiency. The local inspection algorithm based on improved DWA, incorporating obstacle size dynamic safety threshold and task progress, achieved real-time judgment of local passability and proactive obstacle avoidance, ensuring safe robot navigation in complex environments. The global-local co-optimization framework demonstrated adaptability to the dynamic farm environment, enabling the timely completion of individual traversal tasks, and providing a robust solution for intelligent inspection in large-scale cattle operations. Future work involves integrating the proposed path planning algorithm with simultaneous localization and mapping (SLAM), cattle identification, distance detection systems on inspection robot platforms, and conducting extensive field tests within operational cattle farms. Exploring multi-robot collaborative inspection frameworks and incorporating the Vision-and-Language Navigation model to enhance environmental perception and anomaly-handling capabilities are promising directions for adapting to the complexities of even larger-scale farming scenarios.

Key words: intelligent inspection, multi-objective path planning, global individual traversal, local traffic obstacle avoidance, inspection robot

CLC Number: