Obstacle avoidance methods and devices for autonomous agricultural machinery operation

By acquiring the geometric features and size parameters of obstacles, an obstacle avoidance trajectory function for agricultural machinery is constructed, which solves the problem of insufficient obstacle avoidance in the automatic navigation of agricultural machinery, enables agricultural machinery to safely avoid obstacles with minimal power changes, and improves the availability of the automatic driving system for agricultural machinery.

CN116661431BActive Publication Date: 2026-05-05CHINA AGRI UNIV
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA AGRI UNIV
Filing Date
2022-02-18
Publication Date
2026-05-05

AI Technical Summary

Technical Problem

In existing agricultural machinery automatic navigation technologies, there are insufficient obstacle avoidance algorithms in farmland, resulting in poor availability of agricultural machinery automatic driving systems and the inability to achieve unmanned operation.

Method used

By acquiring the geometric features and dimensional parameters of obstacles on the straight operation path of agricultural machinery, an initial obstacle avoidance path is constructed. An improved shortest tangent method is used to generate the obstacle avoidance path, an obstacle avoidance trajectory function of agricultural machinery is constructed, and the optimal obstacle avoidance path is solved with the goal of minimizing power change.

Benefits of technology

The system generates a safe, reliable, smooth, and optimal obstacle avoidance path that meets the requirements of agricultural machinery, enabling agricultural machinery to safely avoid obstacles with minimal changes in power, thus improving the availability of the agricultural machinery automatic driving system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116661431B_ABST
    Figure CN116661431B_ABST
Patent Text Reader

Abstract

This invention provides an obstacle avoidance method and apparatus for autonomous agricultural machinery operation. The method includes: acquiring geometric feature information of obstacles on the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery; determining an initial obstacle avoidance path for the obstacles based on the geometric feature information and size parameters, wherein the initial obstacle avoidance path consists of multiple initial obstacle avoidance points; constructing an obstacle avoidance trajectory function for the agricultural machinery using the initial obstacle avoidance points as trajectory nodes; constructing an objective function based on the obstacle avoidance trajectory function, with the goal of minimizing the dynamic changes of the agricultural machinery during obstacle avoidance, and determining the constraints that the agricultural machinery needs to satisfy during obstacle avoidance; solving the objective function based on the constraints to obtain the optimal obstacle avoidance path for the agricultural machinery. In this embodiment of the invention, an optimal obstacle avoidance path that meets the tracking requirements of agricultural machinery is generated for obstacles in farmland, enabling the agricultural machinery to safely avoid obstacles on its straight operating path.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of agricultural machinery automatic navigation technology, and in particular to an obstacle avoidance method and device for autonomous operation of agricultural machinery. Background Technology

[0002] In recent years, with the rapid growth of my country's economy, the number and proportion of non-agricultural employment have continued to increase. The rural young and middle-aged labor force is rapidly migrating from agriculture to non-agricultural sectors, leading to a continuous decrease in the agricultural labor force and an increasingly severe aging trend. Correspondingly, my country's labor costs have been rising continuously, pushing up production costs and weakening the international competitiveness of agricultural products. This has made increasing labor productivity to reduce labor input a major way to lower agricultural production costs. This market demand arising from rising labor costs inevitably leads to the innovation and application of labor substitution technologies.

[0003] Automatic navigation technology for agricultural machinery is a key control technology for unmanned agriculture and the foundation for its development. With the widespread application of satellite systems in agriculture, automatic navigation technology based on the Global Navigation Satellite System (GNSS) has matured and is the most widely used, representing the current standard for automatic navigation systems in agricultural machinery. However, the currently prevalent automatic driving technology for agricultural machinery still has shortcomings. When operating, automatic driving systems typically generate digital field boundaries based on farmland boundaries for path planning, but operators are still required to drive the machinery to avoid obstacles and turn around. Although some agricultural machinery can now operate unmanned, it does not consider obstacles within the farmland. Therefore, obstacle avoidance algorithms have become a key technology for improving the usability of automatic driving systems for agricultural machinery. Summary of the Invention

[0004] This invention provides an obstacle avoidance method and device for autonomous agricultural machinery operation, which solves the problem of how to generate obstacle avoidance curves for farmland obstacles in the field of automatic navigation of agricultural machinery.

[0005] This invention provides an obstacle avoidance method for autonomous agricultural machinery operation, comprising:

[0006] Obtain the geometric feature information of obstacles on the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery;

[0007] Based on the geometric feature information and size parameters, an initial obstacle avoidance path is determined for the obstacle, and the initial obstacle avoidance path is composed of multiple initial obstacle avoidance points;

[0008] Using the initial obstacle avoidance point as the trajectory node, construct the agricultural machinery obstacle avoidance trajectory function;

[0009] Based on the agricultural machinery obstacle avoidance trajectory function, with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance, an objective function is constructed, and the constraints that the agricultural machinery needs to satisfy during obstacle avoidance are determined.

[0010] Based on the constraints, the objective function is solved to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0011] Optionally, determining the initial obstacle avoidance path for the obstacle based on the geometric feature information and size parameters includes:

[0012] Based on the geometric feature information and size parameters, the obstacle is expanded to obtain the obstacle feature contour graphic corresponding to the obstacle;

[0013] Based on the obstacle feature contour graphic corresponding to the obstacle, the improved shortest tangent method is used to determine the initial obstacle avoidance path for the obstacle.

[0014] Optionally, when the obstacle feature contour graphic is an obstacle feature circle, determining the initial obstacle avoidance path for the obstacle using an improved shortest tangent method based on the obstacle feature contour graphic corresponding to the obstacle includes:

[0015] Based on the intersection of the obstacle feature circle and the straight operating path of the agricultural machinery, and the size parameters of the agricultural machinery, a second initial obstacle avoidance point and a sixth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery.

[0016] Based on the second initial obstacle avoidance point and the sixth initial obstacle avoidance point, the tangents of the obstacle feature circle are determined, and the tangent points are the third initial obstacle avoidance point and the fifth initial obstacle avoidance point, respectively.

[0017] The fourth initial obstacle avoidance point is determined based on the intersection of the first and second lines, wherein the first line is the line connecting the second and third initial obstacle avoidance points, and the second line is the line connecting the sixth and fifth initial obstacle avoidance points.

[0018] Using the intersection of the first parallel line and the second parallel line as the center, where the first parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the second parallel line is a parallel line whose distance from the line connecting the second initial obstacle avoidance point and the fourth initial obstacle avoidance point is equal to the minimum turning radius of the agricultural machinery, a circle with the minimum turning radius of the agricultural machinery is determined. Based on the tangent point between the circle with the minimum turning radius of the agricultural machinery and the straight operating path of the agricultural machinery, the first initial obstacle avoidance point is determined.

[0019] Using the intersection of the first and third parallel lines as the center, where the third parallel line is a parallel line whose distance from the line connecting the sixth and fourth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the second minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the second minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the seventh initial obstacle avoidance point is determined.

[0020] Based on the first, second, third, fourth, fifth, sixth, and seventh initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

[0021] Optionally, when the obstacle feature contour graphic is an obstacle feature rectangle, the step of determining the initial obstacle avoidance path for the obstacle using the improved shortest tangent method based on the obstacle feature contour graphic corresponding to the obstacle includes:

[0022] Based on the intersection of the obstacle feature rectangle and the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery, the ninth initial obstacle avoidance point and the thirteenth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery.

