Path planning optimization method, device and equipment for paddy field weeding robot and medium
By optimizing the path planning method of paddy field weeding robots, the problem of resource waste in the prior art when weed growth density is low or partially distributed is solved, and a more efficient path planning of weeding operations is achieved.
Patent Information
- Application Number
- CN202411492703.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-10-24
- Publication Date
- 2025-02-11
- Estimated Expiration
- 2044-10-24
AI Technical Summary
In the prior art, simple reciprocating coverage paths can lead to considerable waste of resources when weeds grow density is low or partially arranged.
A method of path planning optimization for paddy field weeding robots is proposed. By responding to path planning optimization instructions, the grid area, path points and target operation location points of the paddy field area to be weeded are obtained, and a full coverage path point set is constructed, and the barrier-free path points are passed are obtained. Combination of sets, shortest barrier-free paths and obstacle avoidance paths, optimize path planning.
This method not only retains the rapid planning characteristics of the traditional reciprocating full coverage path planning algorithm, but also further optimizes the length of the job path through path cutting and reorganization strategies, reduces resource waste, and achieves effective obstacles through improved PRM and A* algorithms Avoid and form an efficient and optimal weeding operation path.
Smart Images

Figure CN119413172A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of agricultural production, and in particular to a path planning optimization method for a paddy field weeding robot, a corresponding device, an electronic device, and a computer-readable storage medium. Background Art
[0002] During the rice production process, the weeds in the rice fields grow strongly, which not only poses a serious threat to the growth of rice, but also provides good conditions for the breeding of pests and diseases. Weeding is an important part of field management, and path planning is one of the key steps to achieve autonomous weeding by robots. How to intelligently and accurately remove these weeds to reduce damage to the environment has become a focus of widespread attention among researchers.
[0003] In fields with dense weed cover, the traditional reciprocating mulching path is the most effective path. However, when the weed growth density is low or locally distributed, the simple reciprocating mulching path will result in considerable waste of resources.
[0004] In summary, the applicant has made corresponding explorations to solve the problem that when the weed growth density is low or the weeds are locally distributed, the simple reciprocating covering path in the prior art will lead to considerable waste of resources. Summary of the invention
[0005] The purpose of the present application is to solve the above-mentioned problems and to provide a path planning optimization method for a paddy field weeding robot, a corresponding device, an electronic device and a computer-readable storage medium.
[0006] In order to meet the various objectives of this application, this application adopts the following technical solutions:
[0007] A paddy field weeding robot path planning optimization method proposed to meet one of the purposes of this application includes:
[0008] In response to the instruction to optimize the path planning of the paddy field weeding robot, each grid area to be covered in the paddy field area to be weeded, the path points corresponding to the grid area to be covered and the target operation position point are obtained, and the path points corresponding to each grid area to be covered are sequentially sorted to construct a full coverage path point set, wherein the side length of the grid area to be covered is R;
[0009] All the path points in the full coverage path point set are traversed in sequence according to the preset direction. If the distance between two adjacent path points in the full coverage path point set is less than Then the two adjacent path points are bundled into a corresponding barrier-free path point set to determine a plurality of barrier-free path point sets, wherein the barrier-free path point sets correspond one-to-one to barrier-free paths, and the barrier-free paths are constructed by one or more path points;
[0010] Retaining the path points in the obstacle-free path point set that are on the same horizontal line as the target working position point to determine the shortest obstacle-free path, so as to construct a first obstacle-free path set and its corresponding first start-end point set, wherein the first obstacle-free path set includes multiple shortest obstacle-free paths, and the first start-end point set includes the starting point of each shortest obstacle-free path and its corresponding end point;
[0011] Determine the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine a second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by a plurality of shortest obstacle-free paths with determined path directions;
[0012] The PRM algorithm based on the introduction of the artificial potential field method determines the route map according to the sampling point data and the connected radius, and uses the improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map. The shortest obstacle-free path with the determined path direction in the second obstacle-free path set is connected with the shortest obstacle avoidance path in sequence to determine the optimal weeding operation path, so as to complete the path planning optimization of the paddy field weeding robot.
[0013] Optionally, the first obstacle-free path set is C = {C1, C2, ..., C i}, the first starting and ending point set U = {{S1, E1}, {S2, E2}, ..., {S i ,E i}}, wherein the S i represents the shortest obstacle-free path C i The starting point, E i represents the shortest obstacle-free path C i The end point;
[0014] The second barrier-free path set is The second start and end point set is '"""'
[0015] U={{S1,E1},{S2,E2},...,{S i ,E i}}, wherein the S i The shortest obstacle-free path indicating the determined path direction The starting point, E' i The shortest obstacle-free path indicating the determined path direction The end point, C1, Indicates the starting point of weeding operations.
[0016] Optionally, the step of determining the path direction of each shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy to determine the second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path includes:
[0017] The path direction determination strategy includes:
[0018] Determine U i and L(S i ),in, U i It means the new start and end point set is obtained by deleting the start and end point of the current path from the previous start and end point set. express The shortest obstacle-free path, Indicates the starting point of the current path. The end point of the current path;
[0019] Traverse the U i Find the same as The point S′ with the smallest Euclidean distance, if S′ is the original starting point S of the shortest obstacle-free path i ,but It is a positive sequence, and the path direction is consistent with the original path direction;
[0020] If S′ is the original end point E of the shortest obstacle-free path i ,but In reverse order, the path direction is opposite to the original path direction;
[0021] The determined path sequence Add to the final path set P and repeat the above steps until U i-1 is an empty set, and the second obstacle-free path set is obtained And its corresponding second starting and ending point set U'={{S'1,E'1},{S'2,E'2},...,{S' i ,E' i}}.
[0022] Optionally, after the step of determining the second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and the ending point of each obstacle avoidance path, the following steps are included:
[0023] The preset shortest trajectory planning algorithm is used to obtain the second obstacle-free path set C * The shortest connection trajectory of two adjacent shortest obstacle-free paths A i , wherein the shortest trajectory planning algorithm includes:
[0024]
[0025] Wherein, σ is an obstacle avoidance path planning algorithm, which includes a PRM algorithm that introduces an artificial potential field method and an improved A* graph search algorithm, d i For E' i-1 Point to S' i R is the side length of the grid area to be covered.
[0026] Optionally, the steps of determining the route map based on the sampling point data and the connection radius based on the PRM algorithm using the artificial potential field method include:
[0027] when When , the PRM algorithm based on the introduction of artificial potential field method randomly generates nodes n from the state space M i, , get a set of valid sampling points N, where i = 1, 2, ..., N;
[0028] The state space is regarded as a virtual force field. The sampling points inside the obstacle are subject to the gravitational force of the sampling points in the free space and the repulsive force of the obstacle center, gradually moving to the outside of the obstacle, and finally becoming valid sampling points in the free space to determine the sampling point data;
[0029] For each pair of sampling points X i and X j, , when d=(X i, X j, ) is less than or equal to R m When the sampling point X i, and sampling point X j, An undirected edge is established between them, where d = (X i, X j, ) represents the sampling point X i and X j, The distance between m Represents the connectivity radius of the PRM algorithm;
[0030] Based on the above steps, we finally get a roadmap G(V,E), where V is the node set and E is the edge set.
[0031] Optionally, the step of using an improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and sequentially connecting the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle avoidance path to determine the optimal weeding operation path includes:
[0032] The heuristic function of the improved A* graph search algorithm includes:
[0033]
[0034] ω1+ω2+ω3=1,
[0035] Among them, ω i is the weight of each optimization objective, including overlap rate, path length and cumulative turning angle, f i is the converted objective function, γ1 is the overlap rate, γ2 is the path length, F(x) is the heuristic function, r is the turning radius, η is the energy coefficient of the steering control system, and i=1, 2, 3.
[0036] Optionally, after the step of sequentially connecting the shortest obstacle-free path with the determined path direction in the second obstacle-free path set and the shortest obstacle-avoiding path to determine the optimal weeding operation path, the method further includes:
[0037] The optimal weeding operation path is smoothed by using a Bezier curve to determine the optimal weeding operation path after smoothing, so as to complete the path planning optimization of the paddy field weeding robot.
[0038] A paddy field weeding robot path planning and optimization device provided for another purpose of the present application includes:
[0039] A grid area acquisition module is configured to respond to an instruction for performing path planning optimization on the paddy field weeding robot, acquire each grid area to be covered in the paddy field area to be weeded, path points corresponding to the grid area to be covered, and a target operation position point, and sequentially sort the path points corresponding to each grid area to be covered to construct a full coverage path point set, wherein the side length of the grid area to be covered is R;
[0040] an obstacle-free path point determination module, configured to sequentially traverse all path points in the full coverage path point set in a preset direction, and if the distance between two adjacent path points in the full coverage path point set is less than √2R, then the two adjacent path points are bundled into a corresponding obstacle-free path point set to determine a plurality of obstacle-free path point sets, wherein the obstacle-free path point sets correspond one-to-one to obstacle-free paths, and the obstacle-free paths are constructed by one or more path points;
[0041] A first path set determination module is configured to retain the path points in the obstacle-free path point set that are on the same horizontal line as the target operation position point to determine the shortest obstacle-free path, so as to construct a first obstacle-free path set and its corresponding first start-end point set, wherein the first obstacle-free path set includes multiple shortest obstacle-free paths, and the first start-end point set includes the starting point of each shortest obstacle-free path and its corresponding end point;
[0042] A second path set determination module is configured to determine the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine a second obstacle-free path set and its corresponding second starting and ending point set, and a starting point and an end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by a plurality of shortest obstacle-free paths with determined path directions;
[0043] The path planning optimization module is configured to determine a route map based on the PRM algorithm using the artificial potential field method according to the sampling point data and the connectivity radius, and to use the improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and to connect the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle avoidance path in sequence to determine the optimal weeding operation path, so as to complete the path planning optimization of the paddy field weeding robot.
[0044] An electronic device provided to meet another purpose of the present application includes a central processing unit and a memory, wherein the central processing unit is used to call and run a computer program stored in the memory to execute the steps of the paddy field weeding robot path planning optimization method described in the present application.
[0045] A computer-readable storage medium is provided to meet another purpose of the present application, which stores a computer program implemented according to the path planning optimization method of the paddy field weeding robot in the form of computer-readable instructions. When the computer program is called and executed by a computer, the steps included in the corresponding method are executed.
[0046] Compared with the prior art, the present application aims at the problem that when the weeds have low growth density or are locally distributed, a simple reciprocating covering path will lead to considerable waste of resources. The present application includes but is not limited to the following beneficial effects:
[0047] First, compared with the traditional reciprocating operation path, the path planning optimization method of the paddy field weeding robot in the present application not only retains the fast planning characteristics of the traditional reciprocating full coverage path planning algorithm, but also further optimizes the operation path length through path clipping and reorganization strategies to reduce path resource waste.
[0048] Secondly, the path planning optimization method of the paddy field weeding robot of the present application takes into account the robot's kinematic characteristics and multiple key objectives, such as turning angle, path length and overlap rate, in the path planning algorithm framework. The path planning of the paddy field weeding robot is modeled by adopting the constrained multi-objective optimization technology. The generated path is carefully optimized using an efficient optimization algorithm to ensure the efficiency and practicality of the path planning.
[0049] Third, the path planning optimization method of the paddy field weeding robot of the present application designs an improved PRM path planning algorithm. To address the problem of low algorithm efficiency caused by the sampling points falling on obstacles in the traditional PRM algorithm during the sampling stage, an artificial potential field method is introduced to optimize the sampling points falling within the obstacles, and the sampling points within the obstacles are converted into points in the free space, thereby improving the algorithm's performance in path length and running time.
[0050] Furthermore, the present application proposes a path planning optimization strategy for a paddy field weeding robot to address the problem that using a simple reciprocating covering path when the weed growth density in the field is low or the distribution is localized, which will lead to a considerable waste of resources. The strategy is based on the traditional reciprocating covering path, and by analyzing the spatial coordinate relationship between the target operation position point and the path point, it identifies and removes unnecessary path points, thereby optimizing the path layout. In addition, the present invention also incorporates an improved PRM path planning algorithm and an improved A* graph search algorithm to achieve effective avoidance of obstacles and shortest obstacle avoidance path planning. Finally, the optimized covering path and obstacle avoidance path are integrated and smoothed to form an efficient optimal weeding operation path. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] The above and / or additional aspects and advantages of the present application will become apparent and easily understood from the following description of the embodiments in conjunction with the accompanying drawings, in which:
[0052] Figure 1 A schematic diagram of the process of the paddy field weeding robot path planning optimization method in the embodiment of the present application;
[0053] Figure 2 This is a schematic diagram of the effect of determining the optimal weeding operation path in an embodiment of the present application;
[0054] Figure 3 This is a schematic diagram of the effect of introducing the artificial potential field method into the PRM algorithm to determine the route map in the embodiment of the present application;
[0055] Figure 4 This is a principle block diagram of the path planning and optimization device for the paddy field weeding robot in the embodiment of the present application;
[0056] Figure 5 It is a schematic diagram of the structure of the computer device in the embodiment of the present application. DETAILED DESCRIPTION
[0057] The embodiments of the present application are described in detail below, and examples of the embodiments are shown in the accompanying drawings, wherein the same or similar reference numerals throughout represent the same or similar elements or elements having the same or similar functions. The embodiments described below with reference to the accompanying drawings are exemplary and are only used to explain the present application, and cannot be interpreted as limiting the present application.
[0058] It will be understood by those skilled in the art that, unless expressly stated, the singular forms "one", "said", and "the" used herein may also include plural forms. It should be further understood that the term "comprising" used in the specification of the present application refers to the presence of the features, integers, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or groups thereof. It should be understood that when we refer to an element as being "connected" or "coupled" to another element, it may be directly connected or coupled to the other element, or there may be an intermediate element. In addition, the "connection" or "coupling" used herein may include wireless connection or wireless coupling. The term "and / or" used herein includes all or any unit and all combinations of one or more associated listed items.
[0059] It will be understood by those skilled in the art that, unless otherwise defined, all terms (including technical and scientific terms) used herein have the same meaning as those generally understood by those skilled in the art to which this application belongs. It should also be understood that terms such as those defined in general dictionaries should be understood to have meanings consistent with those in the context of the prior art, and will not be interpreted with idealized or overly formal meanings unless specifically defined as here.
[0060] It will be understood by those skilled in the art that the "client", "terminal" and "terminal device" used herein include both devices with wireless signal receivers, which are devices with only wireless signal receivers without transmission capabilities, and devices with receiving and transmitting hardware, which are devices with receiving and transmitting hardware capable of two-way communication on a two-way communication link. Such devices may include: cellular or other communication devices such as personal computers, tablet computers, which have single-line displays or multi-line displays or cellular or other communication devices without multi-line displays; PCS (Personal Communications Service, personal communication system), which can combine voice, data processing, fax and / or data communication capabilities; PDA (Personal Digital Assistant, personal digital assistant), which may include a radio frequency receiver, pager, Internet / intranet access, web browser, notepad, calendar and / or GPS (Global Positioning System, global positioning system) receiver; conventional laptop and / or palmtop computers or other devices, which have and / or include a conventional laptop and / or palmtop computer or other device with and / or including a radio frequency receiver. The "client", "terminal" and "terminal device" used herein may be portable, transportable, installed in a vehicle (air, sea and / or land), or suitable for and / or configured to run locally, and / or in a distributed form, at any other location on the earth and / or in space. The "client", "terminal" and "terminal device" used herein may also be a communication terminal, an Internet terminal, a music / video playing terminal, for example, a PDA, a MID (Mobile Internet Device) and / or a mobile phone with a music / video playing function, or a smart TV, a set-top box and other devices.
[0061] The hardware referred to by the names such as "server", "client", and "service node" in this application is essentially an electronic device with the equivalent capabilities of a personal computer. It is a hardware device with the necessary components revealed by the von Neumann principle, such as a central processing unit (including an arithmetic unit and a controller), a memory, an input device, and an output device. The computer program is stored in its memory, and the central processing unit calls the program stored in the external memory into the internal memory for execution, executes the instructions in the program, and interacts with the input and output devices to complete specific functions.
[0062] It should be pointed out that the concept of "server" referred to in this application can also be extended to the case of server clusters. According to the network deployment principle understood by those skilled in the art, the servers should be logically divided. In physical space, these servers can be independent of each other but can be called through interfaces, or integrated into a physical computer or a set of computer clusters. Those skilled in the art should understand this flexibility, and should not use it to restrict the implementation of the network deployment method of this application.
[0063] Unless expressly specified, one or more technical features of the present application can be deployed on a server for implementation and accessed by a client through a remote call to obtain an online service interface provided by the server, or can be directly deployed and run on a client for access.
[0064] The neural network models referenced or may be referenced in this application, unless expressly specified, can be deployed on a remote server and remotely called on the client, or can be deployed and directly called on a client with sufficient device capabilities. In some embodiments, when it runs on the client, its corresponding intelligence can be obtained through transfer learning to reduce the requirements for the client's hardware operating resources and avoid excessive occupation of the client's hardware operating resources.
[0065] Unless explicitly specified, the various data involved in this application can be stored remotely on a server or on a local terminal device, as long as it is suitable for being called by the technical solution of this application.
[0066] Those skilled in the art should be aware that, although the various methods of the present application are described based on the same concept and thus present commonality to each other, unless otherwise specified, these methods can be independently executed. Similarly, for each embodiment disclosed in the present application, they are all proposed based on the same inventive concept, therefore, concepts with the same expression, and concepts that are appropriately changed for convenience despite different expressions, should be understood as equivalent.
[0067] Unless the mutually exclusive relationship between the embodiments to be disclosed in this application is explicitly stated, the relevant technical features involved in each embodiment can be cross-combined to flexibly construct a new embodiment, as long as such combination does not deviate from the creative spirit of this application and can meet the needs of the prior art or solve certain deficiencies in the prior art. Those skilled in the art should be aware of this flexibility.
[0068] See also Figure 1 , Figure 2 as well as Figure 3 In one embodiment, the paddy field weeding robot path planning optimization method of the present application includes:
[0069] Step S10, in response to the instruction to optimize the path planning of the paddy field weeding robot, obtaining each grid area to be covered in the paddy field area to be weeded, the path points corresponding to the grid area to be covered, and the target operation position point, and sequentially sorting the path points corresponding to each grid area to be covered to construct a full coverage path point set, wherein the side length of the grid area to be covered is R;
[0070] The robot path planning system can respond to the instruction of optimizing the path planning of the paddy field weeding robot, obtain each grid area to be covered in the paddy field area to be weeded, the path points corresponding to the grid area to be covered and the target operation position point, and sort the path points corresponding to each grid area to be covered in sequence to construct a full coverage path point set, wherein the side length of the grid area to be covered is R;
[0071] In some embodiments, a reciprocating full coverage path planning algorithm can be used to generate a set of path points in a grid area to be covered with a side length of R, and each path point is sequentially arranged as W1, W2, ..., W n .
[0072] In some embodiments, Figure 2 This is a schematic diagram of the effect of determining the optimal weeding operation path in an embodiment of the present application; Figure 3 This is a schematic diagram of the effect of introducing the artificial potential field method into the PRM algorithm to determine the route map in the embodiment of the present application.
[0073] Step S20: traverse all the path points in the full coverage path point set in sequence according to the preset direction. If the distance between two adjacent path points in the full coverage path point set is less than Then the two adjacent path points are bundled into a corresponding barrier-free path point set to determine a plurality of barrier-free path point sets, wherein the barrier-free path point sets correspond one-to-one to barrier-free paths, and the barrier-free paths are constructed by one or more path points;
[0074] After sorting the path points corresponding to each grid area to be covered in sequence to construct a full coverage path point set, all the path points in the full coverage path point set are traversed in sequence according to a preset direction. If the distance between two adjacent path points in the full coverage path point set is less than Then the two adjacent path points are bundled into a corresponding barrier-free path point set to determine a plurality of barrier-free path point sets, wherein the barrier-free path point sets correspond one-to-one to barrier-free paths, and the barrier-free paths are constructed by one or more path points;
[0075] In some embodiments, if the distance between two adjacent path points in the full coverage path point set is less than √2R, the two adjacent path points are bundled into the corresponding obstacle-free path point set. When , it means that there is no obstacle between the two adjacent path points, and the two adjacent path points are added to the corresponding obstacle-free path point set until the distance between the two adjacent path points is greater than , it indicates that there is an obstacle between two adjacent path points, then stop adding path points to the current obstacle-free path set to determine the current obstacle-free path set and its corresponding current obstacle-free path, and repeat the above steps to determine multiple obstacle-free path point sets.
[0076] In some embodiments, the preset direction may be from left to right or from top to bottom, etc.
[0077] Step S30: retaining the path points in the barrier-free path point set that are on the same horizontal line as the target working position point to determine the shortest barrier-free path, so as to construct a first barrier-free path set and its corresponding first start-end point set, wherein the first barrier-free path set includes multiple shortest barrier-free paths, and the first start-end point set includes the starting point of each shortest barrier-free path and its corresponding end point;
[0078] All the path points in the full coverage path point set are traversed in sequence according to the preset direction. If the distance between two adjacent path points in the full coverage path point set is less than Then, the two adjacent path points are bundled into a corresponding barrier-free path point set to determine a plurality of barrier-free path point sets, and in order to delete redundant path points, path points in the barrier-free path point set that are on the same horizontal line as the target operation position point are retained to determine the shortest barrier-free path, so as to construct a first barrier-free path set and its corresponding first start-end point set, wherein the first barrier-free path set includes a plurality of shortest barrier-free paths, and the first start-end point set includes a starting point of each shortest barrier-free path and its corresponding end point;
[0079] In some embodiments, the first obstacle-free path set is C = {C1, C2, ..., C i}, the first starting and ending point set U = {{S1, E1}, {S2, E2}, ..., {S i ,E i}}, wherein the S i represents the shortest obstacle-free path C i The starting point, E i represents the shortest obstacle-free path C i The end point;
[0080] The second barrier-free path set is The second starting and ending point set is U'={{S'1,E'1},{S'2,E'2},...,{S' i ,E' i}}, wherein the S' i The shortest obstacle-free path indicating the determined path direction The starting point, E' i The shortest obstacle-free path indicating the determined path direction The end point, C1, Indicates the starting point of weeding operations.
[0081] Step S40: determining the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine a second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by a plurality of shortest obstacle-free paths with determined path directions;
[0082] Retaining the path points in the obstacle-free path point set that are on the same horizontal line as the target working position point to determine the shortest obstacle-free path, so as to construct a first obstacle-free path set and its corresponding first starting and ending point set, and then determining the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine a second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by a plurality of shortest obstacle-free paths with determined path directions;
[0083] In some embodiments, the path direction determination strategy includes:
[0084] Step S401: Determine U i and L(S i ),in, U i It means the new start and end point set is obtained by deleting the start and end point of the current path from the previous start and end point set. express The shortest obstacle-free path, Indicates the starting point of the current path. The end point of the current path;
[0085] Step S402: traverse the U i Find the same as The point S′ with the smallest Euclidean distance, if S′ is the original starting point S of the shortest obstacle-free pathi ,but It is a positive sequence, and the path direction is consistent with the original path direction;
[0086] Step S403: If S′ is the original end point E of the shortest obstacle-free path i ,but In reverse order, the path direction is opposite to the original path direction;
[0087] Step S404: The determined path sequence Add to the final path set P and repeat the above steps until U i-1 is an empty set, and the second obstacle-free path set is obtained And its corresponding second starting and ending point set U'={{S'1,E'1},{S'2,E'2},...,{S' i ,E' i}}.
[0088] Further, after the step of determining the second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, the following steps are included:
[0089] The preset shortest trajectory planning algorithm is used to obtain the second obstacle-free path set C * The shortest connection trajectory of two adjacent shortest obstacle-free paths A i , wherein the shortest trajectory planning algorithm includes:
[0090]
[0091] Wherein, σ is an obstacle avoidance path planning algorithm, which includes a PRM algorithm that introduces an artificial potential field method and an improved A* graph search algorithm, d i For E' i-1 Point to S' i R is the side length of the grid area to be covered.
[0092] Based on the above shortest trajectory planning algorithm, when ||d i ||=R or When , it means that there are no obstacles between the shortest obstacle-free paths in the adjacent determined path directions. Connect the shortest obstacle-free paths in the directions of two adjacent determined paths to determine the connection trajectory between the shortest obstacle-free paths in the directions of the adjacent determined paths; When , it means that there is an obstacle between the two adjacent shortest obstacle-free paths with determined path directions. Then, the PRM algorithm with artificial potential field method and the improved A* graph search algorithm are used to plan the obstacle avoidance path between the two adjacent shortest obstacle-free paths with determined path directions.
[0093] Step S50, based on the PRM algorithm introducing the artificial potential field method, a route map is determined according to the sampling point data and the connected radius, and an improved A* graph search algorithm is used to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and the shortest obstacle-free path with the determined path direction in the second obstacle-free path set is connected in sequence with the shortest obstacle avoidance path to determine the optimal weeding operation path, so as to complete the path planning optimization of the paddy field weeding robot.
[0094] Based on the preset path direction judgment strategy, the path direction of the shortest obstacle-free path is determined according to the first obstacle-free path set and its corresponding first starting and ending point set, so as to determine the second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path. Then, based on the PRM algorithm introducing the artificial potential field method, a route map is determined according to the sampling point data and the connection radius, and an improved A* graph search algorithm is used to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and the shortest obstacle-free path with the determined path direction in the second obstacle-free path set is sequentially connected with the shortest obstacle avoidance path to determine the optimal weeding operation path. Specifically, in combination with the path set C * and the shortest obstacle avoidance trajectory A i The final path is obtained, which is expressed as
[0095] To complete the path planning optimization of the paddy field weeding robot.
[0096] In some embodiments, the Probabilistic Roadmap Method (PRM) path planning algorithm was originally proposed by researchers in the fields of computer science and robotics continuing in the 1990s. Its important source is the algorithm jointly developed by LJ Guibas and SM LaValle in 1997, who first described the method in detail in their paper. PRM was proposed to address path planning problems in high-dimensional spaces, especially to provide effective obstacle avoidance paths for mobile robots in complex environments. The algorithm combines probability theory with geometric methods, aiming to simplify the path planning process by generating graph structures that can be used for path search through random sampling. This application introduces an artificial potential field method based on the PRM algorithm to determine an improved PRM algorithm.
[0097] Based on any of the above embodiments, the steps of determining the route map according to the sampling point data and the connected radius based on the PRM algorithm using the artificial potential field method include:
[0098] when When , the PRM algorithm based on the introduction of artificial potential field method randomly generates nodes n from the state space M i, , get a set of valid sampling points N, where i = 1, 2, ..., N;
[0099] The state space is regarded as a virtual force field. The sampling points inside the obstacle are subject to the gravitational force of the sampling points in the free space and the repulsive force of the obstacle center, gradually moving to the outside of the obstacle, and finally becoming valid sampling points in the free space to determine the sampling point data;
[0100] For each pair of sampling points X i and X j, , when d=(X i, X j, ) is less than or equal to R m When the sampling point X i, and sampling point X j, An undirected edge is established between them, where d = (X i, X j, ) represents the sampling point X i and X j, The distance between m Represents the connectivity radius of the PRM algorithm;
[0101] Based on the above steps, we finally get a roadmap G(V,E), where V is the node set and E is the edge set.
[0102] Based on any of the above embodiments, the step of using an improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and sequentially connecting the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle avoidance path to determine the optimal weeding operation path includes:
[0103] The heuristic function of the improved A* graph search algorithm includes:
[0104]
[0105] ω1+ω2+ω3=1,
[0106] Among them, ω i is the weight of each optimization objective, including overlap rate, path length and cumulative turning angle, f i is the converted objective function, γ1 is the overlap rate, γ2 is the path length, F(x) is the heuristic function, r is the turning radius, η is the energy coefficient of the steering control system, and i=1, 2, 3.
[0107] Furthermore, after the step of sequentially connecting the shortest obstacle-free path with the determined path direction in the second obstacle-free path set and the shortest obstacle-avoiding path to determine the optimal weeding operation path, the method further includes:
[0108] The optimal weeding operation path is smoothed by using a Bezier curve to determine the optimal weeding operation path after smoothing, so as to complete the path planning optimization of the paddy field weeding robot.
[0109] As can be seen from the above embodiments, compared with the prior art, the present application aims at the problem that when the weeds have low growth density or are locally distributed, a simple reciprocating covering path will lead to considerable waste of resources. The present application includes but is not limited to the following beneficial effects:
[0110] First, compared with the traditional reciprocating operation path, the path planning optimization method of the paddy field weeding robot in the present application not only retains the fast planning characteristics of the traditional reciprocating full coverage path planning algorithm, but also further optimizes the operation path length through path clipping and reorganization strategies to reduce path resource waste.
[0111] Secondly, the path planning optimization method of the paddy field weeding robot of the present application takes into account the robot's kinematic characteristics and multiple key objectives, such as turning angle, path length and overlap rate, in the path planning algorithm framework. The path planning of the paddy field weeding robot is modeled by adopting the constrained multi-objective optimization technology. The generated path is carefully optimized using an efficient optimization algorithm to ensure the efficiency and practicality of the path planning.
[0112] Third, the path planning optimization method of the paddy field weeding robot of the present application designs an improved PRM path planning algorithm. To address the problem of low algorithm efficiency caused by the sampling points falling on obstacles in the traditional PRM algorithm during the sampling stage, an artificial potential field method is introduced to optimize the sampling points falling within the obstacles, and the sampling points within the obstacles are converted into points in the free space, thereby improving the algorithm's performance in path length and running time.
[0113] Furthermore, the present application proposes a path planning optimization strategy for a paddy field weeding robot to address the problem that using a simple reciprocating covering path when the weed growth density in the field is low or the distribution is localized, which will lead to a considerable waste of resources. The strategy is based on the traditional reciprocating covering path, and by analyzing the spatial coordinate relationship between the target operation position point and the path point, it identifies and removes unnecessary path points, thereby optimizing the path layout. In addition, the present invention also incorporates an improved PRM path planning algorithm and an improved A* graph search algorithm to achieve effective avoidance of obstacles and shortest obstacle avoidance path planning. Finally, the optimized covering path and obstacle avoidance path are integrated and smoothed to form an efficient optimal weeding operation path.
[0114] See also Figure 4 A paddy field weeding robot path planning and optimization device is provided to meet one of the purposes of the present application, including a grid area acquisition module 1100, an obstacle-free path point determination module 1200, a first path set determination module 1300, a second path set determination module 1400 and a path planning optimization module 1500. Among them, the grid area acquisition module 1100 is configured to respond to the instruction of path planning optimization for the paddy field weeding robot, obtain each grid area to be covered in the paddy field area to be weeded, the path points corresponding to the grid area to be covered and the target operation position point, and sort the path points corresponding to each grid area to be covered in sequence to construct a full coverage path point set, wherein the side length of the grid area to be covered is R; the obstacle-free path point determination module 1200 is configured to traverse all the path points in the full coverage path point set in sequence according to a preset direction, and if the distance between two adjacent path points in the full coverage path point set is less than √2R, the two adjacent path points are bundled into the corresponding obstacle-free path point set to determine multiple obstacle-free path point sets, wherein the obstacle-free path point set corresponds one-to-one to the obstacle-free path, and the obstacle-free path is constructed by one or more path points; the first path set determination module 1300 is configured to retain the path points in the obstacle-free path point set that are on the same horizontal line as the target operation position point to determine the shortest obstacle-free path, so as to construct a first obstacle-free path set and its corresponding first obstacle-free path set. A set of starting and ending points, wherein the first obstacle-free path set includes multiple shortest obstacle-free paths, and the first starting and ending point set includes the starting point of each shortest obstacle-free path and its corresponding end point; a second path set determination module 1400 is configured to determine the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine the second obstacle-free path set and its corresponding second starting and ending point set, the starting point and end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by multiple shortest obstacle-free paths with determined path directions; a path planning optimization module 1500 is configured to determine a route map based on the PRM algorithm introduced by the artificial potential field method according to the sampling point data and the connection radius, and use the improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and end point of each obstacle avoidance path in the route map, and connect the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle avoidance path in sequence to determine the optimal weeding operation path, so as to complete the path planning optimization of the paddy field weeding robot.
[0115] Based on any embodiment of this application, please refer to Figure 5 Another embodiment of the present application further provides an electronic device, which can be implemented by a computer device, such as Figure 5As shown, a schematic diagram of the internal structure of a computer device. The computer device includes a processor, a computer-readable storage medium, a memory, and a network interface connected via a system bus. Among them, the computer-readable storage medium of the computer device stores an operating system, a database, and computer-readable instructions. The database may store a control information sequence. When the computer-readable instructions are executed by the processor, the processor can implement a path planning optimization method for a paddy field weeding robot. The processor of the computer device is used to provide computing and control capabilities to support the operation of the entire computer device. The memory of the computer device may store computer-readable instructions. When the computer-readable instructions are executed by the processor, the processor can execute the path planning optimization method for the paddy field weeding robot of the present application. The network interface of the computer device is used to connect and communicate with a terminal. Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0116] In this embodiment, the processor is used to execute Figure 4 The memory stores the program code and various data required to execute the above modules or submodules. The network interface is used to transmit data between user terminals or servers. The memory in this embodiment stores the program code and data required to execute all modules / submodules in the path planning and optimization device for paddy field weeding robots of the present application, and the server can call the program code and data of the server to execute the functions of all submodules.
[0117] The present application also provides a storage medium storing computer-readable instructions. When the computer-readable instructions are executed by one or more processors, the one or more processors execute the steps of the paddy field weeding robot path planning optimization method described in any embodiment of the present application.
[0118] The present application also provides a computer program product, including a computer program / instruction, which, when executed by one or more processors, implements the steps of the paddy field weeding robot path planning optimization method described in any embodiment of the present application.
[0119] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments of the present application can be implemented by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the aforementioned storage medium can be a computer-readable storage medium such as a disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
[0120] The above description is only a partial implementation method of the present application. It should be pointed out that for ordinary technicians in this technical field, several improvements and modifications can be made without departing from the principles of the present application. These improvements and modifications should also be regarded as the scope of protection of the present application.
[0121] In summary, this application aims to solve the problem that using a simple reciprocating covering path when the weed growth density in the field is low or the weeds are locally distributed will lead to a considerable waste of resources. A path planning optimization strategy for a paddy field weeding robot is proposed. The strategy is based on the traditional reciprocating covering path. By analyzing the spatial coordinate relationship between the target operation position point and the path point, unnecessary path points are identified and removed, thereby optimizing the path layout. In addition, the present invention also incorporates an improved PRM path planning algorithm and an improved A* graph search algorithm to achieve effective avoidance of obstacles and shortest obstacle avoidance path planning. Finally, the optimized covering path and obstacle avoidance path are integrated and smoothed to form an efficient optimal weeding operation path.
Claims
1. A method for optimizing the path planning of a paddy field weeding robot, characterized in that: include: In response to the instruction to optimize the path planning of the paddy field weeding robot, each grid area to be covered in the paddy field area to be weeded, the path points corresponding to the grid area to be covered and the target operation position point are obtained, and the path points corresponding to each grid area to be covered are sequentially sorted to construct a full coverage path point set, wherein the side length of the grid area to be covered is R; Traversing all the path points in the full coverage path point set in sequence according to a preset direction, if the distance between two adjacent path points in the full coverage path point set is less than √2R, bundling the two adjacent path points into a corresponding barrier-free path point set to determine a plurality of barrier-free path point sets, wherein the barrier-free path point sets correspond one-to-one to barrier-free paths, and the barrier-free paths are constructed by one or more path points; Retaining the path points in the obstacle-free path point set that are on the same horizontal line as the target working position point to determine the shortest obstacle-free path, so as to construct a first obstacle-free path set and its corresponding first start-end point set, wherein the first obstacle-free path set includes multiple shortest obstacle-free paths, and the first start-end point set includes the starting point of each shortest obstacle-free path and its corresponding end point; Determine the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine a second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by a plurality of shortest obstacle-free paths with determined path directions; The PRM algorithm based on the introduction of the artificial potential field method determines the route map according to the sampling point data and the connected radius, and uses the improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map. The shortest obstacle-free path with the determined path direction in the second obstacle-free path set is connected with the shortest obstacle avoidance path in sequence to determine the optimal weeding operation path, so as to complete the path planning optimization of the paddy field weeding robot.
2. The paddy field weeding robot path planning optimization method according to claim 1, characterized in that: The first obstacle-free path set is C = {C1, C2, ..., C i }, the first starting and ending point set U = {{S1, E1}, {S2, E2}, ..., {S i ,E i }}, wherein the S i represents the shortest obstacle-free path C i The starting point, E i represents the shortest obstacle-free path C i The end point; The second barrier-free path set is The second starting and ending point set is U′={{S′1,E′1},{S′2,E′2},...,{S′ i ,E' i }}, wherein the S i The shortest obstacle-free path with determined path direction The starting point, E' i The shortest obstacle-free path with determined path direction The end point, C1, Indicates the starting point of weeding operations.
3. The paddy field weeding robot path planning optimization method according to claim 2, characterized in that: The step of determining the path direction of each shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine the second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, comprises: The path direction determination strategy includes: Determine U i and L(S i ),in, U i It means the new start and end point set is obtained by deleting the start and end point of the current path from the previous start and end point set. express The shortest obstacle-free path, Indicates the starting point of the current path. The end point of the current path; Traverse the U i Find the same as The point S with the smallest Euclidean distance ′ , if the S ′ is the original starting point S of the shortest obstacle-free path i ,but It is a positive sequence, and the path direction is consistent with the original path direction; If the S ′ is the original end point E of the shortest obstacle-free path i ,but In reverse order, the path direction is opposite to the original path direction; The determined path sequence Add to the final path set P and repeat the above steps until U i-1 is an empty set, and the second obstacle-free path set is obtained and its corresponding '""" The second starting and ending point set U={{S1,E1},{S2,E2},...,{S i ,E i }}.
4. The paddy field weeding robot path planning optimization method according to claim 2, characterized in that: After determining the second obstacle-free path set and its corresponding second starting and ending point set, and the starting point and end point of each obstacle avoidance path, the method further includes: The preset shortest trajectory planning algorithm is used to obtain the second obstacle-free path set C * The shortest connection trajectory of two adjacent shortest obstacle-free paths A i , wherein the shortest trajectory planning algorithm includes: Wherein, σ is an obstacle avoidance path planning algorithm, which includes a PRM algorithm that introduces an artificial potential field method and an improved A* graph search algorithm, d i For E' i-1 Point to S' i R is the side length of the grid area to be covered.
5. The paddy field weeding robot path planning optimization method according to claim 4, characterized in that: The PRM algorithm based on the introduction of the artificial potential field method determines the steps of the route map according to the sampling point data and the connection radius, including: when When , the PRM algorithm based on the introduction of artificial potential field method randomly generates nodes n from the state space M i ,, get a set of valid sampling points N, where i = 1, 2, ..., N; The state space is regarded as a virtual force field. The sampling points inside the obstacle are subject to the gravitational force of the sampling points in the free space and the repulsive force of the obstacle center, gradually moving to the outside of the obstacle, and finally becoming valid sampling points in the free space to determine the sampling point data; For each pair of sampling points X i and X j, , when d=(X i, X j, ) is less than or equal to R m When the sampling point X i, and sampling point X j, An undirected edge is established between them, where d = (X i, X j, ) represents the sampling point X i and X j, The distance between m Represents the connectivity radius of the PRM algorithm; Based on the above steps, we finally get a roadmap G(V,E), where V is the node set and E is the edge set.
6. The paddy field weeding robot path planning optimization method according to claim 5, characterized in that: The steps of using an improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and sequentially connecting the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle avoidance path to determine the optimal weeding operation path include: The heuristic function of the improved A* graph search algorithm includes: ω1+ω2+ω3=1, Among them, ω i is the weight of each optimization objective, including overlap rate, path length and cumulative turning angle, f i is the converted objective function, γ1 is the overlap rate, γ2 is the path length, F(x) is the heuristic function, r is the turning radius, η is the energy coefficient of the steering control system, and i=1, 2, 3.
7. The paddy field weeding robot path planning optimization method according to any one of claims 1 to 6, characterized in that: After the step of sequentially connecting the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle-avoiding path to determine the optimal weeding operation path, the method includes: The optimal weeding operation path is smoothed by using a Bezier curve to determine the optimal weeding operation path after smoothing, so as to complete the path planning optimization of the paddy field weeding robot.
8. A path planning and optimization device for a paddy field weeding robot, characterized in that: include: A grid area acquisition module is configured to respond to an instruction for performing path planning optimization on the paddy field weeding robot, acquire each grid area to be covered in the paddy field area to be weeded, path points corresponding to the grid area to be covered, and a target operation position point, and sequentially sort the path points corresponding to each grid area to be covered to construct a full coverage path point set, wherein the side length of the grid area to be covered is R; The barrier-free path point determination module is configured to sequentially traverse all path points in the full coverage path point set in a preset direction, and if the distance between two adjacent path points in the full coverage path point set is less than Then the two adjacent path points are bundled into a corresponding barrier-free path point set to determine a plurality of barrier-free path point sets, wherein the barrier-free path point sets correspond one-to-one to barrier-free paths, and the barrier-free paths are constructed by one or more path points; A first path set determination module is configured to retain the path points in the obstacle-free path point set that are on the same horizontal line as the target operation position point to determine the shortest obstacle-free path, so as to construct a first obstacle-free path set and its corresponding first start-end point set, wherein the first obstacle-free path set includes multiple shortest obstacle-free paths, and the first start-end point set includes the starting point of each shortest obstacle-free path and its corresponding end point; A second path set determination module is configured to determine the path direction of the shortest obstacle-free path according to the first obstacle-free path set and its corresponding first starting and ending point set based on a preset path direction judgment strategy, so as to determine a second obstacle-free path set and its corresponding second starting and ending point set, and a starting point and an end point of each obstacle avoidance path, wherein the second obstacle-free path set is constructed by a plurality of shortest obstacle-free paths with determined path directions; The path planning optimization module is configured to determine a route map based on the PRM algorithm using the artificial potential field method according to the sampling point data and the connectivity radius, and to use the improved A* graph search algorithm to find the shortest obstacle avoidance path connecting the starting point and the end point of each obstacle avoidance path in the route map, and to connect the shortest obstacle-free path with the determined path direction in the second obstacle-free path set with the shortest obstacle avoidance path in sequence to determine the optimal weeding operation path, so as to complete the path planning optimization of the paddy field weeding robot.
9. An electronic device, comprising a central processing unit and a memory, characterized in that: The central processing unit is used to call and run the computer program stored in the memory to execute the steps of the method according to any one of claims 1 to 7.
10. A computer-readable storage medium, characterized in that: It stores a computer program implemented according to the method described in any one of claims 1 to 7 in the form of computer-readable instructions, and when the computer program is called and executed by a computer, the steps included in the corresponding method are executed.
Citation Information
Patent Citations
Navigation robot path planning method and device, robot and storage medium
CN110044359A
Mobile robot path planning method based on improved PRM and artificial potential field
CN114740864A
Working method of mowing device
CN115708442A
Mechanical arm continuous operation motion planning method
CN115723129A
Inspection robot path planning method based on convolutional neural network
CN118672265A
Cited By
AGV dynamic path planning and obstacle avoidance implementation method based on improved D star algorithm, AGV trolley and medium
CN119935156A