CN109934384B - Polygonal land parcel segmentation method and device, storage medium and electronic equipment - Google Patents

Polygonal land parcel segmentation method and device, storage medium and electronic equipment Download PDF

Info

Publication number
CN109934384B
CN109934384B CN201910081517.0A CN201910081517A CN109934384B CN 109934384 B CN109934384 B CN 109934384B CN 201910081517 A CN201910081517 A CN 201910081517A CN 109934384 B CN109934384 B CN 109934384B
Authority
CN
China
Prior art keywords
vertex
boundary
plot
type
barrier
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910081517.0A
Other languages
Chinese (zh)
Other versions
CN109934384A (en
Inventor
齐欣
任贵杰
梅森
宋大雷
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenyang Woozoom Technology Co ltd
Original Assignee
Shenyang Woozoom Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenyang Woozoom Technology Co ltd filed Critical Shenyang Woozoom Technology Co ltd
Priority to CN201910081517.0A priority Critical patent/CN109934384B/en
Publication of CN109934384A publication Critical patent/CN109934384A/en
Application granted granted Critical
Publication of CN109934384B publication Critical patent/CN109934384B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention relates to the field of unmanned aerial vehicle plant protection, and discloses a polygonal plot partitioning method, a device, a storage medium and electronic equipment, wherein the longitude and latitude coordinates are converted into plane coordinates by acquiring the set initial spraying course of an unmanned aerial vehicle, the spraying width, the plot boundary vertex and the position of the barrier boundary vertex, and the x-axis direction and the y-axis direction are determined according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point; sorting the plot boundary vertexes and the barrier boundary vertexes according to the plot segmentation scanning direction; performing block segmentation scanning on the sorted block boundary vertexes and the barrier boundary vertexes to segment the operation block into a plurality of subregions and generate a subregion adjacency graph; and carrying out reverse rotation on the plane coordinate according to the spraying course of the unmanned aerial vehicle so as to acquire and store the boundary information of the partitioned sub-regions. The invention can divide any polygonal plot containing any polygonal barrier into a plurality of simple polygonal plots, so that the covering and spraying operation of each divided plot can be realized by utilizing the existing planning method, and then the spraying operation of any polygonal plot can be realized.

Description

Polygonal land parcel segmentation method and device, storage medium and electronic equipment
Technical Field
The invention relates to the field of unmanned aerial vehicle plant protection, in particular to a polygonal plot partitioning method and device, a storage medium and electronic equipment.
Background
The unmanned aerial vehicle plant protection utilizes the unmanned aerial vehicle to carry out agriculture and forestry plant protection operation, and an autonomous flight mode (that is, the unmanned aerial vehicle automatically flies according to a set air route) or a semi-autonomous flight mode (the unmanned aerial vehicle is controlled to fly by a driver through a remote controller) is generally adopted during operation. For autonomous flight mode, airline planning is an important preparatory step prior to work. Route planning refers to the computation of a reasonable route covering the entire plot by a computer software system according to the coordinates of the farmland plot (usually the plane projection coordinate information of the plot).
Before planning a flight path, whether obstacles exist in a plot and the vicinity of the plot need to be considered, and the plot is divided so as to plan the flight path of the unmanned aerial vehicle better.
Disclosure of Invention
The invention provides a polygonal land parcel segmentation method, which solves the technical problem that a land parcel segmentation method in the prior art is only suitable for convex polygonal land parcel boundaries and obstacle boundaries, but can not be suitable for non-convex polygonal land parcel boundaries and obstacle boundaries.
The purpose of the invention is realized by the following technical scheme:
a polygonal plot partitioning method for unmanned aerial vehicles, comprising:
acquiring a set initial spraying course, a spraying width, a plot boundary vertex and a position of an obstacle boundary vertex of the unmanned aerial vehicle, converting the longitude and latitude coordinates into plane coordinates, and determining the directions of an x axis and a y axis according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point, wherein the initial spraying course is the positive direction of the x axis;
sorting the plot boundary vertexes and the barrier boundary vertexes according to the plot segmentation scanning direction;
performing block segmentation scanning on the sorted block boundary vertexes and the sorted obstacle boundary vertexes to segment the operation block into a plurality of sub-regions and generate a sub-region adjacency graph, wherein the operation block is a region without the obstacle in the block region;
and according to the spraying course of the unmanned aerial vehicle, reversely rotating the plane coordinates to acquire and store the boundary information of the partitioned sub-regions, wherein the boundary information of the sub-regions is a coordinate set of boundary vertexes of the sub-regions.
A polygonal parcel segmentation apparatus for an unmanned aerial vehicle, comprising:
the acquisition module is used for acquiring the set initial spraying course, the spraying width, the plot boundary vertex and the position of the barrier boundary vertex of the unmanned aerial vehicle, converting the longitude and latitude coordinates into plane coordinates, and determining the directions of an x axis and a y axis according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point, wherein the initial spraying course is the positive direction of the x axis;
the sorting module is used for sorting the plot boundary vertexes and the barrier boundary vertexes according to the plot segmentation scanning direction;
the segmentation scanning module is used for performing segmentation scanning on the sorted plot boundary vertexes and the sorted barrier boundary vertexes so as to segment the operation plot into a plurality of subregions and generate a subregion adjacency graph, wherein the operation plot is a region without the barrier in the plot region;
and the storage module is used for reversely rotating the plane coordinates according to the spraying course of the unmanned aerial vehicle so as to acquire and store the boundary information of the divided sub-regions, wherein the boundary information of the sub-regions is a coordinate set of boundary vertexes of the sub-regions.
A non-transitory readable storage medium having stored thereon a computer program which, when executed by a computer, implements the above-described polygonal block division method.
An electronic device comprises a nonvolatile readable storage medium, a processor and a computer program stored on the nonvolatile readable storage medium and capable of running on the processor, wherein the processor executes the computer program to realize the polygon block segmentation method.
According to a fifth aspect of embodiments of the present application, there is also provided a computer program product containing instructions which, when run on a computer, cause the computer to carry out the above-mentioned polygonal block segmentation method when executed.
According to a sixth aspect of embodiments of the present application, there is also provided a computer program which, when run on a computer, causes the computer to perform the above-described polygon block segmentation method.
The invention provides a polygonal plot partitioning method, a device, a storage medium and electronic equipment, wherein the longitude and latitude coordinates of a set unmanned aerial vehicle spraying course, a spraying width, a plot boundary vertex and an obstacle boundary vertex are obtained, the longitude and latitude coordinates are converted into plane coordinates, and the plane coordinates are rotated to ensure that the spraying course is the same as the positive direction of an x axis of a plane coordinate system; sorting the plot boundary vertexes and the barrier boundary vertexes according to the scanning direction; scanning the sorted plot boundary vertexes and the barrier boundary vertexes to divide the operation plot into sub-regions and generate a sub-region adjacency graph; and carrying out reverse rotation on the plane coordinate according to the spraying course of the unmanned aerial vehicle so as to acquire and store the boundary information of the partitioned sub-regions. The invention can divide any polygonal plot containing any polygonal barrier into a plurality of simple polygonal plots, so that the covering and spraying operation of each divided plot can be realized by utilizing the existing planning method, and then the spraying operation of any polygonal plot can be realized.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings needed to be used in the embodiments will be briefly described below, and it is obvious that the drawings in the following description are only some embodiments of the present invention, and it is obvious for those skilled in the art to obtain other drawings without inventive exercise.
FIG. 1 is a flowchart illustrating a method for dividing a polygonal parcel according to a first embodiment of the present invention;
FIG. 2 is a schematic view of a polygonal parcel according to a first embodiment of the present invention;
FIG. 3 is a schematic diagram of a first division of a polygonal parcel according to a first embodiment of the present invention;
FIG. 4 is a schematic diagram illustrating the first division of a polygonal parcel according to a first embodiment of the present invention;
FIG. 5 is a schematic diagram of a polygonal parcel after second segmentation according to a first embodiment of the present invention;
FIG. 6 is a schematic diagram illustrating the polygonal land after the second division according to the first embodiment of the present invention;
FIG. 7 is a diagram illustrating the result of the final segmentation of the polygonal parcel according to the first embodiment of the present invention;
FIG. 8 is a schematic diagram illustrating the final polygonal land block after being divided according to a first embodiment of the present invention;
FIG. 9 is a schematic view of another polygonal parcel of an embodiment of the present invention;
FIG. 10 is a schematic structural diagram of a polygonal block segmentation apparatus according to a third embodiment of the present invention;
fig. 11 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
Example one
An embodiment of the present invention provides a method for dividing a polygonal parcel, as shown in fig. 1, including:
step 101, acquiring a set initial spraying course, a spraying width, a plot boundary vertex and a position of an obstacle boundary vertex of the unmanned aerial vehicle, converting the longitude and latitude coordinates into plane coordinates, and determining x-axis and y-axis directions according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point;
wherein the initial spraying course is the positive direction of the x axis; the spraying course can be changed during the spraying process. Two-dimensional coordinate planes can be customized, for example: the vertical upward direction in the plane can be the positive direction of the x axis, the y axis is the horizontal direction, and in addition, the positive direction of the y axis can be determined according to the position of the land parcel.
Step 102, sorting the plot boundary vertexes and the barrier boundary vertexes according to the plot segmentation scanning direction;
and when the y-axis coordinates are the same, sorting the vertices of the land parcel boundaries and the vertices of the barrier boundaries from small to large according to the x-axis coordinates. After sorting, the first vertex is the top left vertex and the last vertex is the bottom right vertex.
103, carrying out plot segmentation scanning on the sorted plot boundary vertexes and the sorted barrier boundary vertexes to segment the operation plot into a plurality of subregions and generate a subregion adjacency graph;
wherein, the scanning direction can be customized, for example: the scanning direction is set to be a 45-degree direction from the upper left corner to the lower right corner in a plane coordinate system, and the operation land is an area for removing the obstacles in the land area;
step 103 may specifically include:
step 103-1, judging whether the current vertex is marked as scanned;
103-2, when the current vertex is not marked as scanned, acquiring a preamble vertex and a subsequent vertex adjacent to the current vertex, and judging the vertex type of the current vertex according to the plane coordinates of the preamble vertex and the subsequent vertex, wherein the vertex type comprises a first type, a second type, a third type, a fourth type and a fifth type, the first type refers to that the preamble vertex and the subsequent vertex are respectively positioned at the left side and the right side of the current vertex, the second type refers to that the preamble vertex and the subsequent vertex are both positioned at the right side of the current vertex, the third type refers to that the preamble vertex and the subsequent vertex are both positioned at the left side of the current vertex, the fourth type refers to that the preamble vertex is the same as the y-axis coordinate of the current vertex, and the fifth type refers to that the subsequent vertex is the same as the y-axis coordinate of the current vertex;
103-3, when the type of the current vertex is the first type, adding the current vertex into the vertex sequence of the sub-region;
103-4, when the type of the current vertex is the second type, judging whether the left side of the current vertex is outside the operation block, and when the left side of the current vertex is outside the operation block, starting a new sub-region on the right side, and adding the current vertex into a vertex sequence of the new sub-region; when the left side of the current vertex is in the operation block, closing the sub-area on the left side of the current vertex, opening an upper sub-area and a lower sub-area on the right side, and updating the vertex sequence of the sub-areas;
103-5, when the type of the current vertex is a third type, judging whether the right side of the current vertex is outside the operation block, and when the right side of the current vertex is outside the operation block, closing the sub-region and updating the vertex sequence of the sub-region; when the right side of the current vertex is in the operation block, closing the upper and lower subregions of the current vertex, opening a new subregion on the right side, and updating the vertex sequence of the subregions;
103-6, when the type of the current vertex is the fourth type, marking the preamble vertex of the current vertex as a scanned vertex, taking the preamble vertex of the preamble vertex as the preamble vertex of the current vertex, and updating the vertex sequence of the sub-region;
and 103-7, when the type of the current vertex is the fifth type, marking the subsequent vertex of the current vertex as a scanned vertex, taking the subsequent vertex of the subsequent vertex as the subsequent vertex of the current vertex, and updating the vertex sequence of the sub-region.
104, reversely rotating the plane coordinate according to the spraying course of the unmanned aerial vehicle to acquire and store the boundary information of the partitioned sub-area;
and the boundary information of the sub-region is a coordinate set of a boundary vertex of the sub-region.
To better illustrate the first embodiment of the present invention, the following is illustrated:
fig. 2 is a schematic diagram of a polygonal parcel according to a first embodiment of the present invention, wherein vertices A1a 2-a 15 are polygonal parcels, B1B 2-B6 are first polygonal obstacles, and C1C 2-C5 are second polygonal obstacles. Scanning is performed from left to right, assuming the spraying direction is the positive direction of the X axis.
The 1 st vertex is a15, the preceding vertex is a14, the following vertex is a1, and both a14 and a1 are located on the right side of a15 (corresponding to the second type), as described in step 103-4, if it is determined that the left side of a15 is outside the working area, a new sub-area is started on the right side, the sub-area is defined as 1 (corresponding to number 1 in the adjacent map), and the a15 vertex is added into the vertex sequence of sub-area 1.
The 2 nd vertex is A14, the preceding vertex is A13, the following vertex is A15, and the two vertices are respectively located at the left and right sides of A14 (corresponding to the first type), so that the vertex is only added into the vertex sequence of the subregion 1, and the subregion partition or merging operation is not needed.
The 3 rd vertex is A1, the preceding vertex is A15, the following vertex is A2, and the two vertices are respectively located at the left and right sides of A14 (corresponding to the first type), so that the point only needs to be added into the vertex sequence of the subregion 1, and the subregion segmentation or combination operation is not needed.
The 4 th vertex is B1, the preceding vertex is B6, the following vertex is B2, and both B6 and B2 are located on the right side of B1 (corresponding to the second type), further, as described in step 103-4, the left side of B1 is in the working area, therefore, it is necessary to close sub-area 1 and open two sub-areas, one above the other and one below the other, so that the upper sub-area is 2 (corresponding to number 2 in the adjacency graph) and the lower sub-area is 3 (corresponding to number 3 in the adjacency graph). By this, the sub-region 1 is divided completely, and its boundary vertex is a15A1W 2a14, as shown in fig. 3, and the corresponding adjacency graph is shown in fig. 4.
The 5 th vertex is B6, its preceding vertex is B5 and its following vertex is B1. At this time, the Y coordinates of the B6 point and the B5 point are the same (corresponding to the fourth type), and further, the preamble vertex of the B6 point is updated to B4 as described in step 103-6. In this case, since the vertex following the point B6 is B1 and the preceding vertex is B4 are located on both sides of the point B6, it is not necessary to perform the region segmentation operation, and it is only necessary to add vertex information to the sub-region vertex list.
The 9 th vertex B3, the preceding vertex is B2 and the following vertex is B4. At this point, the B3 vertex is Y-coordinate identical to the B4 vertex (corresponding to the fifth type), and further, as described in steps 103-7, the subsequent vertex of the B3 vertex is updated to B5. At this time, the preceding vertex of B3 is B2, the following vertex is B5, both are located on the left side of B3, and the right side of the B3 vertex is within the working area, thus closing the current 2 sub-areas (sub-area 2 and sub-area 3) while opening a new sub-area 4 on the right side. By this, the division of the sub-regions 2 and 3 is completed. The border sequence of the subregion 2 is W1W3B 2B1, the border sequence of the subregion 3 is W2B1B6B5B4W4a13, as shown in fig. 5, and the corresponding adjacency graph is shown in fig. 6.
The vertex scanning from left to right is continued until all the vertices are scanned, and the segmentation of the land parcel can be completed, and the final segmentation result is shown in fig. 7 and its corresponding adjacency graph 8.
In addition, fig. 2 shows the situation where only one obstacle is distributed along the x-axis in the parcel, while fig. 9 shows the situation where more than one obstacle is distributed along the x-axis, which is similar to the above-mentioned processing method, and is characterized in that the leading vertex and the following vertex of D1 are both located on the right side of D1 (corresponding to the second type), further, as described in step 103-4, the left side of D1 is within the working area, therefore, it is necessary to close sub-area 1, and open two sub-areas, one above and one below (area 2 and area 3), so that the upper sub-area is 2 (corresponding to number 2 in the adjacent map), the lower sub-area is 3 (corresponding to number 3 in the adjacent map), further, the sub-area is 3 is divided, and the leading vertex and the following vertex of E1 are both located on the right side of E1 (corresponding to the second type), further as described in step 103-4, the left side of E1 is in the working area, therefore, it is necessary to close sub-area 1 and open two sub-areas one above the other (area 3 and area 4), making the upper sub-area 3 (corresponding to number 3 in the adjacency graph) and the lower sub-area 4 (corresponding to number 4 in the adjacency graph).
The embodiment of the invention provides a polygonal plot partitioning method, which comprises the steps of obtaining a set unmanned aerial vehicle spraying course, a spraying width, a plot boundary vertex and a longitude and latitude coordinate of an obstacle boundary vertex, converting the longitude and latitude coordinate into a plane coordinate, and rotating the plane coordinate to enable the spraying course to be the same as the positive direction of an x axis of a plane coordinate system; sorting the plot boundary vertexes and the barrier boundary vertexes according to the scanning direction; scanning the sorted plot boundary vertexes and the barrier boundary vertexes to divide the operation plot into sub-regions and generate a sub-region adjacency graph; and carrying out reverse rotation on the plane coordinate according to the spraying course of the unmanned aerial vehicle so as to acquire and store the boundary information of the partitioned sub-regions. The invention can divide any polygonal plot containing any polygonal barrier into a plurality of simple polygonal plots, so that the covering and spraying operation of each divided plot can be realized by utilizing the existing planning method, and then the spraying operation of any polygonal plot can be realized.
Example two
Before the step 102 of the first embodiment, the second embodiment of the present invention may further include a step of preprocessing, where the step of preprocessing includes at least one of the following:
1. judging whether the plot boundaries are intersected or not, and indicating a user to input longitude and latitude coordinates of the vertexes of the plot boundaries again when the plot boundaries are intersected;
2. retracting the top point of the boundary of the land parcel by a preset distance, and extending the top point of the boundary of the obstacle by the preset distance;
the retraction of the top point of the plot boundary can prevent the unmanned aerial vehicle from flying out of the boundary due to sampling point errors or control errors, so that danger is avoided; the outward expansion of the boundary vertex of the obstacle can prevent the airplane from flying into the obstacle due to the error of a sampling point or the error of control, and the danger is prevented.
3. Judging whether the obstacles are intersected or not according to the obstacle boundary formed by the top points of the obstacle boundaries, selecting the top points of the outer boundaries of the intersected obstacles when the intersected obstacles exist, generating a new obstacle boundary, and deleting the intersected original obstacles;
4. judging whether the barrier is intersected with the plot boundary according to the barrier boundary formed by the barrier boundary vertex and the plot boundary formed by the plot boundary vertex, converting the barrier boundary of the intersection part in the plot boundary into a new plot boundary when the barrier is intersected with the plot boundary, and deleting the intersected original barrier;
5. and judging whether the operation land is connected or not, and when the operation land is not connected, indicating the user to input the land and obstacle information again. For the situation of non-communication, the non-communication operation land block can be divided into a plurality of communication operation land blocks, and then the divided communication operation land blocks are divided by adopting the polygonal land block division method of the embodiment of the invention.
EXAMPLE III
An embodiment of the present invention provides a polygonal parcel partitioning apparatus, as shown in fig. 10, including:
the acquisition module 810 is configured to acquire a set initial spraying course, a spraying width, a plot boundary vertex and a position of an obstacle boundary vertex of the unmanned aerial vehicle, convert the longitude and latitude coordinates into plane coordinates, and determine x-axis and y-axis directions according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point, where the initial spraying course is a positive x-axis direction;
a sorting module 820, configured to sort the block boundary vertices and the obstacle boundary vertices according to the block segmentation scanning direction;
a dividing and scanning module 830, configured to perform block dividing and scanning on the sorted block boundary vertices and barrier boundary vertices, so as to divide the operation block into a plurality of sub-regions, and generate a sub-region adjacency graph, where the operation block is a region of the block region without the barrier;
the storage module 840 is configured to perform reverse rotation on the plane coordinate according to the unmanned aerial vehicle spraying course to acquire and store the boundary information of the partitioned sub-regions, where the boundary information of the sub-regions is a coordinate set of boundary vertices of the sub-regions.
Wherein the apparatus may further comprise:
the first preprocessing module 851 is used for judging whether the block boundaries are intersected or not, and instructing a user to input longitude and latitude coordinates of the vertexes of the block boundaries again when the block boundaries are intersected;
a second preprocessing module 852, configured to retract the boundary vertex of the parcel by a preset distance, and extend the boundary vertex of the obstacle by a preset distance;
a third preprocessing module 853, configured to determine whether the obstacles intersect with each other according to an obstacle boundary formed by the vertices of the obstacle boundary, select the vertices of the outer boundary of the intersecting obstacles when the intersecting obstacles exist, generate a new obstacle boundary, and delete the intersecting original obstacles;
the fourth preprocessing module 854, configured to determine whether the obstacle intersects the parcel boundary according to the obstacle boundary formed by the obstacle boundary vertex and the parcel boundary formed by the parcel boundary vertex, convert the obstacle boundary of the intersection portion in the parcel boundary into a new parcel boundary when the obstacle intersects the parcel boundary, and delete the original obstacle that has intersected;
a fifth preprocessing module 855, configured to determine whether the operation parcel is connected, and when not connected, instruct the user to re-input parcel and obstacle information or divide the operation parcel into a plurality of connected operation parcels, and perform polygonal parcel division on the connected operation parcel.
The segmentation scan module 830 includes:
a scan determination unit 831, configured to determine whether the current vertex has been marked as scanned;
a vertex classifying unit 832, configured to, when the current vertex is not marked as scanned, obtain a preamble vertex and a subsequent vertex adjacent to the current vertex, and determine vertex types of the current vertex according to plane coordinates of the preamble vertex and the subsequent vertex, where the vertex types include a first type, a second type, a third type, a fourth type, and a fifth type, the first type indicates that the preamble vertex and the subsequent vertex are located on the left and right sides of the current vertex, the second type indicates that the preamble vertex and the subsequent vertex are located on the right side of the current vertex, the third type indicates that the preamble vertex and the subsequent vertex are located on the left side of the current vertex, the fourth type indicates that the preamble vertex is the same as a y-axis coordinate of the current vertex, and the fifth type indicates that the subsequent vertex is the same as the y-axis coordinate of the current vertex;
a first segmentation unit 833, configured to add the current vertex to the vertex sequence of the sub-region when the type of the current vertex is the first type;
a second dividing unit 834, configured to, when the type of the current vertex is a second type, determine whether the left side of the current vertex is outside the operation block, and when the left side of the current vertex is outside the operation block, open a new sub-region on the right side, and add the current vertex into a vertex sequence of the new sub-region; when the left side of the current vertex is in the operation block, closing the sub-area on the left side of the current vertex, opening an upper sub-area and a lower sub-area on the right side, and updating the vertex sequence of the sub-areas;
a third segmentation unit 835, configured to, when the type of the current vertex is a third type, determine whether the right side of the current vertex is outside the operation block, and when the right side of the current vertex is outside the operation block, close the sub-region, and update the vertex sequence of the sub-region; when the right side of the current vertex is in the operation block, closing the upper and lower subregions of the current vertex, opening a new subregion on the right side, and updating the vertex sequence of the subregions;
a fourth segmentation unit 836, configured to, when the type of the current vertex is a fourth type, mark the preamble vertex of the current vertex as a scanned vertex, use the preamble vertex of the preamble vertex as the preamble vertex of the current vertex, and update the vertex sequence of the sub-region;
and a fifth dividing unit 837, configured to mark a subsequent vertex of the current vertex as a scanned vertex when the type of the current vertex is a fifth type, and update the vertex sequence of the sub-region by using the subsequent vertex of the subsequent vertex as the subsequent vertex of the current vertex.
The sorting module 820 includes:
a Y-axis sorting unit 821 for sorting the vertices of the parcel boundaries and the vertices of the obstacle boundaries from small to large according to Y-axis coordinates;
and the X-axis sorting unit 822 is used for sorting the X-axis coordinates from large to small when the y-axis coordinates are the same.
It should be noted that other corresponding descriptions of the functional units related to the polygonal block segmentation apparatus provided in this embodiment may refer to the corresponding description in fig. 1, and are not repeated herein.
Based on the method shown in fig. 1, correspondingly, the present embodiment further provides a non-volatile readable storage medium, on which computer readable instructions are stored, and the readable instructions, when executed by a processor, implement the polygonal block segmentation method shown in fig. 1.
Based on such understanding, the technical solution of the present application may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.), and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the implementation scenarios of the present application.
In order to achieve the above object, based on the above method shown in fig. 1 and the virtual device embodiment shown in fig. 10, an electronic device is further provided in this embodiment, as shown in fig. 11, and includes a bus 41, a communication interface 42, a non-volatile readable storage medium 43, and a processor 44; a non-volatile readable storage medium 43 for storing a computer program 45; a processor 44 for executing a computer program 45 to implement the above-described polygonal block segmentation method as shown in fig. 1; the communication interface 42 is used for realizing communication between the electronic device and an external device; bus 41 is used to couple communication interface 42, non-volatile readable storage medium 43, and processor 44.
Optionally, the electronic device may further include a user interface, a network interface, a camera, Radio Frequency (RF) circuitry, a sensor, audio circuitry, a WI-FI module, and so on. The user interface may include a Display screen (Display), an input unit such as a keypad (Keyboard), etc., and the optional user interface may also include a USB interface, a card reader interface, etc. The network interface may optionally include a standard wired interface, a wireless interface (e.g., WI-FI interface), etc.
It will be understood by those skilled in the art that the electronic device structure provided in the present embodiment does not constitute a limitation of the physical device, and may include more or less components, or combine some components, or arrange different components.
The nonvolatile storage medium can also comprise an operating system and a network communication module. The operating system is a program that manages the hardware and software resources of the electronic device described above, and supports the operation of the information processing program and other software and/or programs. The network communication module is used for realizing communication among components in the nonvolatile storage medium and communication with other hardware and software in the information processing entity device.
Through the above description of the embodiments, those skilled in the art will clearly understand that the present invention may be implemented by software plus a necessary hardware platform, and certainly may be implemented by hardware, but in many cases, the former is a better embodiment. With this understanding in mind, all or part of the technical solutions of the present invention that contribute to the background can be embodied in the form of a software product, which can be stored in a storage medium, such as a ROM/RAM, a magnetic disk, an optical disk, etc., and includes instructions for causing a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods according to the embodiments or some parts of the embodiments of the present invention.
The present invention has been described in detail, and the principle and embodiments of the present invention are explained herein by using specific examples, which are only used to help understand the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (8)