[0023] Based on the ninth and thirteenth initial obstacle avoidance points, draw the line connecting the geometric center of the obstacle feature rectangle to the first vertex, and the perpendicular line connecting the geometric center of the obstacle feature rectangle to the second vertex, respectively, to determine the first and second feet of the perpendicular. Using the geometric center of the obstacle feature rectangle as the center and the distance between the geometric center of the obstacle feature rectangle and the first foot of the perpendicular as the radius, obtain the outer circle of the obstacle feature rectangle; wherein the line segment formed by connecting the first and second vertices of the obstacle feature rectangle does not intersect the straight-line operation path of the agricultural machinery.

[0024] Based on the tangent point between the outer circle of the obstacle feature rectangle and the parallel line of the agricultural machinery straight operation path, the tangent point on the arc of the sector formed by the first perpendicular foot, the second perpendicular foot and the geometric center of the obstacle feature rectangle with an included angle of less than 180 degrees is selected as the eleventh initial obstacle avoidance point.

[0025] The tenth initial obstacle avoidance point is determined based on the intersection of the fourth parallel line and the third connecting line, wherein the fourth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the third connecting line is a line connecting the ninth initial obstacle avoidance point and the first perpendicular foot. The twelfth initial obstacle avoidance point is determined based on the intersection of the fifth parallel line and the fourth connecting line, wherein the fifth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the fourth connecting line is a line connecting the thirteenth initial obstacle avoidance point and the second perpendicular foot.

[0026] Using the intersection of the sixth and seventh parallel lines as the center, where the sixth parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the seventh parallel line is a parallel line whose distance from the line connecting the ninth and tenth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, a third minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the third minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, an eighth initial obstacle avoidance point is determined.

[0027] Using the intersection of the sixth and eighth parallel lines as the center, where the eighth parallel line is a parallel line whose distance from the line connecting the thirteenth and twelfth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the fourth minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the fourth minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the fourteenth initial obstacle avoidance point is determined.

[0028] Based on the eighth, ninth, tenth, eleventh, twelfth, thirteenth, and fourteenth initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

[0029] Optionally, the step of constructing the agricultural machinery obstacle avoidance trajectory function using the initial obstacle avoidance point as the trajectory node includes:

[0030] Based on the distance between adjacent trajectory nodes, the time allocation of the agricultural machinery obstacle avoidance trajectory is performed according to the uniform speed time allocation, and the time allocation result of the agricultural machinery obstacle avoidance trajectory is obtained.

[0031] Based on the time allocation results of the agricultural machinery obstacle avoidance trajectory, an agricultural machinery obstacle avoidance trajectory function is constructed.

[0032] Optionally, the determination of the constraints that need to be met during the obstacle avoidance process of the agricultural machinery includes:

[0033] Based on the preset values ​​of the position, velocity, and acceleration of the first and last trajectory nodes on the initial obstacle avoidance path, and the fact that the position, velocity, and acceleration of the intermediate trajectory nodes on the initial obstacle avoidance path remain unchanged, an equality constraint condition is constructed.

[0034] Based on the trajectory node and multiple trajectory sub-nodes between adjacent trajectory nodes, the passable area of ​​the initial obstacle avoidance path is constructed, and inequality constraints are constructed based on the passable area of ​​the initial obstacle avoidance path.

[0035] Optionally, based on the constraints, the objective function is solved to obtain the optimal obstacle avoidance path for the agricultural machinery, including:

[0036] Based on the constraints, the objective function is solved using a QP solver to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0037] The present invention also provides an obstacle avoidance device for autonomous operation of agricultural machinery, comprising:

[0038] The acquisition module is used to acquire the geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery;

[0039] The first processing module is used to determine an initial obstacle avoidance path for the obstacle based on the geometric feature information and size parameters. The initial obstacle avoidance path consists of multiple initial obstacle avoidance points.

[0040] The second processing module is used to construct an obstacle avoidance trajectory function for agricultural machinery using the initial obstacle avoidance point as the trajectory node;

[0041] The third processing module is used to construct an objective function based on the agricultural machinery obstacle avoidance trajectory function, with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance, and to determine the constraints that the agricultural machinery needs to satisfy during obstacle avoidance.

[0042] The solution module is used to solve the objective function based on the constraints to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0043] The present invention also provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the obstacle avoidance method for autonomous operation of agricultural machinery as described above.

[0044] The present invention also provides a non-transitory computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the obstacle avoidance method for autonomous operation of agricultural machinery as described above.

[0045] This invention provides an obstacle avoidance method for autonomous agricultural machinery operation. It acquires the geometric features of obstacles along the straight operating path of the agricultural machinery and the dimensional parameters of the machinery to generate an initial obstacle avoidance path. Based on this initial path, it constructs an obstacle avoidance trajectory function, determining the objective function to minimize the change in power during obstacle avoidance. It also identifies the constraints that the machinery must satisfy during obstacle avoidance and solves to obtain the optimal obstacle avoidance path. This method generates a safe, reliable, smooth, and optimal obstacle avoidance path that meets the requirements for tracking the machinery along its straight operating path, enabling the machinery to safely avoid obstacles while minimizing power changes. Attached Figure Description

[0046] To more clearly illustrate the technical solutions in this invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this invention. For those skilled in the art, other drawings can be obtained from these drawings without creative effort.

[0047] Figure 1 This is one of the flowcharts of the obstacle avoidance method for autonomous operation of agricultural machinery provided by the present invention;

[0048] Figure 2 This is a schematic diagram of the structure of the obstacle feature circle provided by the present invention;

[0049] Figure 3 This is a schematic diagram of the rectangular obstacle feature provided by the present invention;

[0050] Figure 4 This is one of the schematic diagrams of the improved shortest tangent method provided by the present invention;

[0051] Figure 5 This is the second schematic diagram of the improved shortest tangent method provided by the present invention;

[0052] Figure 6 This is one of the schematic diagrams of agricultural machinery obstacle avoidance paths provided by the present invention;

[0053] Figure 7 This is a schematic diagram of the passable area provided by the present invention;

[0054] Figure 8 This is the second schematic diagram of the obstacle avoidance path for agricultural machinery provided by the present invention;

[0055] Figure 9 This is the second flowchart of the obstacle avoidance method for autonomous operation of agricultural machinery provided by the present invention;

[0056] Figure 10 This is a schematic diagram of the obstacle avoidance device for autonomous operation of agricultural machinery provided by the present invention;

[0057] Figure 11 This is a schematic diagram of the structure of the electronic device provided by the present invention. Detailed Implementation

[0058] To make the objectives, technical solutions, and advantages of this invention clearer, the technical solutions of this invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this invention. All other embodiments obtained by those skilled in the art based on the embodiments of this invention without creative effort are within the scope of protection of this invention.

[0059] Figure 1 This is one of the flowcharts illustrating the obstacle avoidance method for autonomous agricultural machinery operation provided by this invention, such as... Figure 1 As shown, the obstacle avoidance method for autonomous operation of agricultural machinery provided by the present invention includes steps 110, 120, 130, 140 and 150.

[0060] Step 110: Obtain the geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery.

[0061] In this embodiment of the invention, before the agricultural machinery begins operation, a straight-line operation path for the agricultural machinery to operate within the entire farmland is obtained based on a pre-acquired farmland map.

