A hierarchical and progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library
By using a four-mode MPC algorithm library and a tightly coupled RL-MPC parameter tuning mechanism, the problem of obstacle avoidance and precise operation of weeding robots in different environments has been solved, achieving efficient and safe autonomous obstacle avoidance, improving operation efficiency and success rate, and filling the technical gap in intelligent planning layer.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- ZHEJIANG FORESTRY UNIVERSITY
- Filing Date
- 2026-03-11
- Publication Date
- 2026-06-30
AI Technical Summary
Existing obstacle avoidance planning methods for weeding robots cannot achieve precise operations under different environmental complexities, and the algorithm architecture lacks adaptability. The decoupling of reinforcement learning and motion control leads to information loss, and existing monitoring well construction efficiency is low and difficult to adjust.
A smart weeding machine based on a four-mode MPC algorithm library is adopted. A multi-instance MPC algorithm library with a unified kinematic model is constructed to achieve lossless hot switching of algorithm instances in the planning layer. A three-level differentiated safety distance model of crops, weeds and rigid obstacles is established, and the cost function weight is dynamically adjusted through the tightly coupled parameter tuning mechanism of RL-MPC.
It achieves high-precision obstacle avoidance in different environments, reduces seedling damage rate, improves operation efficiency and success rate, has scene adaptive capability, and fills the technical gap in intelligent planning layer.
Smart Images