1. A polygonal plot partitioning method for unmanned aerial vehicles is characterized by comprising the following steps:
acquiring a set initial spraying course, a spraying width, a plot boundary vertex and a position of an obstacle boundary vertex of the unmanned aerial vehicle, converting longitude and latitude coordinates into plane coordinates, and determining x-axis and y-axis directions according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point, wherein the initial spraying course is the positive direction of the x-axis; sorting the plot boundary vertexes and the barrier boundary vertexes according to the plot segmentation scanning direction;
performing block segmentation scanning on the sorted block boundary vertexes and the sorted obstacle boundary vertexes to segment the operation block into a plurality of sub-regions and generate a sub-region adjacency graph, wherein the operation block is a region without the obstacle in the block region;
according to the spraying course of the unmanned aerial vehicle, carrying out reverse rotation on the plane coordinates to acquire and store the boundary information of the partitioned sub-regions, wherein the boundary information of the sub-regions is a coordinate set of boundary vertexes of the sub-regions;
wherein, the step of performing the block segmentation scanning on the sorted block boundary vertexes and the barrier boundary vertexes to segment the operation block into a plurality of sub-regions and generate a sub-region adjacency graph comprises the following steps: judging whether the current vertex is marked as scanned or not;
when the current vertex is not marked as scanned, acquiring a preamble vertex and a subsequent vertex adjacent to the current vertex, and judging the vertex type of the current vertex according to the plane coordinates of the preamble vertex and the subsequent vertex, wherein the vertex type comprises a first type, a second type, a third type, a fourth type and a fifth type, the first type refers to that the preamble vertex and the subsequent vertex are respectively positioned at the left side and the right side of the current vertex, the second type refers to that the preamble vertex and the subsequent vertex are both positioned at the right side of the current vertex, the third type refers to that the preamble vertex and the subsequent vertex are both positioned at the left side of the current vertex, the fourth type refers to that the preamble vertex is the same as the y-axis coordinate of the current vertex, and the fifth type refers to that the subsequent vertex is the same as the y-axis coordinate of the current vertex;
when the type of the current vertex is a fourth type, marking the preorder vertex of the current vertex as a scanned vertex, taking the preorder vertex of the preorder vertex as the preorder vertex of the current vertex, and updating the vertex sequence of the sub-region;
and when the type of the current vertex is the fifth type, marking the subsequent vertex of the current vertex as a scanned vertex, taking the subsequent vertex of the subsequent vertex as the subsequent vertex of the current vertex, and updating the vertex sequence of the sub-region.
2. The method of claim 1, wherein the step of sorting the plot boundary vertices and the obstacle boundary vertices according to the plot partition scan direction is preceded by at least one of:
judging whether the plot boundaries are intersected or not, and indicating a user to input longitude and latitude coordinates of the vertexes of the plot boundaries again when the plot boundaries are intersected; retracting the top point of the boundary of the land parcel by a preset distance, and extending the top point of the boundary of the obstacle by the preset distance;
judging whether the obstacles are intersected or not according to the obstacle boundary formed by the top points of the obstacle boundaries, selecting the top points of the outer boundaries of the intersected obstacles when the intersected obstacles exist, generating a new obstacle boundary, and deleting the intersected original obstacles;
judging whether the barrier is intersected with the plot boundary according to the barrier boundary formed by the barrier boundary vertex and the plot boundary formed by the plot boundary vertex, converting the barrier boundary of the intersection part in the plot boundary into a new plot boundary when the barrier is intersected with the plot boundary, and deleting the intersected original barrier;
and judging whether the operation land parcels are connected or not, and when the operation land parcels are not connected, instructing a user to input the information of the land parcels and the obstacles again or dividing the operation land parcels into a plurality of connected operation land parcels, and carrying out polygonal land parcel division on the connected operation land parcels.
3. The method of claim 1, wherein the step of ordering the parcel boundary vertices and the obstacle boundary vertices according to the parcel division scan direction comprises: and sorting the vertex of the land parcel boundary and the vertex of the obstacle boundary from small to large according to the y-axis coordinate, and sorting from large to small according to the x-axis coordinate when the y-axis coordinate is the same.
4. The utility model provides a polygon landmass segmenting device for unmanned aerial vehicle, its characterized in that includes:
the acquisition module is used for acquiring the set initial spraying course, the spraying width, the plot boundary vertex and the position of the barrier boundary vertex of the unmanned aerial vehicle, converting longitude and latitude coordinates into plane coordinates, and determining the directions of an x axis and a y axis according to the initial spraying course, the position of the plot boundary point and the position of an initial spraying point, wherein the initial spraying course is the positive direction of the x axis;
the sorting module is used for sorting the plot boundary vertexes and the barrier boundary vertexes according to the plot segmentation scanning direction;
the segmentation scanning module is used for performing segmentation scanning on the sorted plot boundary vertexes and the sorted barrier boundary vertexes so as to segment the operation plot into a plurality of subregions and generate a subregion adjacency graph, wherein the operation plot is a region without the barrier in the plot region;
the storage module is used for reversely rotating the plane coordinates according to the spraying course of the unmanned aerial vehicle so as to acquire and store the boundary information of the divided sub-regions, wherein the boundary information of the sub-regions is a coordinate set of boundary vertexes of the sub-regions;
wherein the segmentation scan module comprises: a scanning judgment unit for judging whether the current vertex is marked as scanned;
the vertex classification unit is used for acquiring a preamble vertex and a subsequent vertex which are adjacent to the current vertex when the current vertex is not marked as scanned, and judging the vertex type of the current vertex according to the plane coordinates of the preamble vertex and the subsequent vertex, wherein the vertex type comprises a first type, a second type, a third type, a fourth type and a fifth type, the first type refers to that the preamble vertex and the subsequent vertex are respectively positioned at the left side and the right side of the current vertex, the second type refers to that the preamble vertex and the subsequent vertex are positioned at the right side of the current vertex, the third type refers to that the preamble vertex and the subsequent vertex are positioned at the left side of the current vertex, the fourth type refers to that the y-axis coordinates of the preamble vertex and the current vertex are the same, and the fifth type refers to that the y-axis coordinates of the subsequent vertex and the current vertex are the same;
the fourth segmentation unit is used for marking the preorder vertex of the current vertex as a scanned vertex when the type of the current vertex is a fourth type, taking the preorder vertex of the preorder vertex as the preorder vertex of the current vertex, and updating the vertex sequence of the sub-region;
and the fifth segmentation unit is used for marking the subsequent vertex of the current vertex as a scanned vertex when the type of the current vertex is a fifth type, taking the subsequent vertex of the subsequent vertex as the subsequent vertex of the current vertex, and updating the vertex sequence of the sub-region.
5. The polygonal block segmentation apparatus according to claim 4, further comprising: the first preprocessing module is used for judging whether the plot boundaries are intersected or not, and indicating a user to input longitude and latitude coordinates of the vertexes of the plot boundaries again when the plot boundaries are intersected;
the second preprocessing module is used for shrinking the boundary vertex of the land parcel by a preset distance and expanding the boundary vertex of the obstacle by the preset distance;
the third preprocessing module is used for judging whether the obstacles are intersected or not according to the obstacle boundary formed by the top points of the obstacle boundaries, selecting the top points of the outer boundaries of the intersected obstacles when the intersected obstacles exist, generating a new obstacle boundary and deleting the intersected original obstacles;
the fourth preprocessing module is used for judging whether the barrier is intersected with the plot boundary according to the barrier boundary formed by the barrier boundary vertex and the plot boundary formed by the plot boundary vertex, converting the barrier boundary of the intersection part in the plot boundary into a new plot boundary when the barrier is intersected with the plot boundary, and deleting the intersected original barrier;
and the fifth preprocessing module is used for judging whether the operation land parcels are communicated or not, and when the operation land parcels are not communicated, instructing a user to input the information of the land parcels and the obstacles again or dividing the operation land parcels into a plurality of communicated operation land parcels and carrying out polygonal land parcel division on the communicated operation land parcels.
6. The polygonal block partitioning device according to claim 4, wherein said sorting module comprises:
the Y-axis sorting unit is used for sorting the vertex of the parcel boundary and the vertex of the barrier boundary according to the Y-axis coordinate from small to large;
and the X-axis sorting unit is used for sorting according to the X coordinate from large to small when the y-axis coordinates are the same.
7. A non-transitory readable storage medium having stored thereon a computer program which, when executed by a computer, implements the polygon block segmentation method of any one of claims 1 to 3.
8. An electronic device comprising a non-volatile readable storage medium, a processor, and a computer program stored on the non-volatile readable storage medium and executable on the processor, the processor implementing the polygon map segmentation method of any one of claims 1 to 3 when executing the program.
CN201910081517.0A 2019-01-28 2019-01-28 Polygonal land parcel segmentation method and device, storage medium and electronic equipment Active CN109934384B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910081517.0A CN109934384B (en) 2019-01-28 2019-01-28 Polygonal land parcel segmentation method and device, storage medium and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910081517.0A CN109934384B (en) 2019-01-28 2019-01-28 Polygonal land parcel segmentation method and device, storage medium and electronic equipment