[0062] Based on the pre-acquired farmland map and in accordance with the Urban Basic Geographic Information System Technical Specification CJJ100-2004, obstacles in the farmland are classified according to their geometric attributes into cylindrical obstacles such as utility poles, trees, and irrigation wells, and rectangular obstacles such as agricultural machinery, piles of straw, and bushes. The cross-sectional geometry of cylindrical obstacles is circular, and the cross-sectional geometry of rectangular obstacles is rectangular.

[0063] The geometric feature information of an obstacle is determined by its cross-sectional geometry, which includes the obstacle's cross-sectional geometry and dimensional parameters.

[0064] The dimensional parameters of agricultural machinery include its length, width, and minimum turning radius.

[0065] Step 120: Based on the geometric feature information and size parameters, determine the initial obstacle avoidance path for the obstacle, wherein the initial obstacle avoidance path consists of multiple initial obstacle avoidance points.

[0066] In this embodiment of the invention, the obstacle avoidance distance is determined based on the geometric feature information of the obstacle and the size parameters of the agricultural machinery. The obstacle avoidance distance is the sum of the radius of the obstacle and half the width of the agricultural machinery, or the sum of the maximum distance from the center of the obstacle to the top corner and half the width of the agricultural machinery.

[0067] During the operation of agricultural machinery along a straight working path, it is determined whether the distance between the center of the rear axle of the agricultural machinery and the obstacle exceeds the obstacle avoidance distance.

[0068] If the distance between the rear axle center of the agricultural machinery and the obstacle exceeds the obstacle avoidance distance, the agricultural machinery shall continue to operate along the straight operating path.

[0069] If the distance between the rear axle center of the agricultural machinery and the obstacle does not exceed the obstacle avoidance distance, multiple initial obstacle avoidance points are generated based on the geometric features of the obstacle and the size parameters of the agricultural machinery. The initial obstacle avoidance points form the initial obstacle avoidance path for the obstacle.

[0070] It should be noted that multiple initial obstacle avoidance points can be generated using the improved shortest tangent method, or other algorithms such as the A* algorithm, RRT algorithm, and D* algorithm can be used to generate initial obstacle avoidance points based on the geometric features of the obstacles and the size parameters of the agricultural machinery, depending on actual needs.

[0071] Optionally, step 120 includes steps 1201 and 1202.

[0072] Step 1201: Based on the geometric feature information and size parameters, the obstacle is expanded to obtain the obstacle feature contour graphic corresponding to the obstacle.

[0073] In this embodiment of the invention, based on the geometric feature information of the obstacle, a puffing processing method for the obstacle is determined, and based on the puffed obstacle, a corresponding obstacle feature contour graphic is determined. The obstacle feature contour graphic corresponding to the obstacle includes an obstacle feature circle and an obstacle feature rectangle.

[0074] When the cross-sectional geometry of an obstacle is circular, a three-layer structure is used to expand the obstacle. Based on the obstacle's dimensions, its radius is obtained. The first layer is the circular cross-section of the obstacle. The second layer expands to half the width of the agricultural machinery, and the third layer expands to include a safety distance. These three layers are three concentric circles centered on the geometric center of the obstacle. The characteristic circle of the obstacle is obtained through these three layers.

[0075] It should be noted that the safety distance can be half the diagonal length of the smallest geometric unit constituting the passable area, or it can be set according to actual needs. This invention does not impose any specific limitations on it.

[0076] Figure 2 This is a schematic diagram of the structure of the obstacle feature circle provided by the present invention, as shown below. Figure 2 As shown, point O is the geometric center of the obstacle, |OA| is the radius of the obstacle, |AB| is half the width of the agricultural machinery, and |BC| is the safety distance.

[0077] When the cross-sectional geometry of the obstacle is rectangular, a two-layer structure is used to expand the obstacle. The first layer is the rectangular cross-section of the obstacle. The second layer is formed by expanding the width of the agricultural machinery by half. The first and second layers are concentric rectangles with the geometric center of the obstacle as the geometric center. The distance between two vertices of the rectangles in the first and second layers in the same direction is equal to half the width of the agricultural machinery.

[0078] Figure 3 This is a schematic diagram of the rectangular obstacle feature structure provided by the present invention, as shown below. Figure 3 As shown, the vertices O1 and O2 of the rectangle in the first layer structure are in the same direction, and |O1O2| is equal to half the width of the agricultural machinery.

[0079] Step 1202: Based on the obstacle feature contour graphic corresponding to the obstacle, the improved shortest tangent method is used to determine the initial obstacle avoidance path for the obstacle.

[0080] In this embodiment of the invention, an improved shortest tangent method is used to obtain multiple initial obstacle avoidance points for the feature contour of the obstacle, and based on the initial obstacle avoidance points, an initial obstacle avoidance path for the obstacle is determined.

[0081] In this embodiment of the invention, the improved shortest tangent method can easily and quickly generate multiple obstacle avoidance points for the feature contour of the obstacle. The obstacle avoidance point that meets the obstacle avoidance conditions is selected as the initial obstacle avoidance point. Based on the initial obstacle avoidance point, the initial obstacle avoidance path can simultaneously have the advantages of being continuous in position and direction and having a short obstacle avoidance length.

[0082] Optionally, when the obstacle feature contour graphic is an obstacle feature circle, determining the initial obstacle avoidance path for the obstacle using an improved shortest tangent method based on the obstacle feature contour graphic corresponding to the obstacle includes:

[0083] Based on the intersection of the obstacle feature circle and the straight operating path of the agricultural machinery, and the size parameters of the agricultural machinery, a second initial obstacle avoidance point and a sixth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery.

[0084] Based on the second initial obstacle avoidance point and the sixth initial obstacle avoidance point, the tangents of the obstacle feature circle are determined, and the tangent points are the third initial obstacle avoidance point and the fifth initial obstacle avoidance point, respectively.

[0085] The fourth initial obstacle avoidance point is determined based on the intersection of the first and second lines, wherein the first line is the line connecting the second and third initial obstacle avoidance points, and the second line is the line connecting the sixth and fifth initial obstacle avoidance points.

[0086] Using the intersection of the first parallel line and the second parallel line as the center, where the first parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the second parallel line is a parallel line whose distance from the line connecting the second initial obstacle avoidance point and the fourth initial obstacle avoidance point is equal to the minimum turning radius of the agricultural machinery, a circle with the minimum turning radius of the agricultural machinery is determined. Based on the tangent point between the circle with the minimum turning radius of the agricultural machinery and the straight operating path of the agricultural machinery, the first initial obstacle avoidance point is determined.

[0087] Using the intersection of the first and third parallel lines as the center, where the third parallel line is a parallel line whose distance from the line connecting the sixth and fourth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the second minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the second minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the seventh initial obstacle avoidance point is determined.

[0088] Based on the first, second, third, fourth, fifth, sixth, and seventh initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

[0089] The following, in conjunction with the accompanying drawings, details how, when the obstacle feature contour graphic is an obstacle feature circle, an improved shortest tangent method is used to determine the initial obstacle avoidance path for the obstacle based on the obstacle feature contour graphic corresponding to the obstacle. Figure 4 This is one of the schematic diagrams of the improved shortest tangent method provided by the present invention, such as... Figure 4 As shown, straight line AB is the straight operation path of agricultural machinery. The circle with radius robs and geometric center O is the cross-sectional geometry of the obstacle. The circle with radius R and geometric center O is the obstacle feature circle corresponding to the obstacle.