Figure CN122308358A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of autonomous navigation and intelligent obstacle avoidance technology for agricultural robots, specifically a hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library. Background Technology
[0002] Intelligent weeding robots are crucial equipment in precision agriculture, and their autonomous navigation and obstacle avoidance capabilities directly determine operational efficiency and crop protection levels. Unlike general-purpose mobile robots, weeding robots need to simultaneously accomplish three objectives in dense vegetation environments: first, efficiently covering the work area; second, accurately approaching and removing weeds; and third, avoiding damage to crops and collisions with rigid obstacles. This places extremely high demands on the scene adaptability and planning precision of the obstacle avoidance system.
[0003] The shortcomings of existing technologies in differentiated safety obstacle avoidance:
[0004] A search revealed that current obstacle avoidance planning methods for weeding robots all employ a single obstacle distance safety threshold. Patent CN118303206B discloses a self-obstacle-avoiding, all-area weeding device that acquires obstacle positions through image recognition and records them as coordinate points. However, its path planning only distinguishes between "obstacles" and "non-obstacles," failing to establish a tiered safety distance model for crops, weeds, and rigid obstacles. Patent CN121368952A discloses a swing-type intelligent inter-plant weeding device for open-field vegetables. It uses a depth camera and laser sensor to calculate a "fusion height" to control the weeding blade to avoid seedlings, but its output is only used for adjusting the robotic arm's movements and is not fed back to the distance cost function of the motion planning layer. These methods result in robots being overly conservative between crop rows, overly aggressive in dense weed areas, and slow to respond to rigid obstacles, failing to achieve precise operations such as "walking through where possible, avoiding where necessary, and stopping when appropriate."
[0005] The shortcomings of existing technologies in terms of algorithm architecture adaptation:
[0006] Current intelligent lawnmowers all employ a single, fixed-architecture obstacle avoidance planner. Publicly available literature on autonomous obstacle avoidance mowing devices uses a pathpoint planning method based on obstacle coordinates, while mountain orchard weeding robots use A* inline traversal; neither can dynamically switch planner instances based on environmental complexity. A single algorithm cannot simultaneously meet real-time and passability requirements in vastly different scenarios such as open lawns, densely planted orchards, and sensor degradation—low-complexity scenarios result in wasted computational power, while high-complexity scenarios face a sharp drop in passability.
[0007] The shortcomings of existing technologies in combining reinforcement learning and MPC:
[0008] While the patent with publication number CN121368952A involves intelligent control, its reinforcement learning module is decoupled from the underlying motion control. A search reveals that there is currently no technical solution in the field of agricultural robots that embeds a reinforcement learning agent within the MPC optimization loop and directly adjusts the cost function weights. In existing methods, reinforcement learning is mostly used for global path planning or target trajectory generation, with MPC responsible for trajectory tracking; the two operate in series. This "planning-after-decision" architecture suffers from information loss and cannot achieve real-time, continuous, and fine-tuning of obstacle avoidance behavior patterns using reinforcement learning.
[0009] To achieve simultaneous monitoring of soil and groundwater at different depths, existing technologies employ multi-level monitoring wells. A typical approach involves lowering a monitoring well casing into a large-diameter borehole, filling the annular gap between the casing and the borehole wall with filter material for different monitoring layers. This requires on-site backfilling of filter material layer by layer, adding bentonite balls layer by layer, and waiting for them to slowly absorb water and expand. This method is inefficient, and the effectiveness of water sealing is highly dependent on the experience of the construction personnel, making quality difficult to guarantee. Once the water-sealing material solidifies, the monitoring layer is permanently fixed. If later research reveals that contamination has migrated beyond the original monitoring layer, or if the monitoring resolution needs to be adjusted, the monitoring well cannot be modified and must be re-drilled, resulting in high costs. Therefore, we propose a layered, progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library to address these problems. Summary of the Invention
[0010] To address the shortcomings of existing technologies, this invention provides a hierarchical, progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library. It solves the following problems: how to construct a multi-instance MPC algorithm library for different environmental complexities during weeding operations, allowing each instance to share the same kinematic model and optimization solver, with differences only in cost function structure and weight generation strategy, achieving lossless hot switching between planning layer algorithm instances; how to map the output results of visual semantic segmentation and LiDAR clustering to the MPC cost function layer, establishing a three-level differentiated safety distance constraint model for crops, weeds, and rigid obstacles, enabling the weeder to "cross weeds, avoid crops, and bypass obstacles" during operation; and how to achieve a tightly coupled parameter tuning mechanism between reinforcement learning and MPC, embedding the reinforcement learning AI within the MPC optimization loop, allowing it to perceive environmental states in real time and dynamically adjust the speed weights, safety distance weights, and smoothing weights in the MPC cost function, achieving continuous behavior parameter tuning between "operational efficiency" and "obstacle avoidance safety."
[0011] To achieve the above objectives, the present invention provides the following technical solution: a hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library, comprising the following steps:
[0012] Step S1: Construct a four-instance MPC algorithm library based on a unified kinematics model
[0013] Unlike existing technologies that employ "multiple algorithms in parallel or switching" architectures, this invention proposes a multi-instance configuration library within the same MPC optimization framework. The four algorithm instances share the following unified components:
[0014] Kinematic Model: The kinematic model of the differential wheeled mobile robot is adopted, and the discretized state transition equation is as follows:
[0015]
[0016]
[0017]
[0018] Where T is the control period, and in this embodiment, T = 0.1 s.
[0019] Prediction kernel: fixed prediction time domain Np=15, control time domain Nc=8.
[0020] Optimized solver: The OSQP solver is adopted, providing a unified calling interface.
[0021] The only differences between the instances are the cost function structure and weight generation strategy: MPC_Avoidance uses fixed weights and a uniform safety threshold; MPC_Avoidance_RL uses dynamically output weights from the reinforcement learning agent; MPC_Avoidance_Fusion calculates obstacle distances based on a fused cost map; and MPC_Avoidance_Wood uses a three-level differentiated safety threshold. All four instances share the same ROS node encapsulation, and the cost function calculation core is switched in real-time via a dynamically configured server, with a switching time of <50 ms and no abrupt changes in the control output.
[0022] Step S2: Online assessment of the complexity of the weeding operation environment and adaptive scheduling of the algorithm
[0023] Construct a quantitative assessment model for environmental complexity, with inputs including obstacle density. Average speed of obstacles Crop density Weed coverage Topographic relief The complexity scoring function C is defined as follows:
[0024]
[0025] Algorithm scheduling strategy:
[0026] C < 0.25: Schedule MPC_Avoidance (open lawn)
[0027] 0.25 ≤ C < 0.45: Schedule MPC_Avoidance_RL (Dynamic Obstacles, Medium-Density Weeds)
[0028] 0.45 ≤ C < 0.65: Schedule MPC_Avoidance_Fusion (sensor degradation)
[0029] C ≥ 0.65 or η_weed > 50%: Schedule MPC_Avoidance_Wood (high-density vegetation, orchard)
[0030] The scheduler employs an anti-jitter strategy: a switch is performed when the conditions are met for three consecutive frames and the target instance is not at the same time, with a 0.5-second speed transition added during the switch process.
[0031] Step S3: Three-level differentiated safety distance modeling for crops, weeds, and rigid obstacles (core innovation)
[0032] This invention is the first to propose mapping visual semantic segmentation and LiDAR clustering results to the MPC cost function layer to establish a three-level differentiated safe distance constraint model.
[0033] 3.1 Environmental Perception and Grid Tagging
[0034] RGB-D images are processed by a lightweight semantic segmentation network to output crop, weed, and background classifications; LiDAR point clouds are clustered and analyzed for reflection intensity to output rigid obstacle clusters. Multi-source information is spatiotemporally aligned and projected onto a two-dimensional raster map, with each raster g assigned a unique label L(g).
[0035] L(g) ∈ {0: unobstructed, 1: weeding area, 2: crop protection area, 3: rigid obstacle}
[0036] 3.2 Differentiated Safety Distance Function
[0037] Define differential security thresholds associated with raster labels:
[0038]
[0039] 3.3 Differentiated distance cost term in MPC cost function
[0040] Reconstruct the obstacle distance cost term in the MPC cost function:
[0041]
[0042] Where d_min(x_k) is the Euclidean distance from state x_k to the nearest obstacle grid, and L(x_k) is the label of that grid. This design enables the MPC optimizer to adaptively adjust the obstacle avoidance aggression level according to the obstacle type.
[0043] Step S4: Tightly Coupled Parameter Tuning Mechanism between Reinforcement Learning and MPC (Core Innovation)
[0044] Unlike the existing technology where RL and MPC are decoupled in a "planning-tracking" architecture, this invention proposes a tightly coupled RL-MPC parameter tuning mechanism, which embeds the reinforcement learning intelligence into the MPC optimization loop and directly adjusts the weights of the MPC cost function.
[0045] 4.1 Reinforcement Learning Agent Design
[0046] The TD3 algorithm is adopted. The state space S is a 14-dimensional vector, containing features such as robot speed, target orientation, distance between obstacles and crops, weed coverage on the left and right, obstacle density, weed coverage, and terrain undulation. The action space A is a 3-dimensional continuous quantity, corresponding to the trajectory tracking weights in the MPC cost function. Obstacle distance weight Controlling smoothing weights The output range is [0.2, 4.0].
[0047] 4.2 Reward Function Design
[0048] The reward function R balances operational efficiency and obstacle avoidance safety:
[0049]
[0050] in The percentage of weed coverage per unit time. Minimum obstacle distance This is the collision indication function.
[0051] 4.3 Tightly Coupled Execution Flow
[0052] Within each control cycle: the environmental perception module outputs the status. Network output weights Optimizer with The process involves: finding the optimal control sequence for the weights → executing the control input in the first frame → calculating the reward R_t and storing the experience → updating the network parameters every 50 steps. This architecture enables lossless injection of reinforcement learning decision information into the MPC optimization objective, resulting in shorter control paths and faster response times.
[0053] Step S5: Algorithm performance loopback evaluation and incremental update
[0054] Performance metrics (obstacle avoidance success rate, weed coverage, average operation speed, seedling damage rate, etc.) of each algorithm instance in various weeding scenarios are collected and stored in a knowledge base. When an instance's evaluation score is lower than the historical P90 quantile for 10 consecutive times in similar scenarios, incremental training of the model is triggered. Incremental training uses a hybrid sampling method with an experience replay pool, retaining 20% of the original data and 80% of the new data, and fine-tuning for 5 epochs.
[0055] Beneficial effects
[0056] This invention provides a hierarchical, progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library. Compared with existing technologies, it has the following advantages:
[0057] The hierarchical and progressive autonomous obstacle avoidance method for intelligent weeders based on the four-mode MPC algorithm library (1) brings about a sharp drop in the rate of seedling damage due to differentiated obstacle avoidance accuracy.
[0058] Compared with publicly available self-obstacle-avoiding mowing devices (CN118303206B) and intelligent inter-row weeding devices (CN121368952A), this invention establishes a three-level differentiated safety distance model at the MPC cost function layer for the first time. Field comparative trials show that in an orchard scenario with a crop row spacing of 0.8 m and a weed coverage rate of 45%, this invention reduces the number of accidental collisions with crops by 76% (comparative method 21% → this invention 6%), and increases the weed coverage rate by 44% (comparative method 63% → this invention 89%). The comparative method, due to its uniform safety threshold (0.5 m), consistently fails to simultaneously achieve both "fewer seedling damages" and "more weeding"—lowering the threshold leads to a surge in seedling damage, while raising the threshold results in severe weed incomplete removal. This invention breaks this technical paradox for the first time.
[0059] (2) Scene adaptive capability enables optimal obstacle avoidance under all working conditions
[0060] Compared to lawnmowers using a single obstacle coordinate point planning method (CN118303206B) and weeding devices employing a fixed robotic arm seedling avoidance strategy (CN121368952A), this invention proposes a four-instance MPC algorithm library and a quantitative scheduling mechanism for environmental complexity, achieving lossless hot switching of planning layer algorithm instances for the first time. In open lawn scenarios, scheduling the lightweight MPC_Avoidance reduces power consumption by 32% with a control cycle of 8.2 ms. In densely planted orchard scenarios, automatic switching to MPC_Avoidance_Wood achieves a 96% success rate compared to the traditional method's 76%. In scenarios with RTK signal occlusion and visual degradation, switching to MPC_Avoidance_Fusion reduces positioning errors to <5 cm (compared to >30 cm in other methods). This invention achieves full-scene adaptability, which cannot be covered by a single algorithm, through architectural innovation.
[0061] (3) Tightly coupled parameter tuning of RL-MPC improves both work efficiency and safety simultaneously.
[0062] Compared to existing agricultural robot solutions that employ a decoupled "planning-tracking" architecture for reinforcement learning and MPC, this invention proposes a tightly coupled RL-MPC parameter tuning mechanism. This mechanism embeds the reinforcement learning AI within the MPC optimization loop, directly adjusting the cost function weights. Comparative experiments show that, with the same training data, this invention improves convergence speed by 2.3 times, steady-state operation speed by 31% (0.41 m / s → 0.58 m / s), and obstacle avoidance success rate by 9 percentage points (84% → 93%). The fundamental reason is that in the decoupled architecture, RL decisions require secondary optimization through MPC, resulting in information loss and response delays. In this invention, RL directly acts on the optimization objective, shortening the control link by more than 60%, achieving end-to-end collaborative optimization of "perception-decision-control".
[0063] (4) Fill the technological gap in the industry and promote the weeding robot into the era of "strategy adaptation".
[0064] The intelligent lawnmower industry is currently undergoing a transformation "from bounded to boundless," with perception solutions becoming increasingly mature. However, the intelligence level of the planning layer remains at the stage of single algorithms and uniform thresholds. This invention is the first to introduce "adaptive scheduling of algorithm libraries" and "differentiated safety distance modeling" into the planning layer of lawnmower robots, filling the technological gap between "perception scene understanding" and "adaptive planning strategy." A technology novelty search report from the Chinese Society of Agricultural Machinery in February 2026 confirms that a lawnmower obstacle avoidance method possessing the three characteristics of "four-instance MPC algorithm library + three-level differentiated safety distance + RL-MPC tightly coupled parameter tuning" has not been publicly reported domestically or internationally. Attached Figure Description
[0065] Figure 1 This is the overall flowchart of the present invention.
[0066] Figure 2 This is a schematic diagram of the unified framework structure of the four-instance MPC algorithm library.
[0067] Figure 3 A schematic diagram of modeling the three-level differentiated safety distance and mapping the MPC cost function.
[0068] Figure 4 The network structure and execution flowchart of the tightly coupled parameter tuning mechanism of RL-MPC are shown.
[0069] Figure 5 This is a schematic diagram of the state machine for online assessment of environmental complexity and adaptive scheduling of algorithms.
[0070] Figure 6 This is an experimental diagram comparing the operation trajectory and seedling damage rate of the present invention and existing technologies in an orchard setting. Detailed Implementation
[0071] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0072] like Figure 1-6 As shown:
[0073] A hierarchical and progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library is presented in this embodiment. The implementation is based on actual compiled and running code. The core module of the algorithm has been encapsulated with ROS nodes. The executable files include mpc_avoidance, mpc_avoidance_rl, mpc_avoidance_fusion, and mpc_avoidance_wood. The method has been verified on the Wheeltec wheeled mobile robot platform.
[0074] Experimental platform: The robot chassis has a maximum speed of 0.8 m / s; the perception system includes a 16-line LiDAR (LivoxMID-360), an RGB-D depth camera (Orbbec Gemini Pro), and four ultrasonic sensors; the computing unit is an NVIDIA Jetson Orin NX 16GB, running Ubuntu 20.04 and ROS Noetic. The algorithm library is written in C++, MPC solvers call OSQP, the reinforcement learning module is based on LibTorch 1.13, and the semantic segmentation network is accelerated by TensorRT, with a single-frame inference time of 12 ms.
[0075] Example 1: Verification of Hot Switching of Four-Instance MPC Algorithm Library
[0076] Four typical scenarios were deployed in the Gazebo simulation environment. The average switching time from MPC_Avoidance to MPC_Avoidance_Wood was 43 ms (<50 ms). The linear velocity command jump before and after the switch was <0.02 m / s, and the angular velocity command jump was <0.05 rad / s, achieving lossless hot switching.
[0077] Example 2: Real-world verification of differentiated safety distance modeling
[0078] Experimental location: Grassland in front of the College of Mathematics and Computer Science, Zhejiang A&F University, Lin'an District, Hangzhou City, Zhejiang Province, with weed coverage of 42%–51%. The control group used the traditional MPC method with a uniform safety threshold of d_safe=0.5 m, while the experimental group used the MPC_Avoidance_Wood method of this invention. Each group was repeated 10 times, and the results are as follows:
[0079] index control group experimental group Improvement range Average number of damaged seedlings (plants / row) 4.2 1.1 Reduced by 73.8% Weed coverage (%) 67.3 91.5 An increase of 24.2% Average operating speed (m / s) 0.33 0.46 An increase of 39.4% Obstacle avoidance success rate (%) 82 98 Increase by 16%
[0080] Experimental data proves that this invention significantly reduces seedling damage rate while simultaneously and substantially improving operational efficiency and weed coverage rate, which is a technical effect that existing methods cannot achieve.
[0081] Example 3: Performance Comparison of Tightly Coupled Parameter Tuning in RL-MPC
[0082] The control group adopted the decoupled architecture of "PPO trajectory generation + MPC trajectory tracking" as described in published patent CN121368952A, while the experimental group adopted the MPC_Avoidance_RL instance (TD3 embedded parameter tuning) of this invention. Using identical training data (500,000 time steps), evaluation was performed in Gazebo.
[0083] index control group experimental group Improvement range Time required to achieve an 80% success rate 320,000 140,000 Speed increased by 2.3 times Steady-state average operating speed (m / s) 0.45 0.59 An increase of 31.1% Steady-state obstacle avoidance success rate (%) 84 93 Increase by 9% Control frequency (Hz) 8.5 9.7 Increased by 14%
[0084] Conclusion: This invention significantly outperforms existing decoupled architectures in three dimensions: convergence speed, steady-state performance, and real-time performance.
[0085] Example 4: Algorithm Performance Validation via Loopback and Incremental Update
[0086] The initial weed identification model achieved an accuracy of 82.3% in the experimental orchard. After deploying the performance loopback module, the system automatically collected samples with a confidence level below 0.7, triggering incremental training every 500 new images. After four rounds of incremental training (collecting a total of 2100 images), the weed identification accuracy improved to 91.7%, while the crop misidentification rate decreased from 12.4% to 5.8%. This mechanism enables the weeder obstacle avoidance system to continuously evolve and adapt to changes in vegetation characteristics across different regions and seasons.
[0087] Finally, it should be noted that the above descriptions are merely preferred embodiments of the present invention and are not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library, characterized in that: Includes the following steps: A four-mode MPC algorithm library is constructed, which includes the MPC_Avoidance benchmark algorithm, the MPC_Avoidance_RL reinforcement learning fusion algorithm, the MPC_Avoidance_Fusion multi-sensor fusion algorithm, and the MPC_Avoidance_Wood forest adaptive algorithm. The four algorithms share the same kinematic model and optimization solver, and only differ in cost function structure and weight generation strategy. The complexity of the weeding operation environment is evaluated online. The environmental complexity input parameters include obstacle density, crop density, weed coverage, terrain undulation, and obstacle dynamics. The corresponding algorithm instances in the algorithm library are dynamically scheduled to perform obstacle avoidance planning according to the complexity level. The output results of visual semantic segmentation and lidar clustering are mapped to the MPC cost function layer to establish a three-level differentiated safety distance constraint model of crops, weeds and rigid obstacles, so that the weeding machine can execute a differentiated passage strategy of "crossing weeds, avoiding crops and bypassing obstacles". The reinforcement learning AI is embedded inside the MPC optimization loop, which can perceive the environmental state in real time and dynamically adjust the weight coefficients in the MPC cost function, thus achieving tight coupling and parameter tuning between reinforcement learning and MPC. The performance metrics of each algorithm instance in various weeding scenarios are collected and stored in the knowledge base. When the performance is lower than the threshold, the algorithm parameters are optimized or the reinforcement learning model is incrementally trained.
2. The hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library as described in claim 1, characterized in that: The four MPC algorithm instances share the same differential wheel kinematics model and OSQP solver interface; the discretized state transition equation is: Where T is the control period, which ranges from 0.08 to 0.12 s.
3. The hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library as described in claim 2, characterized in that: The three-level differentiated safety distance constraint model includes: Raster labeling steps: The RGB-D image is semantically segmented to output crop and weed classification; the LiDAR point cloud is clustered and the reflection intensity is analyzed to output rigid obstacle clusters; the above information is spatiotemporally aligned and projected onto a two-dimensional raster map, and each raster g is assigned a unique label L(g)∈{0: no obstacles, 1: weed operation area, 2: crop protection area, 3: rigid obstacle}. Differentiated security threshold function: Differential distance cost term in MPC cost function: ,in For state The Euclidean distance from the nearest obstacle grid cell.
4. The hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library as described in claim 2, characterized in that: In the tightly coupled parameter tuning mechanism of RL-MPC: The reinforcement learning agent uses the TD3 algorithm. The state space S is a 14-dimensional vector, which includes robot speed, target orientation, distance between obstacles and crops, weed coverage on the left and right, obstacle density, weed coverage, terrain undulation, and emergency stop sign. The action space A is a 3-dimensional continuous quantity, corresponding to the weights of the MPC cost function [w_t, w_o, w_s] ∈ [0.2, 4.0]³. reward function ,in The percentage of weed coverage per unit time. Minimum obstacle distance This is the collision indication function.
5. The hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library as described in claim 1, characterized in that: The environmental complexity scoring function ; The algorithm scheduling strategy is as follows: if C < 0.25, schedule MPC_Avoidance; if 0.25 ≤ C < 0.45, schedule MPC_Avoidance_RL; if 0.45 ≤ C < 0.65, schedule MPC_Avoidance_Fusion; if C ≥ 0.65 or η_weed > 50%, schedule MPC_Avoidance_Wood. The scheduler adopts a de-jitter strategy: if the conditions are met for 3 consecutive frames and the target instance is different, a switch is performed.
6. The hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library as described in claim 1, characterized in that: The MPC_Avoidance_Fusion algorithm is used to construct the sensor confidence attenuation factor. ,in The fusion cost map is generated by weighting and superimposing the probability grids of each sensor, where λ is 1 / 3 of the sensor's nominal range and λ is the time decay coefficient.
7. The hierarchical progressive autonomous obstacle avoidance method for intelligent weeders based on a four-mode MPC algorithm library as described in claim 1, characterized in that: In the algorithm performance loopback and incremental update steps: when the MPC_Avoidance_RL or MPC_Avoidance_Wood instance has a score lower than the historical P90 quantile for 10 consecutive evaluations in similar scenarios, incremental training of the model is triggered; incremental training adopts a hybrid sampling of the experience replay pool, retaining 20%~30% of the original data, adding 70%~80% of the new data, fine-tuning for 3~5 epochs, and reducing the learning rate to 0.1 times.
8. A hierarchical, progressive autonomous obstacle avoidance system for intelligent weeders based on a four-mode MPC algorithm library, characterized in that, include: The four-mode MPC algorithm library module deploys four MPC algorithm instances as described in any one of claims 1 to 7, with each instance sharing the same kinematic model and optimization solver interface; The environmental perception and complexity assessment module integrates multi-sensor data to generate an environmental state characterization and calculates the environmental complexity score for weeding operations. The algorithm scheduler module makes algorithm instance switching decisions based on complexity scores, with a switching time of <50 ms; The three-level differentiated safety distance modeling module maps visual semantic segmentation and LiDAR clustering results to grid labels, and calculates obstacle distance cost in the MPC cost function based on label differentiation. The RL-MPC tightly coupled parameter tuning module embeds the reinforcement learning agent into the MPC optimization loop and outputs the cost function weight coefficients in real time. The algorithm performance loop module collects runtime metrics and triggers incremental model updates.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 7.
10. An intelligent weeding robot, characterized in that, It includes the system described in claim 8.