Publications (2)

Publication Number Publication Date
CN109934384A CN109934384A (en) 2019-06-25
CN109934384B true CN109934384B (en) 2021-05-18

Family

ID=66985248

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910081517.0A Active CN109934384B (en) 2019-01-28 2019-01-28 Polygonal land parcel segmentation method and device, storage medium and electronic equipment

Country Status (1)

Country Link
CN (1) CN109934384B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110502021B (en) * 2019-09-24 2022-07-15 一米信息服务(北京)有限公司 Agricultural machinery operation path planning method and system
CN111753388B (en) * 2019-12-30 2021-06-15 广州极飞科技股份有限公司 Spraying control method, spraying control device, electronic equipment and computer-readable storage medium
CN111221934B (en) * 2020-02-05 2023-08-18 沈阳无距科技有限公司 Unmanned aerial vehicle operation boundary determination method and device
CN111427375B (en) * 2020-03-09 2024-01-09 深圳块织类脑智能科技有限公司 Micro-area intelligent division method and system for unmanned aerial vehicle inspection tour
CN112233131B (en) * 2020-10-22 2022-11-08 广州极飞科技股份有限公司 Method, device and equipment for dividing land block and storage medium
CN113693494B (en) * 2021-02-10 2023-11-14 北京石头创新科技有限公司 Map drawing method and device, medium and electronic equipment
CN113741539A (en) * 2021-09-26 2021-12-03 北方天途航空技术发展(北京)有限公司 Unmanned aerial vehicle plant protection operation air route planning method

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105447848A (en) * 2015-11-06 2016-03-30 四川鱼鳞图信息技术股份有限公司 Method for segmenting plot planar space data in parallel based on set areas and indicating lines
WO2016154482A1 (en) * 2015-03-25 2016-09-29 360 Yield Center, Llc Agronomic systems, methods and apparatuses
CN106403954A (en) * 2016-09-28 2017-02-15 深圳高科新农技术有限公司 Automatic track generating method for unmanned aerial vehicle
CN106774434A (en) * 2017-01-18 2017-05-31 北京艾森博航空科技股份有限公司 Automatic obstacle avoidance method and system applied to unmanned aerial vehicle plant protection
CN108716919A (en) * 2018-05-25 2018-10-30 南京航空航天大学 Plant protection drone path planning method based on arbitrary polygon clear area
CN108805885A (en) * 2018-06-13 2018-11-13 广州极飞科技有限公司 Plot dividing method and terminal, flight course planning method and mobile device control method

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20170270446A1 (en) * 2015-05-01 2017-09-21 360 Yield Center, Llc Agronomic systems, methods and apparatuses for determining yield limits

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2016154482A1 (en) * 2015-03-25 2016-09-29 360 Yield Center, Llc Agronomic systems, methods and apparatuses
CN105447848A (en) * 2015-11-06 2016-03-30 四川鱼鳞图信息技术股份有限公司 Method for segmenting plot planar space data in parallel based on set areas and indicating lines
CN106403954A (en) * 2016-09-28 2017-02-15 深圳高科新农技术有限公司 Automatic track generating method for unmanned aerial vehicle
CN106774434A (en) * 2017-01-18 2017-05-31 北京艾森博航空科技股份有限公司 Automatic obstacle avoidance method and system applied to unmanned aerial vehicle plant protection
CN108716919A (en) * 2018-05-25 2018-10-30 南京航空航天大学 Plant protection drone path planning method based on arbitrary polygon clear area
CN108805885A (en) * 2018-06-13 2018-11-13 广州极飞科技有限公司 Plot dividing method and terminal, flight course planning method and mobile device control method

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
A novel approach for automated land partitioning using genetic algorithm;Hüseyin HAKLI;《Expert Systems With Applications》;20170615;参见第10-18页 *
一种类矩形引导的玉米田遥感图像分割算法;梁若飞 等;《国土资源遥感》;20160627;第28卷(第3期);参见第53-59页 *
全自动植保无人机含障不规则区域的航迹规划算法;金泽选 等;《江苏农业科学》;20180329;第46卷(第5期);参见第220-223页 *