[0090] The straight operating path AB of the agricultural machinery intersects the characteristic circle of the obstacle at points M and N. Points C and D are determined on the straight operating path AB, with point C to the left of point M and point D to the right of point N. |MC|=|ND|=len, where len is the length of the agricultural machinery. Point C is the second initial obstacle avoidance point, and point D is the sixth initial obstacle avoidance point.

[0091] Draw tangents to the feature circle of the obstacle through points C and D, with points E and F as the points of tangency, respectively. The intersection of the two tangents is point P. Point E is the third initial obstacle avoidance point, point F is the fifth initial obstacle avoidance point, and point P is the fourth initial obstacle avoidance point.

[0092] A line parallel to the straight operating path AB at a distance rmin, and a line parallel to the straight line CP at a distance rmin, intersect at point O1. With point O1 as the center and rmin as the radius, draw circle 1, representing the minimum turning radius of the agricultural machinery. This circle is tangent to the straight operating path AB and the straight line CP at points G and H, respectively. A line parallel to the straight operating path AB at a distance rmin, and a line parallel to the straight line DP at a distance rmin, intersect at point O2. With point O2 as the center and rmin as the radius, draw circle 2, representing the minimum turning radius of the agricultural machinery. This circle is tangent to the straight operating path AB and the straight line DP at points J and I, respectively. Point G is the first initial obstacle avoidance point, point J is the seventh initial obstacle avoidance point, and rmin is the minimum turning radius of the agricultural machinery.

[0093] Optionally, when the obstacle feature contour graphic is an obstacle feature rectangle, the step of determining the initial obstacle avoidance path for the obstacle using the improved shortest tangent method based on the obstacle feature contour graphic corresponding to the obstacle includes:

[0094] Based on the intersection of the obstacle feature rectangle and the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery, the ninth initial obstacle avoidance point and the thirteenth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery.

[0095] Based on the ninth and thirteenth initial obstacle avoidance points, draw the line connecting the geometric center of the obstacle feature rectangle to the first vertex, and the perpendicular line connecting the geometric center of the obstacle feature rectangle to the second vertex, respectively, to determine the first and second feet of the perpendicular. Using the geometric center of the obstacle feature rectangle as the center and the distance between the geometric center of the obstacle feature rectangle and the first foot of the perpendicular as the radius, obtain the outer circle of the obstacle feature rectangle; wherein the line segment formed by connecting the first and second vertices of the obstacle feature rectangle does not intersect the straight-line operation path of the agricultural machinery.

[0096] Based on the tangent point between the outer circle of the obstacle feature rectangle and the parallel line of the agricultural machinery straight operation path, the tangent point on the arc of the sector formed by the first perpendicular foot, the second perpendicular foot and the geometric center of the obstacle feature rectangle with an included angle of less than 180 degrees is selected as the eleventh initial obstacle avoidance point.

[0097] The tenth initial obstacle avoidance point is determined based on the intersection of the fourth parallel line and the third connecting line, wherein the fourth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the third connecting line is a line connecting the ninth initial obstacle avoidance point and the first perpendicular foot. The twelfth initial obstacle avoidance point is determined based on the intersection of the fifth parallel line and the fourth connecting line, wherein the fifth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the fourth connecting line is a line connecting the thirteenth initial obstacle avoidance point and the second perpendicular foot.

[0098] Using the intersection of the sixth and seventh parallel lines as the center, where the sixth parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the seventh parallel line is a parallel line whose distance from the line connecting the ninth and tenth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, a third minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the third minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, an eighth initial obstacle avoidance point is determined.

[0099] Using the intersection of the sixth and eighth parallel lines as the center, where the eighth parallel line is a parallel line whose distance from the line connecting the thirteenth and twelfth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the fourth minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the fourth minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the fourteenth initial obstacle avoidance point is determined.

[0100] Based on the eighth, ninth, tenth, eleventh, twelfth, thirteenth, and fourteenth initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

[0101] The following, in conjunction with the accompanying drawings, details how, when the obstacle feature contour graphic is an obstacle feature rectangle, an improved shortest tangent method is used to determine the initial obstacle avoidance path for the obstacle based on the obstacle feature contour graphic corresponding to the obstacle. Figure 5 This is the second schematic diagram of the improved shortest tangent method provided by the present invention, as shown below. Figure 5 As shown, straight line AB is the straight operation path of agricultural machinery, and rectangles O1O2O3O4 are the obstacle feature rectangles corresponding to obstacles.

[0102] The straight operating path AB of the agricultural machinery intersects with the rectangular obstacle feature at points M and N. Points C and D are determined on the straight operating path AB, with point C to the left of point M and point D to the right of point N. |MC|=|ND|=len, where len is the length of the agricultural machinery. Point C is the ninth initial obstacle avoidance point, and point D is the thirteenth initial obstacle avoidance point.

[0103] Draw perpendicular lines from points C and D to lines OO1 and OO2, respectively, with the feet of the perpendiculars at points R and S. Construct a circle with radius |OR| and center at O ​​to obtain the outer circle O. Determine point P based on the two points of tangency between the line parallel to the agricultural machinery's straight operating path AB and circle O, and the arc of the sector ROS with an included angle less than 180 degrees. The line parallel to the agricultural machinery's straight operating path AB passing through point P intersects lines CR and DS at points J and K, respectively. Point J is the tenth initial obstacle avoidance point, point P is the eleventh initial obstacle avoidance point, and point K is the twelfth initial obstacle avoidance point.

[0104] A line parallel to the straight operating path AB at a distance rmin, and a line parallel to the straight line CJ at a distance rmin, intersect at point O5. With point O5 as the center and rmin as the radius, draw circle 5, representing the minimum turning radius of the agricultural machinery. This circle is tangent to the straight operating path AB and the straight line CJ at points E and H, respectively. A line parallel to the straight operating path AB at a distance rmin, and a line parallel to the straight line DK at a distance rmin, intersect at point O6. With point O6 as the center and rmin as the radius, draw circle 6, representing the minimum turning radius of the agricultural machinery. This circle is tangent to the straight operating path AB and the straight line DK at points F and I, respectively. Point E is the eighth initial obstacle avoidance point, point F is the fourteenth initial obstacle avoidance point, and rmin is the minimum turning radius of the agricultural machinery.

[0105] Step 130: Using the initial obstacle avoidance point as the trajectory node, construct the agricultural machinery obstacle avoidance trajectory function.

[0106] In this embodiment of the invention, a polynomial curve can be used to construct the obstacle avoidance trajectory function of agricultural machinery, or a B-spline curve or a Dobbins curve can be used to construct the obstacle avoidance trajectory function of agricultural machinery.

[0107] Different methods for constructing curves can be used to construct the obstacle avoidance trajectory function of agricultural machinery according to actual needs, and this invention does not impose specific limitations on this.

[0108] Optionally, the step of constructing the agricultural machinery obstacle avoidance trajectory function using the initial obstacle avoidance point as the trajectory node includes:

[0109] Based on the distance between adjacent trajectory nodes, the time allocation of the agricultural machinery obstacle avoidance trajectory is performed according to the uniform speed time allocation, and the time allocation result of the agricultural machinery obstacle avoidance trajectory is obtained.

[0110] Based on the time allocation results of the agricultural machinery obstacle avoidance trajectory, an agricultural machinery obstacle avoidance trajectory function is constructed.

[0111] In this embodiment of the invention, time allocation is performed on the trajectory between adjacent nodes based on the proportion of the distance between adjacent trajectory nodes to the entire obstacle avoidance trajectory of the agricultural machinery.

[0112] A uniform time allocation method is used to allocate time for the obstacle avoidance trajectory of agricultural machinery, and the time allocation results of the trajectory between adjacent trajectory nodes in the obstacle avoidance trajectory are obtained.

[0113] In other embodiments of the present invention, time allocation is performed on the obstacle avoidance trajectory of agricultural machinery using fixed time allocation, time allocation based on T-shaped speed curve, or time allocation based on S-shaped speed curve.

[0114] For example, the trajectory between adjacent trajectory nodes can be represented as:

[0115]

[0116] Where p(t) represents the position of the trajectory at time t, a0, a1, ..., a n Let be the trajectory parameters, and n be the polynomial order. Let the parameter vector be p = [a0, a1, ..., a...]. n ] T The obstacle avoidance trajectory function of agricultural machinery can be expressed as:

[0117]

[0118] Where K is the number of segments of the trajectory, and the trajectory between adjacent trajectory nodes is considered as a single trajectory segment.

[0119] Step 140: Based on the agricultural machinery obstacle avoidance trajectory function, construct an objective function with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance, and determine the constraints that the agricultural machinery needs to satisfy during obstacle avoidance.

[0120] In this embodiment of the invention, an objective function is constructed based on the obstacle avoidance trajectory function of agricultural machinery, with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance.

[0121] For example, the velocity v, acceleration a, reciprocal of acceleration jerk, and second derivative of acceleration snap of the obstacle avoidance trajectory of agricultural machinery can be expressed as:

[0122] v(t)=p′(t)=[0,1,2t,3t 2 4t 3 ,...,nt n-1 ]·p

[0123] a(t)=p″(t)=[0,0,2,6t,12t 2 ,...,n(n-1)t n-2 ]·p

[0124]

[0125]

[0126] The goal is to find the minimum value of the snap. During the operation of agricultural machinery, the smaller the change in power, the more beneficial it is to reduce energy consumption.

[0127] minf(p)=min(p (4) (t)) 2 =minp T Qp

[0128]

[0129] Where p is the parameter vector to be solved, Q is a diagonal matrix, and Q0 is the parameter vector to be solved. k It is the parameter matrix of the k-th segment of the trajectory.

[0130] Optionally, determining the constraints that need to be met during the obstacle avoidance process of the agricultural machinery includes steps 1401 and 1402.

[0131] Step 1401: Based on the preset values ​​of the position, velocity, and acceleration of the first and last trajectory nodes on the initial obstacle avoidance path, and the fact that the position, velocity, and acceleration of the intermediate trajectory nodes on the initial obstacle avoidance path remain unchanged, construct equality constraints.

[0132] In this embodiment of the invention, by constraining the position, speed, and acceleration of the first and last trajectory nodes on the initial obstacle avoidance path to preset values, the agricultural machinery's driving state remains consistent when it travels from the straight-line operation path to the first trajectory segment.

[0133] By constraining the position, velocity, and acceleration of intermediate trajectory nodes on the initial obstacle avoidance path to remain constant, it is ensured that when the agricultural machinery travels along the obstacle avoidance trajectory, the driving state of the agricultural machinery remains consistent from the end of the adjacent previous trajectory segment to the beginning of the next trajectory segment.

[0134] For example, equality constraints are expressed as:

[0135]

[0136]

[0137] Where p0 is the starting position of the entire trajectory, i.e., the horizontal and vertical coordinates of the starting point.

[0138] v0 is the starting velocity of the entire trajectory, i.e., the lateral velocity and the longitudinal velocity.

[0139] a0 is the initial acceleration of the entire trajectory, i.e., the lateral acceleration and the longitudinal acceleration.

[0140] p k It is the endpoint of the entire trajectory, i.e., the x and y coordinates of the endpoint.

[0141] v k It refers to the final velocity of the entire trajectory, namely the lateral velocity and the longitudinal velocity.

[0142] a k It is the acceleration at the end of the entire trajectory, namely the lateral acceleration and the longitudinal acceleration.

[0143] Figure 6 This is one of the schematic diagrams of agricultural machinery obstacle avoidance paths provided by the present invention, such as... Figure 6 As shown, after adding equality constraints, the agricultural machinery obstacle avoidance trajectory can be smooth and continuous with only equality constraints, but the trajectory may intersect with the obstacle area again.

[0144] Step 1402: Based on the trajectory node and multiple trajectory sub-nodes between adjacent trajectory nodes, construct the passable area of ​​the initial obstacle avoidance path, and construct inequality constraints based on the passable area of ​​the initial obstacle avoidance path.

[0145] In this embodiment of the invention, multiple trajectory sub-nodes are set on the straight line connecting adjacent trajectory nodes, and the distance between adjacent trajectory sub-nodes is equal to the side length of the passable sub-region.

[0146] Passable sub-regions can be square, rectangular, or rhomboid.

[0147] Multiple traversable sub-regions are constructed, with trajectory nodes and trajectory sub-nodes serving as the geometric centers of the traversable sub-regions.

[0148] Based on multiple passable sub-regions, construct the passable region of the initial obstacle avoidance path.

[0149] Based on the passable area of ​​the initial obstacle avoidance path, construct inequality constraints.

[0150] For example, taking a square with a side length of 0.5m as the passable subregion, the inequality constraint is expressed as:

[0151] x min ≤p ix (t)≤x max

[0152] y min ≤p iy (t)≤y max

[0153] Where, x min It is the lower limit of the horizontal coordinate of the position constraint.

[0154] x max It is the upper limit of the horizontal coordinate of the position constraint.

[0155] y minIt is the lower limit of the horizontal coordinate of the position constraint.

[0156] y max It is the upper limit of the horizontal coordinate of the position constraint.

[0157] p ix (t) is the x-coordinate of the i-th segment of the trajectory at time t.

[0158] P iy (t) is the ordinate of the i-th segment of the trajectory at time t.

[0159] Figure 7 This is a schematic diagram of the passable area provided by the present invention, such as... Figure 7 As shown, multiple passable sub-regions are constructed with adjacent trajectory sub-nodes as geometric centers.

[0160] In this embodiment of the invention, in order to prevent the trajectory from intersecting with obstacles, a passable area is added to limit the optimization range of the trajectory, ensuring that the optimized trajectory does not intersect with obstacles.

[0161] Step 150: Based on the constraints, solve the objective function to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0162] Optionally, based on the constraints, the objective function is solved to obtain the optimal obstacle avoidance path for the agricultural machinery, including:

[0163] Based on the constraints, the objective function is solved using a QP solver to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0164] In this embodiment of the invention, the problem of minimizing the objective function can be transformed into a quadratic optimization problem. Under constraints, the objective function is solved using a quadratic optimization solver, namely a QP solver, to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0165] Figure 8 This is the second schematic diagram of the obstacle avoidance path for agricultural machinery provided by this invention. After adding equality and inequality constraints, the optimal obstacle avoidance path obtained by solving is as follows. Figure 8 As shown.

[0166] Figure 9 This is the second flowchart illustrating the obstacle avoidance method for autonomous agricultural machinery operation provided by this invention, as shown below. Figure 9 As shown, obstacle avoidance methods for autonomous agricultural machinery operation include:

[0167] Step 901: Obtain the geometric feature information of the obstacles and the size parameters of the agricultural machinery.

[0168] Step 902: Divide the obstacle into obstacle feature circles and obstacle feature rectangles based on the geometric feature information of the obstacle, and then proceed to step 9031 or step 9032.

[0169] Step 9031: Determine the feature circle of the obstacle, then proceed to step 9041.

[0170] Step 9041: Use the improved shortest tangent method to generate the initial obstacle avoidance path, and proceed to step 905.

[0171] Step 9032: Determine the feature rectangle of the obstacle, then proceed to step 9042.

[0172] Step 9042: Use the improved shortest tangent method to generate the initial obstacle avoidance path, and proceed to step 905.

[0173] Step 905: For the initial obstacle avoidance path, construct a target function that minimizes the snap.

[0174] Step 906: Add equality constraints to ensure the continuity and smoothness of the trajectory.

[0175] Step 907: Add inequality constraints to ensure safety and prevent the trajectory from colliding with obstacles.

[0176] Step 908: Solve using the QP solver.

[0177] Step 909: Obtain the optimal obstacle avoidance path for the agricultural machinery.

[0178] The obstacle avoidance method for autonomous operation of agricultural machinery provided by this invention generates an optimal obstacle avoidance path for agricultural machinery that is safe, reliable, smooth and meets the tracking requirements of agricultural machinery, so that agricultural machinery can safely avoid obstacles on the straight operation path of agricultural machinery with minimal changes in power.

[0179] Figure 10 This is a schematic diagram of the obstacle avoidance device for autonomous agricultural machinery provided by the present invention, as shown below. Figure 10 As shown, the obstacle avoidance device for autonomous agricultural machinery operation provided by the present invention includes:

[0180] The acquisition module 1001 is used to acquire the geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery;

[0181] The first processing module 1002 is used to determine an initial obstacle avoidance path for the obstacle based on the geometric feature information and size parameters. The initial obstacle avoidance path is composed of multiple initial obstacle avoidance points.

[0182] The second processing module 1003 is used to construct an agricultural machinery obstacle avoidance trajectory function using the initial obstacle avoidance point as a trajectory node;

[0183] The third processing module 1004 is used to construct an objective function based on the agricultural machinery obstacle avoidance trajectory function, with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance, and to determine the constraints that the agricultural machinery needs to satisfy during obstacle avoidance.

[0184] The solver module 1005 is used to solve the objective function based on the constraints to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0185] Optionally, the first processing module 1002 is configured to:

[0186] Based on the geometric feature information and size parameters, the obstacle is expanded to obtain the obstacle feature contour graphic corresponding to the obstacle;

[0187] Based on the obstacle feature contour graphic corresponding to the obstacle, the improved shortest tangent method is used to determine the initial obstacle avoidance path for the obstacle.

[0188] Optionally, when the obstacle feature contour graphic is an obstacle feature circle, determining the initial obstacle avoidance path for the obstacle using an improved shortest tangent method based on the obstacle feature contour graphic corresponding to the obstacle includes:

[0189] Based on the intersection of the obstacle feature circle and the straight operating path of the agricultural machinery, and the size parameters of the agricultural machinery, a second initial obstacle avoidance point and a sixth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery.

[0190] Based on the second initial obstacle avoidance point and the sixth initial obstacle avoidance point, the tangents of the obstacle feature circle are determined, and the tangent points are the third initial obstacle avoidance point and the fifth initial obstacle avoidance point, respectively.

[0191] The fourth initial obstacle avoidance point is determined based on the intersection of the first and second lines, wherein the first line is the line connecting the second and third initial obstacle avoidance points, and the second line is the line connecting the sixth and fifth initial obstacle avoidance points.

[0192] Using the intersection of the first parallel line and the second parallel line as the center, where the first parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the second parallel line is a parallel line whose distance from the line connecting the second initial obstacle avoidance point and the fourth initial obstacle avoidance point is equal to the minimum turning radius of the agricultural machinery, a circle with the minimum turning radius of the agricultural machinery is determined. Based on the tangent point between the circle with the minimum turning radius of the agricultural machinery and the straight operating path of the agricultural machinery, the first initial obstacle avoidance point is determined.

[0193] Using the intersection of the first and third parallel lines as the center, where the third parallel line is a parallel line whose distance from the line connecting the sixth and fourth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the second minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the second minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the seventh initial obstacle avoidance point is determined.

[0194] Based on the first, second, third, fourth, fifth, sixth, and seventh initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

[0195] Optionally, when the obstacle feature contour graphic is an obstacle feature rectangle, the step of determining the initial obstacle avoidance path for the obstacle using the improved shortest tangent method based on the obstacle feature contour graphic corresponding to the obstacle includes:

[0196] Based on the intersection of the obstacle feature rectangle and the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery, the ninth initial obstacle avoidance point and the thirteenth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery.

[0197] Based on the ninth and thirteenth initial obstacle avoidance points, draw the line connecting the geometric center of the obstacle feature rectangle to the first vertex, and the perpendicular line connecting the geometric center of the obstacle feature rectangle to the second vertex, respectively, to determine the first and second feet of the perpendicular. Using the geometric center of the obstacle feature rectangle as the center and the distance between the geometric center of the obstacle feature rectangle and the first foot of the perpendicular as the radius, obtain the outer circle of the obstacle feature rectangle; wherein the line segment formed by connecting the first and second vertices of the obstacle feature rectangle does not intersect the straight-line operation path of the agricultural machinery.

[0198] Based on the tangent point between the outer circle of the obstacle feature rectangle and the parallel line of the agricultural machinery straight operation path, the tangent point on the arc of the sector formed by the first perpendicular foot, the second perpendicular foot and the geometric center of the obstacle feature rectangle with an included angle of less than 180 degrees is selected as the eleventh initial obstacle avoidance point.

[0199] The tenth initial obstacle avoidance point is determined based on the intersection of the fourth parallel line and the third connecting line, wherein the fourth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the third connecting line is a line connecting the ninth initial obstacle avoidance point and the first perpendicular foot. The twelfth initial obstacle avoidance point is determined based on the intersection of the fifth parallel line and the fourth connecting line, wherein the fifth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the fourth connecting line is a line connecting the thirteenth initial obstacle avoidance point and the second perpendicular foot.

[0200] Using the intersection of the sixth and seventh parallel lines as the center, where the sixth parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the seventh parallel line is a parallel line whose distance from the line connecting the ninth and tenth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, a third minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the third minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, an eighth initial obstacle avoidance point is determined.

[0201] Using the intersection of the sixth and eighth parallel lines as the center, where the eighth parallel line is a parallel line whose distance from the line connecting the thirteenth and twelfth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the fourth minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the fourth minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the fourteenth initial obstacle avoidance point is determined.

[0202] Based on the eighth, ninth, tenth, eleventh, twelfth, thirteenth, and fourteenth initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

[0203] Optionally, the second processing module 1003 is used for:

[0204] Based on the distance between adjacent trajectory nodes, the time allocation of the agricultural machinery obstacle avoidance trajectory is performed according to the uniform speed time allocation, and the time allocation result of the agricultural machinery obstacle avoidance trajectory is obtained.

[0205] Based on the time allocation results of the agricultural machinery obstacle avoidance trajectory, an agricultural machinery obstacle avoidance trajectory function is constructed.

[0206] Optionally, the determination of the constraints that need to be met during the obstacle avoidance process of the agricultural machinery includes:

[0207] Based on the preset values ​​of the position, velocity, and acceleration of the first and last trajectory nodes on the initial obstacle avoidance path, and the fact that the position, velocity, and acceleration of the intermediate trajectory nodes on the initial obstacle avoidance path remain unchanged, an equality constraint condition is constructed.

[0208] Based on the trajectory node and multiple trajectory sub-nodes between adjacent trajectory nodes, the passable area of ​​the initial obstacle avoidance path is constructed, and inequality constraints are constructed based on the passable area of ​​the initial obstacle avoidance path.

[0209] Optionally, the solver module 1005 is used for:

[0210] Based on the constraints, the objective function is solved using a QP solver to obtain the optimal obstacle avoidance path for the agricultural machinery.

[0211] It should be noted that the obstacle avoidance device for autonomous operation of agricultural machinery provided in the embodiments of the present invention can realize all the method steps implemented in the embodiments of the obstacle avoidance method for autonomous operation of agricultural machinery, and can achieve the same technical effect, which will not be repeated here.

[0212] The obstacle avoidance device provided by this invention for autonomous operation of agricultural machinery generates an optimal obstacle avoidance path for agricultural machinery that is safe, reliable, smooth and meets the tracking requirements of agricultural machinery, so that agricultural machinery can safely avoid obstacles on the straight operation path of agricultural machinery with minimal changes in power.

[0213] Figure 11 An example is a schematic diagram of the physical structure of an electronic device, such as... Figure 11 As shown, the electronic device may include a processor 1110, a communication interface 1120, a memory 1130, and a communication bus 1140, wherein the processor 1110, the communication interface 1120, and the memory 1130 communicate with each other through the communication bus 1140. The processor 1110 can call logical instructions in the memory 1130 to execute an obstacle avoidance method for autonomous agricultural machinery operation. The method includes: acquiring geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery; determining an initial obstacle avoidance path for the obstacles based on the geometric feature information and size parameters, wherein the initial obstacle avoidance path consists of multiple initial obstacle avoidance points; constructing an obstacle avoidance trajectory function for the agricultural machinery using the initial obstacle avoidance points as trajectory nodes; constructing an objective function based on the obstacle avoidance trajectory function, with the goal of minimizing the power change of the agricultural machinery during obstacle avoidance, and determining the constraints that the agricultural machinery needs to satisfy during obstacle avoidance; and solving the objective function based on the constraints to obtain the optimal obstacle avoidance path corresponding to the agricultural machinery.

[0214] Furthermore, the logical instructions in the aforementioned memory 1130 can be implemented as software functional units and, when sold or used as independent products, can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or a part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of the present invention. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical disks.

[0215] On the other hand, the present invention also provides a computer program product, which includes a computer program that can be stored on a non-transitory computer-readable storage medium. When the computer program is executed by a processor, the computer can execute the obstacle avoidance method for autonomous operation of agricultural machinery provided by the above methods. The method includes: acquiring geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery; determining an initial obstacle avoidance path for the obstacles based on the geometric feature information and size parameters, wherein the initial obstacle avoidance path is composed of multiple initial obstacle avoidance points; constructing an obstacle avoidance trajectory function for the agricultural machinery using the initial obstacle avoidance points as trajectory nodes; constructing an objective function based on the obstacle avoidance trajectory function, with the goal of minimizing the dynamic change of the agricultural machinery during obstacle avoidance, and determining the constraints that the agricultural machinery needs to satisfy during obstacle avoidance; and solving the objective function based on the constraints to obtain the optimal obstacle avoidance path corresponding to the agricultural machinery.

[0216] In another aspect, the present invention also provides a non-transitory computer-readable storage medium storing a computer program thereon. When executed by a processor, the computer program implements the obstacle avoidance method for autonomous operation of agricultural machinery provided by the above methods. The method includes: acquiring geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery; determining an initial obstacle avoidance path for the obstacles based on the geometric feature information and size parameters, wherein the initial obstacle avoidance path is composed of multiple initial obstacle avoidance points; constructing an obstacle avoidance trajectory function for the agricultural machinery using the initial obstacle avoidance points as trajectory nodes; constructing an objective function based on the obstacle avoidance trajectory function, with the goal of minimizing the dynamic change of the agricultural machinery during obstacle avoidance, and determining the constraints that the agricultural machinery needs to satisfy during obstacle avoidance; and solving the objective function based on the constraints to obtain the optimal obstacle avoidance path corresponding to the agricultural machinery.

[0217] The device embodiments described above are merely illustrative. The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the modules can be selected to achieve the purpose of this embodiment according to actual needs. Those skilled in the art can understand and implement this without any creative effort.

[0218] Through the above description of the embodiments, those skilled in the art can clearly understand that each embodiment can be implemented by means of software plus necessary general-purpose hardware platforms, and of course, it can also be implemented by hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.

[0219] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, and not to limit them; although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some of the technical features; and these modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the embodiments of the present invention.

Claims

1. An obstacle avoidance method for autonomous agricultural machinery operation, characterized in that, include: Obtain the geometric feature information of obstacles on the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery; Based on the geometric feature information and size parameters, an initial obstacle avoidance path is determined for the obstacle, and the initial obstacle avoidance path is composed of multiple initial obstacle avoidance points; Using the initial obstacle avoidance point as the trajectory node, construct the agricultural machinery obstacle avoidance trajectory function; The step of constructing the agricultural machinery obstacle avoidance trajectory function using the initial obstacle avoidance point as the trajectory node includes: Based on the distance between adjacent trajectory nodes, the time allocation of the agricultural machinery obstacle avoidance trajectory is performed according to the uniform time allocation to obtain the time allocation result of the agricultural machinery obstacle avoidance trajectory; based on the time allocation result of the agricultural machinery obstacle avoidance trajectory, the agricultural machinery obstacle avoidance trajectory function is constructed. Based on the obstacle avoidance trajectory function of the agricultural machinery, with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance, and with the aim of minimizing the snap, the minimum value of the snap is found, the objective function is constructed, and the constraints that the agricultural machinery needs to satisfy during obstacle avoidance are determined. The constraints that need to be met during the process of determining the agricultural machinery obstacle avoidance include: Based on the preset values ​​of the position, velocity, and acceleration of the first and last trajectory nodes on the initial obstacle avoidance path, and the fact that the position, velocity, and acceleration of the intermediate trajectory nodes on the initial obstacle avoidance path remain unchanged, equality constraints are constructed; based on the trajectory nodes and multiple trajectory sub-nodes between adjacent trajectory nodes, the passable area of ​​the initial obstacle avoidance path is constructed, and based on the passable area of ​​the initial obstacle avoidance path, inequality constraints are constructed. Based on the constraints, the objective function is solved to obtain the optimal obstacle avoidance path for the agricultural machinery. Based on the aforementioned constraints, the objective function is solved to obtain the optimal obstacle avoidance path for the agricultural machinery, including: Based on the constraints, the objective function is solved using a QP solver to obtain the optimal obstacle avoidance path for the agricultural machinery.

2. The obstacle avoidance method for autonomous agricultural machinery operation according to claim 1, characterized in that, Determining the initial obstacle avoidance path for the obstacle based on the geometric feature information and size parameters includes: Based on the geometric feature information and size parameters, the obstacle is expanded to obtain the obstacle feature contour graphic corresponding to the obstacle; Based on the obstacle feature contour graphic corresponding to the obstacle, the improved shortest tangent method is used to determine the initial obstacle avoidance path for the obstacle.

3. The obstacle avoidance method for autonomous agricultural machinery operation according to claim 2, characterized in that, When the obstacle feature contour is an obstacle feature circle, the step of determining the initial obstacle avoidance path for the obstacle using an improved shortest tangent method based on the obstacle feature contour corresponding to the obstacle includes: Based on the intersection of the obstacle feature circle and the straight operating path of the agricultural machinery, and the size parameters of the agricultural machinery, a second initial obstacle avoidance point and a sixth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery. Based on the second initial obstacle avoidance point and the sixth initial obstacle avoidance point, the tangents of the obstacle feature circle are determined, and the tangent points are the third initial obstacle avoidance point and the fifth initial obstacle avoidance point, respectively. The fourth initial obstacle avoidance point is determined based on the intersection of the first and second lines, wherein the first line is the line connecting the second and third initial obstacle avoidance points, and the second line is the line connecting the sixth and fifth initial obstacle avoidance points. Using the intersection of the first parallel line and the second parallel line as the center, where the first parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the second parallel line is a parallel line whose distance from the line connecting the second initial obstacle avoidance point and the fourth initial obstacle avoidance point is equal to the minimum turning radius of the agricultural machinery, a circle with the minimum turning radius of the agricultural machinery is determined. Based on the tangent point between the circle with the minimum turning radius of the agricultural machinery and the straight operating path of the agricultural machinery, the first initial obstacle avoidance point is determined. Using the intersection of the first and third parallel lines as the center, where the third parallel line is a parallel line whose distance from the line connecting the sixth and fourth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the second minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the second minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the seventh initial obstacle avoidance point is determined. Based on the first, second, third, fourth, fifth, sixth, and seventh initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

4. The obstacle avoidance method for autonomous agricultural machinery operation according to claim 2, characterized in that, When the obstacle feature contour is a rectangular obstacle feature, determining the initial obstacle avoidance path for the obstacle using an improved shortest tangent method based on the obstacle feature contour corresponding to the obstacle includes: Based on the intersection of the obstacle feature rectangle and the straight operating path of the agricultural machinery and the size parameters of the agricultural machinery, the ninth initial obstacle avoidance point and the thirteenth initial obstacle avoidance point are determined on the straight operating path of the agricultural machinery. Based on the ninth and thirteenth initial obstacle avoidance points, draw the line connecting the geometric center of the obstacle feature rectangle to the first vertex, and the perpendicular line connecting the geometric center of the obstacle feature rectangle to the second vertex, respectively, to determine the first and second feet of the perpendicular. Using the geometric center of the obstacle feature rectangle as the center and the distance between the geometric center of the obstacle feature rectangle and the first foot of the perpendicular as the radius, obtain the outer circle of the obstacle feature rectangle; wherein the line segment formed by connecting the first and second vertices of the obstacle feature rectangle does not intersect the straight-line operation path of the agricultural machinery. Based on the tangent point between the outer circle of the obstacle feature rectangle and the parallel line of the agricultural machinery straight operation path, the tangent point on the arc of the sector formed by the first perpendicular foot, the second perpendicular foot and the geometric center of the obstacle feature rectangle with an included angle of less than 180 degrees is selected as the eleventh initial obstacle avoidance point. The tenth initial obstacle avoidance point is determined based on the intersection of the fourth parallel line and the third connecting line, wherein the fourth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the third connecting line is a line connecting the ninth initial obstacle avoidance point and the first perpendicular foot. The twelfth initial obstacle avoidance point is determined based on the intersection of the fifth parallel line and the fourth connecting line, wherein the fifth parallel line is a line parallel to the straight operating path of the agricultural machinery passing through the eleventh initial obstacle avoidance point, and the fourth connecting line is a line connecting the thirteenth initial obstacle avoidance point and the second perpendicular foot. Using the intersection of the sixth and seventh parallel lines as the center, where the sixth parallel line is a parallel line whose distance from the straight operating path of the agricultural machinery is equal to the minimum turning radius of the agricultural machinery, and the seventh parallel line is a parallel line whose distance from the line connecting the ninth and tenth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, a third minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the third minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, an eighth initial obstacle avoidance point is determined. Using the intersection of the sixth and eighth parallel lines as the center, where the eighth parallel line is a parallel line whose distance from the line connecting the thirteenth and twelfth initial obstacle avoidance points is equal to the minimum turning radius of the agricultural machinery, the fourth minimum turning radius circle of the agricultural machinery is determined. Based on the tangent point between the fourth minimum turning radius circle of the agricultural machinery and the straight operating path of the agricultural machinery, the fourteenth initial obstacle avoidance point is determined. Based on the eighth, ninth, tenth, eleventh, twelfth, thirteenth, and fourteenth initial obstacle avoidance points, an initial obstacle avoidance path is determined for the obstacle.

5. An obstacle avoidance device for autonomous operation of agricultural machinery, characterized in that, include: The acquisition module is used to acquire the geometric feature information of obstacles on the straight operation path of the agricultural machinery and the size parameters of the agricultural machinery; The first processing module is used to determine an initial obstacle avoidance path for the obstacle based on the geometric feature information and size parameters. The initial obstacle avoidance path consists of multiple initial obstacle avoidance points. The second processing module is used to construct an obstacle avoidance trajectory function for agricultural machinery using the initial obstacle avoidance point as the trajectory node; The step of constructing the agricultural machinery obstacle avoidance trajectory function using the initial obstacle avoidance point as the trajectory node includes: Based on the distance between adjacent trajectory nodes, the time allocation of the agricultural machinery obstacle avoidance trajectory is performed according to the uniform time allocation to obtain the time allocation result of the agricultural machinery obstacle avoidance trajectory; based on the time allocation result of the agricultural machinery obstacle avoidance trajectory, the agricultural machinery obstacle avoidance trajectory function is constructed. The third processing module is used to construct an objective function based on the agricultural machinery obstacle avoidance trajectory function, with the goal of minimizing the change in power of the agricultural machinery during obstacle avoidance and minimizing the snap, and to determine the constraints that the agricultural machinery needs to satisfy during obstacle avoidance. The constraints that need to be met during the process of determining the agricultural machinery obstacle avoidance include: Based on the preset values ​​of the position, velocity, and acceleration of the first and last trajectory nodes on the initial obstacle avoidance path, and the fact that the position, velocity, and acceleration of the intermediate trajectory nodes on the initial obstacle avoidance path remain unchanged, equality constraints are constructed; based on the trajectory nodes and multiple trajectory sub-nodes between adjacent trajectory nodes, the passable area of ​​the initial obstacle avoidance path is constructed, and based on the passable area of ​​the initial obstacle avoidance path, inequality constraints are constructed. The solution module is used to solve the objective function based on the constraints to obtain the optimal obstacle avoidance path for the agricultural machinery. Based on the aforementioned constraints, the objective function is solved to obtain the optimal obstacle avoidance path for the agricultural machinery, including: Based on the constraints, the objective function is solved using a QP solver to obtain the optimal obstacle avoidance path for the agricultural machinery.

6. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the obstacle avoidance method for autonomous operation of agricultural machinery as described in any one of claims 1 to 4.

7. A non-transitory computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the obstacle avoidance method for autonomous operation of agricultural machinery as described in any one of claims 1 to 4.