Also Published As

Publication number Publication date
CN109934384A (en) 2019-06-25

Similar Documents

Publication Publication Date Title
CN109934384B (en) Polygonal land parcel segmentation method and device, storage medium and electronic equipment
US11709058B2 (en) Path planning method and device and mobile device
CN112179330B (en) Pose determination method and device of mobile equipment
US11479359B2 (en) UAV operation route planning method, UAV pesticide spreading method and device
EP3520076B1 (en) Computer vision systems and methods for detecting and modeling features of structures in images
CN108279670B (en) Method, apparatus and computer readable medium for adjusting point cloud data acquisition trajectory
US20190277645A1 (en) Navigation route editing method and apparatus, and control device
CN111750883B (en) Method and device for determining job path, storage medium and electronic equipment
CN111380510B (en) Repositioning method and device and robot
CN104807457A (en) Generation method and device of flight line of aircraft and terminal equipment
CN110221621B (en) Unmanned aerial vehicle, and method, device and storage medium for planning flight area of unmanned aerial vehicle
JP6897076B2 (en) Flight control methods, flight control programs, and flight control devices
US20180357778A1 (en) Image processing device, image processing method, and image processing program
IL255050A (en) Control over an autonomic vehicle
CN110705385B (en) Method, device, equipment and medium for detecting angle of obstacle
CN110456806A (en) A kind of unmanned plane landing method and device
CN112130165A (en) Positioning method, positioning device, positioning medium and unmanned equipment
CN112884900A (en) Landing positioning method and device for unmanned aerial vehicle, storage medium and unmanned aerial vehicle nest
CN113110462A (en) Obstacle information processing method and device and operating equipment
JP4928993B2 (en) Farm district drawing data creation system
CN113096181B (en) Method and device for determining equipment pose, storage medium and electronic device
CN112393735B (en) Positioning method and device, storage medium and electronic device
CN114782928A (en) Parking space detection method and device, electronic equipment and storage medium
CN113671949A (en) Navigation map determination method and device, storage medium and electronic device
CN116443527B (en) Pallet fork method, device, equipment and medium based on laser radar

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant