CN109685751B - Distribution area merging method and device, electronic equipment and storage medium - Google Patents

Distribution area merging method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN109685751B
CN109685751B CN201811609511.8A CN201811609511A CN109685751B CN 109685751 B CN109685751 B CN 109685751B CN 201811609511 A CN201811609511 A CN 201811609511A CN 109685751 B CN109685751 B CN 109685751B
Authority
CN
China
Prior art keywords
vertex
point set
circle
vertexes
alternative
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
CN201811609511.8A
Other languages
Chinese (zh)
Other versions
CN109685751A (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.)
Rajax Network Technology Co Ltd
Original Assignee
Rajax Network 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 Rajax Network Technology Co Ltd filed Critical Rajax Network Technology Co Ltd
Priority to CN201811609511.8A priority Critical patent/CN109685751B/en
Publication of CN109685751A publication Critical patent/CN109685751A/en
Application granted granted Critical
Publication of CN109685751B publication Critical patent/CN109685751B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T5/00Image enhancement or restoration
    • G06T5/50Image enhancement or restoration by the use of more than one image, e.g. averaging, subtraction
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/08Logistics, e.g. warehousing, loading or distribution; Inventory or stock management
    • G06Q10/083Shipping
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T11/002D [Two Dimensional] image generation
    • G06T11/20Drawing from basic elements, e.g. lines or circles
    • G06T11/206Drawing of charts or graphs

Landscapes

  • Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Business, Economics & Management (AREA)
  • Physics & Mathematics (AREA)
  • Economics (AREA)
  • Human Resources & Organizations (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Development Economics (AREA)
  • Marketing (AREA)
  • Operations Research (AREA)
  • Quality & Reliability (AREA)
  • Strategic Management (AREA)
  • Tourism & Hospitality (AREA)
  • General Business, Economics & Management (AREA)
  • Image Generation (AREA)

Abstract

The embodiment of the invention relates to the technical field of Internet and discloses a method and a device for merging distribution areas, electronic equipment and a storage medium. Selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering the searching step; the searching step comprises the steps of making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; the alternative point set comprises a next vertex of the circle center and a vertex in the searched circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to be coincident with the initial point, taking the selected vertex as a circle center, and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertexes selected as the circle centers to form a region formed by combining a plurality of polygonal distribution regions. By adopting the embodiment of the invention, the area formed by combining the plurality of polygonal distribution areas can be more accurately determined.

Description

Distribution area merging method and device, electronic equipment and storage medium
Technical Field
The embodiment of the invention relates to the technical field of internet, in particular to a merging method and device of distribution areas, electronic equipment and a storage medium.
Background
With the rapid development of internet technology, more and more people choose to use a new shopping mode of online shopping, and therefore, a large amount of logistics distribution needs are generated. The jurisdiction range of each delivery site is generally an irregular polygon, a plurality of delivery sites can form delivery camp, a plurality of camp can form delivery battle groups, the area administered by background management personnel can be delivery camp, delivery battle groups and the like, at the moment, the plurality of delivery sites need to be merged and managed, namely, the plurality of polygons are merged into a large polygon, so that the background management personnel can acquire data information in the jurisdiction range.
However, the inventors found that at least the following problems exist in the related art: when a plurality of polygons are merged, if there is a concave polygon, a region not belonging to the concave polygon is included in the range of the merged polygon, and the range of the merged polygon is inaccurate.
Disclosure of Invention
An object of embodiments of the present invention is to provide a distribution area merging method, a distribution area merging device, an electronic apparatus, and a storage medium, which can more accurately determine an area where a plurality of polygonal distribution areas are merged.
The plurality of polygons are merged, that is, vertices of outermost layers of the plurality of polygons are connected to form a convex polygon, and when a concave polygon exists, points at the outermost periphery of the concave polygon are connected to determine the boundary of the merged polygon, so that a region not within the range of the concave polygon is included in the range of the merged polygon, and the range of the merged polygon is inaccurate.
In order to solve the above technical problem, an embodiment of the present invention provides a method for merging distribution areas, including: acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes according to a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes; selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering the searching step; the searching step comprises the steps of making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; the alternative point set comprises a next vertex of the circle center and a vertex in the searched circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to be coincident with the initial point, taking the selected vertex as a circle center, and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertexes selected as the circle centers to form a region formed by combining a plurality of polygonal distribution regions.
The embodiment of the present invention further provides a merging device for distribution areas, including: the sorting module is used for acquiring a plurality of vertexes of the polygonal distribution areas and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes; the selection module is used for selecting the next vertex of the starting point as the circle center; the searching module is used for executing the searching step, and the searching step comprises the steps of making a circle according to the circle center and the preset radius, searching the top point in the circle, and setting an alternative point set; the alternative point set comprises a next vertex of the circle center and a vertex in the searched circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to be coincident with the initial point, taking the selected vertex as a circle center, and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertexes selected as the circle centers to form a region formed by combining a plurality of polygonal distribution regions.
Embodiments of the present invention further provide an electronic device, including a memory and a processor, where the memory stores a computer program, and the processor executes the program to perform: acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes according to a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes; selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering the searching step; the searching step comprises the steps of making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; the alternative point set comprises a next vertex of the circle center and a vertex in the searched circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to be coincident with the initial point, taking the selected vertex as a circle center, and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertexes selected as the circle centers to form a region formed by combining a plurality of polygonal distribution regions.
Compared with the prior art, the method and the device have the advantages that multiple vertexes of multiple polygon distribution areas are obtained, and the multiple vertexes are arranged in the preset direction by taking the vertex through which the outer tangent of the set of the polygon distribution areas passes in the multiple vertexes as a starting point; selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering a searching step, wherein the searching step comprises the following steps: making a circle according to the circle center and a preset radius, searching vertexes in the circle, setting a candidate point set, wherein the candidate point set comprises a next vertex of the circle center and a vertex in the searched circle, selecting one vertex from the vertexes in the candidate point set, repeating the searching step by taking the selected vertex as the circle center when the selected vertex is not coincident with the initial point until the selected vertex in the candidate point set is coincident with the initial point, and sequentially connecting the initial point and all the vertexes selected as the circle center to form a region after a plurality of polygonal distribution regions are combined; if the merged area has a concave side, the boundary of the merged area of the plurality of polygonal distribution areas can be accurately drawn along the concave side, so that the merged area of the plurality of polygonal distribution areas can be more accurately determined.
In addition, acquiring a plurality of vertexes of the plurality of polygon distribution areas, and arranging the plurality of vertexes in a preset direction by taking a target bump in the plurality of vertexes as a starting point specifically comprises: for a plurality of vertexes of each polygonal distribution area, taking any one of the vertexes of the polygonal distribution area as an initial point, and arranging the vertexes of the polygonal distribution area according to a preset direction; and sequentially connecting a plurality of vertexes of the arranged polygonal distribution areas end to obtain a large polygonal distribution area, and arranging the vertexes of the large polygonal distribution area in a preset direction by taking the target salient points in the large polygonal distribution area as starting points. The embodiment provides a specific implementation manner for acquiring a plurality of vertexes of a plurality of polygon distribution areas and arranging the plurality of vertexes in a preset direction by taking a target bump in the plurality of vertexes as a starting point, so that when the plurality of polygon distribution areas are combined, the initial point of the polygon distribution area can be prevented from being connected to the last vertex of an adjacent polygon distribution area.
In addition, in the case where any one of the plurality of vertices of the polygon delivery area is used as an initial point, any one of the vertices is a vertex through which a circumscribed line of the polygon delivery area passes. In the present embodiment, the vertex through which the outer tangent of the polygon delivery area passes is selected as the initial point so that the initial point is the outermost vertex of the plurality of polygon delivery areas and is all on the merged polygon delivery area.
In addition, selecting one vertex from the vertices in the candidate point set specifically includes: calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the previous vertex of the circle center and the coordinate of each vertex in the alternative point set; and selecting one vertex from the vertexes in the alternative point set according to the evaluation value of each vertex in the alternative point set. The embodiment provides a specific implementation mode for selecting one vertex from all the vertices in the alternative point set.
In addition, according to the coordinates of the center of the circle, the coordinates of the vertex above the center of the circle, and the coordinates of each vertex in the alternative point set, the evaluation value of each vertex in the alternative point set is calculated, which specifically comprises: for each vertex in the alternative point set, a vector P is calculatedxPYAnd vector PYPZAs an evaluation value of the vertex, where PxCoordinates of the last vertex of the circle center, PYCoordinates representing the center of a circle, PZCoordinates representing each vertex in the alternate point set. The present embodiment provides a specific implementation manner of calculating the evaluation value of each vertex in the alternative point set according to the coordinates of the center of the circle and the coordinates of the previous vertex of the center of the circle, and the coordinates of each vertex in the alternative point set.
In addition, selecting one vertex from the vertices in the candidate point set according to the evaluation value of each vertex in the candidate point set specifically includes: determining whether the vector P exists in each vertex in the alternative point set or not according to the evaluation value of each vertex in the alternative point setxPYThe vertex on the right side; if the vector P exists in each vertex in the alternative point setxPYVertex on the right, from the point located on vector PxPYSelecting a vertex with the largest evaluation value from the vertices on the right side; if the vector P does not exist in each vertex in the alternative point setxPYAnd selecting the vertex with the smallest evaluation value from all the vertices in the candidate point set by the vertex on the right side. The present embodiment provides a specific implementation manner of selecting one vertex from vertices in the candidate point set according to the evaluation value of each vertex in the candidate point set.
In addition, it is determined whether or not there is any vertex in the alternative point set located in the vector P based on the evaluation value of each vertex in the alternative point setxPYThe right vertex specifically includes: determining alternativesWhether the evaluation value of each vertex in the point set has at least one vertex is a positive value; if the evaluation value of each vertex in the alternative point set has at least one vertex evaluation value being a positive value, determining that at least one vertex is located in the vector PxPYRight side of (c); if the evaluation value of each vertex in the alternative point set does not have the evaluation value of at least one vertex as a positive value, judging that all the vertices in the alternative point set are not positioned in the vector PxPYTo the right of (a). The embodiment provides a method for determining whether the vector P exists in each vertex in the alternative point set or not according to the evaluation value of each vertex in the alternative point set0P1The vertex on the right.
In addition, the preset direction is a counterclockwise direction.
Drawings
One or more embodiments are illustrated by the corresponding figures in the drawings, which are not meant to be limiting.
Fig. 1 is a flowchart of a merging method of delivery areas according to a first embodiment of the present invention;
FIG. 2 is a schematic illustration of a merger of 3 delivery zones according to a first embodiment of the present invention;
FIG. 3 is a flow chart of a merging method of delivery areas according to a second embodiment of the present invention;
fig. 4 is a structural diagram of a merging method of distribution areas according to a third embodiment of the present invention;
FIG. 5 is a structural view of an information presentation apparatus according to a fourth embodiment of the present invention;
fig. 6 is a block diagram of an electronic apparatus according to a fifth embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention more apparent, embodiments of the present invention will be described in detail below with reference to the accompanying drawings. However, it will be appreciated by those of ordinary skill in the art that numerous technical details are set forth in order to provide a better understanding of the present application in various embodiments of the present invention. However, the technical solution claimed in the present application can be implemented without these technical details and various changes and modifications based on the following embodiments. The following embodiments are divided for convenience of description, and should not constitute any limitation to the specific implementation manner of the present invention, and the embodiments may be mutually incorporated and referred to without contradiction.
A first embodiment of the present invention relates to a method for merging a plurality of polygonal distribution areas, which may be polygonal distribution areas of a station, a battle, or a battle group, and which may be a region at a higher level by merging the plurality of polygonal distribution areas, for example, a polygonal distribution area of a battle may be obtained by merging polygonal distribution areas of a plurality of stations.
Fig. 1 shows a specific flow of the delivery area merging method according to the present embodiment. The flow of fig. 1 is described in detail below:
step 101, obtaining a plurality of vertexes of a plurality of polygon distribution areas, and arranging the vertexes according to a preset direction by taking a target salient point of the vertexes as a starting point.
Specifically, as shown in fig. 2, the explanation is given by taking 3 polygon distribution areas A, B, C as an example, and 9 vertices P of 3 polygon distribution areas A, B, C are acquired0、P1、P2、P3、P5、P6、P7、P8、 P9The set of the polygonal distribution areas refers to a plurality of polygonal distribution areas as a whole, the vertex through which the circumscribed line of the set of the polygonal distribution areas passes is selected as a target bump, the circumscribed line passing through the target bump cannot pass through any polygonal distribution area, and therefore the selected target bump has P0、P6、P9、P3Then, any target bump in the 4 target bumps is taken as a starting point, and the target bump P at the lower left corner is taken as the starting point in the embodiment0Arranging the 9 vertexes as a starting point in a preset direction, wherein the preset direction can be clockwise or anticlockwise, and the arranged 9 vertexes are arranged in an anticlockwise way for exampleIs P0、P1、P8、 P5、P6、P7、P9、P2、P3. The longitude and latitude of each vertex can be used as the coordinates of the vertex.
And 102, selecting the next vertex of the starting point as a circle center according to the arrangement sequence, and entering a searching step.
Specifically, the starting point is P0Is P as the next vertex1With P1As a center, go to search step 103.
The searching step 103 comprises the following substeps:
and a substep 1031 of making a circle according to the circle center and the preset radius, searching a vertex in the circle, and setting a candidate point set.
And a substep 1032 of selecting a vertex from the vertices in the candidate point set, and repeating the searching step by using the selected vertex as a circle center when the selected vertex is determined not to coincide with the starting point.
And a substep 1033, when it is determined that the selected vertex coincides with the starting point, sequentially connecting the starting point and all the vertices selected as the circle centers to form a region where the plurality of polygon distribution regions are merged.
Specifically, a result set may be preset, and the starting point P may be set first0And the center P of the circle1Add the result set and then add P1As the center of the circle, making a circle with a preset radius, wherein the circle comprises a vertex P5Centering on the center P1Next vertex P8And the vertex P in the circle5Adding the vertex P into the set candidate point set, and then selecting a vertex from all the vertices in the candidate point set, wherein the candidate point set comprises the vertex P8、P5Selecting a vertex P5And judging whether the selected vertex is coincident with the initial point or not, wherein the vertex P is5And the starting point P0Misaligned, the selected vertex P5Add result set with vertex P5Repeating substep 1031 as a circle center; with the vertex P5A circle with a predetermined radius as the center and a vertex P6、P7、P8Centering on the center P5Next vertex P6And the vertex P in the circle6、P7、P8Adding the vertex P into the set candidate point set, and then selecting a vertex from all the vertices in the candidate point set, wherein the candidate point set comprises the vertex P6、P7、P8Selecting a vertex P6And judging whether the selected vertex is coincident with the initial point or not, wherein the vertex P is6And the starting point P0Misaligned, the selected vertex P6Add result set with vertex P6As the center of circle, the searching step 103 is repeated, the specific process is similar to the above, and is not repeated here until the selected vertex and the starting point P0Coincidence, the resulting result set including the vertex P0、P1、P5、P6、P7、P8、P2、P3Starting point P0And all the vertexes selected as the circle centers are sequentially connected, that is, all the vertexes in the result set are sequentially connected according to the adding sequence, so as to form a region formed by combining 3 polygonal distribution regions A, B, C.
Compared with the prior art, the method and the device have the advantages that multiple vertexes of multiple polygon distribution areas are obtained, and the multiple vertexes are arranged in the preset direction by taking the vertex through which the outer tangent of the set of the polygon distribution areas passes in the multiple vertexes as a starting point; selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering a searching step, wherein the searching step comprises the following steps: making a circle according to the circle center and a preset radius, searching vertexes in the circle, setting a candidate point set, wherein the candidate point set comprises a next vertex of the circle center and a vertex in the searched circle, selecting one vertex from the vertexes in the candidate point set, repeating the searching step by taking the selected vertex as the circle center when the selected vertex is not coincident with the initial point until the selected vertex in the candidate point set is coincident with the initial point, and sequentially connecting the initial point and all the vertexes selected as the circle center to form a region after a plurality of polygonal distribution regions are combined; if the merged area has a concave side, the boundary of the merged area of the plurality of polygonal distribution areas can be accurately drawn along the concave side, so that the merged area of the plurality of polygonal distribution areas can be more accurately determined.
A second embodiment of the present invention relates to a method for merging distribution areas, and the second embodiment is substantially the same as the first embodiment, and is different from the first embodiment in that the second embodiment of the present invention provides a specific implementation in which a plurality of vertices of a plurality of polygonal distribution areas are obtained, and the plurality of vertices are arranged in a predetermined direction with a target bump among the plurality of vertices as a starting point.
Fig. 3 shows a specific flow of the delivery area merging method according to the present embodiment.
The step 202 and the step 203 are substantially the same as the step 102 and the step 103, and are not repeated here, the main difference is that the step 201 includes the following substeps:
in the sub-step 2011, for each of the plurality of vertices of the polygonal distribution area, the plurality of vertices of the polygonal distribution area are arranged in a predetermined direction with any one of the plurality of vertices of the polygonal distribution area as an initial point.
Specifically, referring to fig. 2, taking 3 polygon distribution areas as an example for explanation, for a plurality of vertices of each polygon distribution area, taking any vertex of the plurality of vertices of the polygon distribution area as an initial point, and arranging the plurality of vertices of each polygon distribution area in a preset direction; in the case where any vertex of the multiple vertices of the polygon distribution area is used as the initial point, the vertex through which the circumscribed line of the polygon distribution area passes is selected as the initial point, so that the initial point is the outermost vertex of the multiple polygon distribution areas and is located on the large polygon distribution area obtained after the merging in sub-step 2012. Taking the polygon distribution area A as an example, the polygon distribution area A includes a vertex P0、P1、P2、P3The vertex through which the outer tangent of the polygonal distribution area passes is P0、P3Vertex P0Or vertex P3All can be used as initial point, with point P at lower left corner0Taking the starting point as an example, the 4 vertexes are arranged in a preset direction, which may be a clockwise direction or a counterclockwise direction, for example,the 4 arranged vertexes are P0、P1、P2、P3(ii) a Similarly, the polygon dispensing area B has 5 vertices arranged as P1、P5、P6、P7、P8The 4 vertexes of the polygonal distribution area C are arranged to be P9、P2、P8、P7
And a substep 2012, sequentially connecting the plurality of vertexes of the arranged polygonal distribution areas end to obtain a polygonal distribution area, and arranging the plurality of vertexes of the polygonal distribution area in a preset direction with the target salient point in the polygonal distribution area as a starting point.
Specifically, the arranged 9 vertexes of the 3 polygonal distribution areas are sequentially connected end to obtain a polygonal distribution area, and the vertexes of the polygonal distribution area include P0、P1、P2、P3、P5、P6、P7、 P9The target bump has P0、P6、P9、P3Taking any one of 4 target salient points as a starting point, wherein the target salient point is a vertex through which an outer tangent of a set of polygonal distribution areas passes, namely the target salient point is an outermost point of the polygonal distribution areas, selecting the target salient point as the starting point, so that the starting point is an area formed by combining a plurality of polygonal distribution areas, and then arranging the plurality of vertexes of the polygonal distribution areas in a preset direction by taking the selected target salient point as the starting point; in the present embodiment, the target salient point P at the lower left corner0Arranging the 9 vertexes as a starting point in a preset direction, wherein the preset direction can be clockwise or anticlockwise, and the anticlockwise arrangement is taken as an example, and the 9 vertexes after arrangement are P0、P1、P5、P6、P7、 P8、P2、P3
Compared with the first embodiment, the present embodiment provides a specific implementation manner in which a plurality of vertices of a plurality of polygon distribution areas are obtained, and the plurality of vertices are arranged in a preset direction with a target bump among the plurality of vertices as an initial point, so that when the plurality of polygon distribution areas are combined, the initial point of the polygon distribution area can be prevented from being connected to the last vertex of an adjacent polygon distribution area.
A third embodiment of the present invention relates to a delivery area merging method, and is substantially the same as the first embodiment, and specifically differs therefrom in that the third embodiment of the present invention provides a specific implementation of selecting one vertex from among vertices in a candidate point set.
Fig. 4 shows a specific flow of the delivery area merging method according to the present embodiment.
The steps 302 and 302 are substantially the same as the steps 101 and 102, and are not described herein again, the main difference is that the searching step 303 includes the following sub-steps:
and a substep 3031 of making a circle according to the circle center and the preset radius, searching a vertex in the circle, and setting a candidate point set.
Specifically, as shown in fig. 2, taking 3 polygon distribution areas A, B, C as an example for explanation, a result set may be set in advance, and the starting point P may be set first0And the center P of the circle1Add the result set and then add P1As the center of the circle, making a circle with a preset radius, wherein the circle comprises a vertex P5Centering on the center P1Next vertex P8And the vertex P in the circle5Adding the set alternative point set.
Sub-step 3032 comprises the sub-steps of:
substep 30321, calculating the evaluation value of each vertex in the alternative point set according to the coordinates of the circle center, the coordinates of the previous vertex of the circle center, and the coordinates of each vertex in the alternative point set.
Specifically, the candidate point set includes a vertex P8、P5For each vertex in the set of alternative points, a vector P is calculatedxPYAnd vector PYPZAs an evaluation value of the vertex, where PxCoordinates of the last vertex of the circle center, PYCoordinates representing the center of a circle, PZCoordinates representing each vertex in the set of alternate points; respectively calculating alternative point set top point P8、P5Evaluation value of (1), vertex P8Evaluation value T of8=P0P1XP1P8Vertex P5Evaluation value T of8=P0P1XP1P5
And a substep 30322 of selecting a vertex from the vertices in the candidate point set according to the evaluation value of each vertex in the candidate point set, and repeating the searching step by taking the selected vertex as a circle center when the selected vertex is determined not to coincide with the starting point.
Specifically, it is determined whether or not there is any vertex in the alternative point set located in the vector P based on the evaluation value of each vertex in the alternative point setxPYThe vertex on the right side, specifically, whether or not there is any vertex located in the vector P among the vertices in the alternative point set may be determined by determining whether or not there is at least one vertex whose evaluation value is a positive value among the evaluation values of the vertices in the alternative point setxPYThe vertex on the right side is located in the vector P if the evaluation value of the vertex is positivexPYThe right side; otherwise, the vertex is located in the vector PxPYLeft side; when there are more than one vertex in the alternative point setxPYVertex on the right side, from the point located on vector PxPYSelecting a vertex with the largest evaluation value from the vertices on the right side; when the vector P does not exist in each vertex in the alternative point setxPYVertex on the right side, and there are multiple vertices located in vector PxPYAnd when the vertex on the left side is selected, selecting the vertex with the smallest evaluation value from all the vertices in the alternative point set, judging whether the selected vertex is coincident with the initial point, if the selected vertex is not coincident with the initial point, adding the selected vertex into the result set, taking the selected vertex as the circle center, and repeating the searching step 303, wherein the specific process is similar to that described above and is not repeated herein until the selected vertex is coincident with the initial point.
And a substep 3033, when determining that the selected vertex coincides with the starting point, sequentially connecting the starting point and all the vertices selected as the circle centers to form a region after the plurality of polygon distribution regions are combined.
This embodiment provides a specific implementation of selecting one vertex from among the vertices in the candidate point set, as compared to the first embodiment.
A fourth embodiment of the present invention relates to a distribution area merging device for merging a plurality of polygonal distribution areas, which may be polygonal distribution areas of a station, a battle camp, or a battle group, and which can obtain an area of a higher level by merging the polygonal distribution areas, for example, a polygonal distribution area of a battle camp can be obtained by merging the polygonal distribution areas of the station. Referring to fig. 5, the merging device 500 of the distribution areas includes:
the sorting module 501 is configured to obtain multiple vertices of multiple polygon distribution areas, and arrange the multiple vertices in a preset direction with a target bump in the multiple vertices as a starting point, where the target bump is a vertex through which a circumscribed line of a set of the polygon distribution areas passes; specifically, as shown in fig. 2, the description is given by taking 3 polygon distribution areas A, B, C as an example, and 9 vertices P of 3 polygon distribution areas A, B, C are obtained0、P1、P2、P3、P5、P6、P7、P8、P9The set of the polygonal distribution areas refers to a plurality of polygonal distribution areas as a whole, the vertex through which the circumscribed line of the set of the polygonal distribution areas passes is selected as a target bump, the circumscribed line passing through the target bump cannot pass through any polygonal distribution area, and therefore the selected target bump has P0、P6、P9、P3Then, any target bump in the 4 target bumps is taken as a starting point, and the target bump P at the lower left corner is taken as the starting point in the embodiment0Arranging the 9 vertexes as a starting point in a preset direction, wherein the preset direction can be clockwise or anticlockwise, and the anticlockwise arrangement is taken as an example, and the 9 vertexes after arrangement are P0、P1、P8、P5、P6、P7、P9、P2、P3. The longitude and latitude of each vertex can be used as the coordinates of the vertex.
A selecting module 502, configured to select a next vertex of the starting point as a circle center, where the starting point is P0Is P as the next vertex1 The selecting module 502 selects P1And taking the center of the circle as the center of the circle, and entering a searching step.
A searching module 503, configured to perform a searching step, where the searching step includes making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting a candidate point set; the alternative point set comprises a next vertex of the circle center and a vertex in the searched circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to be coincident with the initial point, taking the selected vertex as a circle center, and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertexes selected as the circle centers to form a region formed by combining a plurality of polygonal distribution regions.
Specifically, the search module 503 presets a result set, and starts the starting point P first0And the center P of the circle1Add the result set and then add P1As the center of the circle, making a circle with a preset radius, wherein the circle comprises a vertex P5Centering on the center P1Next vertex P8And the vertex P in the circle5Adding the vertex P into the set candidate point set, and then selecting a vertex from all the vertices in the candidate point set, wherein the candidate point set comprises the vertex P8、P5Selecting a vertex P5And judging whether the selected vertex is coincident with the initial point or not, wherein the vertex P is5And the starting point P0Misaligned, the selected vertex P5Add result set with vertex P5Repeating substep 1031 as a circle center; with the vertex P5A circle with a predetermined radius as the center and a vertex P6、P7、P8Centering on the center P5Next vertex P6And the vertex P in the circle6、P7、P8Adding the set candidate point set, and then selecting a vertex from all the vertices in the candidate point set, wherein the candidate point setIncluding a vertex P6、P7、P8Selecting a vertex P6And judging whether the selected vertex is coincident with the initial point or not, wherein the vertex P is6And the starting point P0Misaligned, the selected vertex P6Add result set with vertex P6As the center of circle, repeating the searching step, the specific process is similar to the above, and will not be described herein again until the selected vertex and the starting point P0Coincidence, the resulting result set including the vertex P0、P1、P5、P6、P7、P8、P2、P3Starting point P0And all the vertexes selected as the circle centers are sequentially connected, that is, all the vertexes in the result set are sequentially connected according to the adding sequence, so as to form a region formed by combining 3 polygonal distribution regions A, B, C.
It should be noted that this embodiment is a system example corresponding to the first to third embodiments, and may be implemented in cooperation with the first to third embodiments. The related technical details mentioned in the first to third embodiments are still valid in this embodiment, and are not described herein again in order to reduce repetition. Accordingly, the related-art details mentioned in the present embodiment can also be applied to the first to third embodiments.
It should be noted that each module referred to in this embodiment is a logical module, and in practical applications, one logical unit may be one physical unit, may be a part of one physical unit, and may be implemented by a combination of multiple physical units. In addition, in order to highlight the innovative part of the present invention, elements that are not so closely related to solving the technical problems proposed by the present invention are not introduced in the present embodiment, but this does not indicate that other elements are not present in the present embodiment.
Compared with the prior art, the method and the device have the advantages that multiple vertexes of the multiple polygon distribution areas are obtained, and the multiple vertexes are arranged in the preset direction by taking the vertex through which the outer tangent of the set of the polygon distribution areas passes in the multiple vertexes as a starting point; selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering a searching step, wherein the searching step comprises the following steps: making a circle according to the circle center and a preset radius, searching vertexes in the circle, setting a candidate point set, wherein the candidate point set comprises a next vertex of the circle center and a vertex in the searched circle, selecting one vertex from the vertexes in the candidate point set, repeating the searching step by taking the selected vertex as the circle center when the selected vertex is not coincident with the initial point until the selected vertex in the candidate point set is coincident with the initial point, and sequentially connecting the initial point and all the vertexes selected as the circle center to form a region after a plurality of polygonal distribution regions are combined; if the merged area has a concave side, the boundary of the merged area of the plurality of polygonal distribution areas can be accurately drawn along the concave side, so that the merged area of the plurality of polygonal distribution areas can be more accurately determined.
A fifth embodiment of the present invention relates to an electronic device, such as a tablet computer, a desktop computer, and the like. As shown in fig. 6, the electronic device includes a memory 602 and a processor 601;
wherein the memory 602 stores instructions executable by the at least one processor 601, the instructions being executable by the at least one processor 601 to implement:
acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes according to a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes; selecting the next vertex of the starting point as the circle center according to the arrangement sequence, and entering the searching step; the searching step comprises the steps of making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; the alternative point set comprises a next vertex of the circle center and a vertex in the searched circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to be coincident with the initial point, taking the selected vertex as a circle center, and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertexes selected as the circle centers to form a region formed by combining a plurality of polygonal distribution regions.
One or more processors 601 and a memory 602, one processor 601 being illustrated in fig. 6. The processor 601 and the memory 602 may be connected by a bus or other means, and fig. 6 illustrates an example of a connection by a bus. The memory 602, which is a non-volatile computer-readable storage medium, may be used to store non-volatile software programs, non-volatile computer-executable programs, and modules. The processor 601 executes various functional applications and data processing of the device by running nonvolatile software programs, instructions, and modules stored in the memory 602, that is, implements the delivery area merging method described above.
The memory 602 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store filters and the like. Further, the memory 602 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, the memory 602 may optionally include memory located remotely from the processor 601, which may be connected to an external device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
One or more modules are stored in the memory 602 and when executed by the one or more processors 601 perform the method for merging dispatch areas in any of the method embodiments described above.
The above-mentioned device can execute the method provided by the embodiment of the present invention, and has the corresponding functional modules and beneficial effects of the execution method, and reference may be made to the method provided by the embodiment of the present invention for technical details that are not described in detail in the embodiment.
A seventh embodiment of the present invention relates to a computer-readable storage medium storing a computer program. The computer program, when executed by a processor, implements the above-described delivery area merge method embodiment.
That is, as can be understood by those skilled in the art, all or part of the steps in the above method for determining and setting the area distribution pressure may be implemented by a program instructing related hardware, where the program is stored in a storage medium and includes several instructions to enable a device (which may be a single chip, a chip, etc.) or a processor (processor) to execute all or part of the steps of the method according to each embodiment of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
It will be understood by those of ordinary skill in the art that the foregoing embodiments are specific examples for carrying out the invention, and that various changes in form and details may be made therein without departing from the spirit and scope of the invention in practice.
The embodiment of the application provides A1. a method for combining distribution areas, which comprises the following steps:
acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes;
selecting the next vertex of the starting point as a circle center according to the arrangement sequence, and entering a searching step;
the step of searching includes the steps of,
making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; wherein the alternative point set comprises a next vertex of the circle center and a searched vertex in the circle;
selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to coincide with the starting point, taking the selected vertex as a circle center and repeating the searching step;
and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertices selected as circle centers to form a region formed by combining a plurality of polygonal distribution regions.
A2. According to the method for merging distribution areas described in a1, the obtaining a plurality of vertices of a plurality of polygonal distribution areas and arranging the plurality of vertices in a preset direction with a target bump among the plurality of vertices as a starting point specifically includes:
for a plurality of vertexes of each polygonal distribution area, taking any one of the vertexes of the polygonal distribution area as an initial point, and arranging the vertexes of the polygonal distribution area in a preset direction;
and sequentially connecting a plurality of vertexes of the polygon distribution area after arrangement end to obtain a large polygon distribution area, and arranging the plurality of vertexes of the large polygon distribution area in a preset direction by taking the target salient points in the large polygon distribution area as the starting points.
A3. The delivery area merging method according to a2, wherein any one of a plurality of vertices of the polygon delivery area is used as an initial point, and the vertex through which a circumscribed line of the polygon delivery area passes.
A4. According to the delivery area merging method described in a1, the selecting one vertex from the vertices in the alternative point set specifically includes:
calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the previous vertex of the circle center and the coordinate of each vertex in the alternative point set;
and selecting one vertex from the vertexes in the alternative point set according to the evaluation value of each vertex in the alternative point set.
A5. According to the method for merging distribution areas of a4, the calculating the evaluation value of each vertex in the alternative point set according to the coordinates of the center of the circle, the coordinates of the vertex immediately above the center of the circle, and the coordinates of each vertex in the alternative point set specifically includes:
for each vertex in the alternative point set, countingCalculating the vector PxPYAnd vector PYPZAs an evaluation value of the vertex, where PxThe coordinate of the last vertex of the circle center, PYCoordinates representing the center of the circle, PZCoordinates representing each vertex in the set of alternative points.
A6. The method for merging distribution areas according to a5, where selecting one vertex from the vertices in the alternative point set according to the evaluation values of the vertices in the alternative point set specifically includes:
determining whether each vertex in the alternative point set exists in the vector P according to the evaluation value of each vertex in the alternative point setxPYThe vertex on the right side;
if the vector P exists in each vertex in the alternative point setxPYVertex on the right, from the point located on the vector PxPYSelecting a vertex with the largest evaluation value from the vertices on the right side;
if the vector P does not exist in each vertex in the alternative point setxPYAnd the vertex on the right side selects the vertex with the smallest evaluation value from the vertexes in the alternative point set.
A7. The method for merging distribution areas according to a6, wherein the determining whether the vector P is located at each vertex in the alternative point set according to the evaluation value of each vertex in the alternative point setxPYThe right vertex specifically includes:
determining whether the evaluation value of each vertex in the alternative point set has at least one vertex with a positive evaluation value;
if the evaluation value of each vertex in the alternative point set has at least one vertex evaluation value which is a positive value, determining that the at least one vertex is located in the vector PxPYRight side of (c);
if the evaluation value of each vertex in the alternative point set does not have the evaluation value of at least one vertex as a positive value, determining that each vertex in the alternative point set is not located in the vector PxPYTo the right of (a).
A8. The merging method of distribution areas of any one of a1 to a7, the preset direction being a counterclockwise direction.
The embodiment of the present application further provides B9. a merging device for distribution areas, including:
the sorting module is used for acquiring a plurality of vertexes of a plurality of polygonal distribution areas and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes;
the selection module is used for selecting the next vertex of the starting point as the circle center;
the searching module is used for executing a searching step, wherein the searching step comprises the steps of making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; wherein the alternative point set comprises a next vertex of the circle center and a searched vertex in the circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to coincide with the starting point, taking the selected vertex as a circle center and repeating the searching step; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertices selected as circle centers to form a region formed by combining a plurality of polygonal distribution regions.
An electronic device according to an embodiment of the present application further includes a memory and a processor, where the memory stores a computer program, and the processor executes the program to:
acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes;
selecting the next vertex of the starting point as a circle center according to the arrangement sequence, and entering a searching step;
the step of searching includes the steps of,
making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; wherein the alternative point set comprises a next vertex of the circle center and a searched vertex in the circle;
selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to coincide with the starting point, taking the selected vertex as a circle center and repeating the searching step;
and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertices selected as circle centers to form a region formed by combining a plurality of polygonal distribution regions.
C11. The electronic device according to C10, wherein the acquiring multiple vertices of multiple polygonal distribution areas, and arranging the multiple vertices in a preset direction with a target bump in the multiple vertices as a starting point specifically includes:
for a plurality of vertexes of each polygonal distribution area, taking any one of the vertexes of the polygonal distribution area as an initial point, and arranging the vertexes of the polygonal distribution area in a preset direction;
and sequentially connecting a plurality of vertexes of the polygon distribution area after arrangement end to obtain a large polygon distribution area, and arranging the plurality of vertexes of the large polygon distribution area in a preset direction by taking the target salient points in the large polygon distribution area as the starting points.
C12. The electronic apparatus according to C11, wherein any one of the plurality of vertices of the polygon delivery area is taken as an initial point, and the any one vertex is a vertex through which a circumscribed line of the polygon delivery area passes.
C13. According to the electronic device of C11, selecting one vertex from the vertices in the candidate point set specifically includes:
calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the previous vertex of the circle center and the coordinate of each vertex in the alternative point set;
and selecting one vertex from the vertexes in the alternative point set according to the evaluation value of each vertex in the alternative point set.
C14. According to the electronic device of C13, the calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the vertex above the circle center, and the coordinate of each vertex in the alternative point set specifically includes:
for each vertex in the alternative point set, computing a vector PxPYAnd vector PYPZAs an evaluation value of the vertex, where PxThe coordinate of the last vertex of the circle center, PYCoordinates representing the center of the circle, PZCoordinates representing each vertex in the set of alternative points.
C15. According to the electronic device of C14, selecting one vertex from the vertices in the alternative point set according to the evaluation values of the vertices in the alternative point set specifically includes:
determining whether each vertex in the alternative point set exists in the vector P according to the evaluation value of each vertex in the alternative point setxPYThe vertex on the right side;
if the vector P exists in each vertex in the alternative point setxPYVertex on the right, from the point located on the vector PxPYSelecting a vertex with the largest evaluation value from the vertices on the right side;
if the vector P does not exist in each vertex in the alternative point setxPYAnd the vertex on the right side selects the vertex with the smallest evaluation value from the vertexes in the alternative point set.
C16. The electronic device according to C15, wherein the determining whether there is any vertex in the alternative point set located in the vector P according to the evaluation value of each vertex in the alternative point setxPYThe right vertex specifically includes:
determining whether the evaluation value of each vertex in the alternative point set has at least one vertex with a positive evaluation value;
if the evaluation value of each vertex in the alternative point set has at least one vertex evaluation value which is a positive value, determining that the at least one vertex is located in the vector PxPYRight side of (c);
if the evaluation value of each vertex in the alternative point set does not have the evaluation value of at least one vertex as a positive value, determining that each vertex in the alternative point set is not located in the vector PxPYTo the right of (a).
C17. The electronic device of any of C10-C16, the preset direction being a counter-clockwise direction.
Further provided is a non-volatile storage medium storing a computer-readable program for causing a computer to execute the delivery area merging method according to any one of a1 to A8.

Claims (17)

1. A method for merging distribution areas, comprising:
acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes;
selecting the next vertex of the starting point as a circle center according to the arrangement sequence, and entering a searching step;
the step of searching includes the steps of,
making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; wherein the alternative point set comprises a next vertex of the circle center and a searched vertex in the circle;
selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to coincide with the starting point, taking the selected vertex as a circle center and repeating the searching step; wherein the selecting one vertex from the vertices in the alternative point set comprises: calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the previous vertex of the circle center and the coordinate of each vertex in the alternative point set; selecting a vertex from the vertexes in the alternative point set according to the evaluation value of each vertex in the alternative point set;
and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertices selected as circle centers to form a region formed by combining a plurality of polygonal distribution regions.
2. The method for merging delivery areas according to claim 1, wherein the obtaining of the vertices of the polygonal delivery areas and the arranging of the vertices in the preset direction with the target salient points of the vertices as starting points specifically comprises:
for a plurality of vertexes of each polygonal distribution area, taking any one of the vertexes of the polygonal distribution area as an initial point, and arranging the vertexes of the polygonal distribution area in a preset direction;
and sequentially connecting a plurality of vertexes of the polygon distribution area after arrangement end to obtain a large polygon distribution area, and arranging the plurality of vertexes of the large polygon distribution area in a preset direction by taking the target salient points in the large polygon distribution area as the starting points.
3. The delivery area merging method according to claim 2, wherein in taking any one of a plurality of vertices of the polygonal delivery area as an initial point, the any one vertex is a vertex through which a circumscribed line of the polygonal delivery area passes.
4. The method for merging distribution areas according to claim 1, wherein the calculating the evaluation value of each vertex in the alternative point set according to the coordinates of the center of the circle, the coordinates of the vertex immediately above the center of the circle, and the coordinates of each vertex in the alternative point set comprises:
for each vertex in the alternative point set, computing a vector PxPYAnd vector PYPZAs an evaluation value of the vertex, where PxThe coordinate of the last vertex of the circle center, PYCoordinates representing the center of the circle, PZCoordinates representing each vertex in the set of alternative points.
5. The method as claimed in claim 4, wherein the selecting a vertex from the vertices in the alternative point set according to the evaluation value of each vertex in the alternative point set specifically comprises:
determining whether each vertex in the alternative point set exists in the vector P according to the evaluation value of each vertex in the alternative point setxPYThe vertex on the right side;
if the vector P exists in each vertex in the alternative point setxPYVertex on the right, from the point located on the vector PxPYSelecting a vertex with the largest evaluation value from the vertices on the right side;
if the vector P does not exist in each vertex in the alternative point setxPYAnd the vertex on the right side selects the vertex with the smallest evaluation value from the vertexes in the alternative point set.
6. The method of claim 5, wherein the determining whether the vector P is located at each vertex in the alternative point set according to the evaluation value of each vertex in the alternative point setxPYThe right vertex specifically includes:
determining whether the evaluation value of each vertex in the alternative point set has at least one vertex with a positive evaluation value;
if the evaluation value of each vertex in the alternative point set has at least one vertex evaluation value which is a positive value,then it is determined that the at least one vertex is located in the vector PxPYRight side of (c);
if the evaluation value of each vertex in the alternative point set does not have the evaluation value of at least one vertex as a positive value, determining that each vertex in the alternative point set is not located in the vector PxPYTo the right of (a).
7. The method of merging delivery areas of any one of claims 1 to 6, wherein the predetermined direction is a counter-clockwise direction.
8. A consolidation apparatus for distribution areas, comprising:
the sorting module is used for acquiring a plurality of vertexes of a plurality of polygonal distribution areas and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes;
the selection module is used for selecting the next vertex of the starting point as the circle center;
the searching module is used for executing a searching step, wherein the searching step comprises the steps of making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; wherein the alternative point set comprises a next vertex of the circle center and a searched vertex in the circle; selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to coincide with the starting point, taking the selected vertex as a circle center and repeating the searching step; wherein the selecting one vertex from the vertices in the alternative point set comprises: calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the previous vertex of the circle center and the coordinate of each vertex in the alternative point set; selecting a vertex from the vertexes in the alternative point set according to the evaluation value of each vertex in the alternative point set; and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertices selected as circle centers to form a region formed by combining a plurality of polygonal distribution regions.
9. An electronic device comprising a memory and a processor, the memory storing a computer program, the processor executing the program to perform:
acquiring a plurality of vertexes of a plurality of polygonal distribution areas, and arranging the vertexes in a preset direction by taking a target salient point in the vertexes as a starting point; the target salient point is a vertex through which a circumscribed line of the set of the polygonal distribution area passes;
selecting the next vertex of the starting point as a circle center according to the arrangement sequence, and entering a searching step;
the step of searching includes the steps of,
making a circle according to the circle center and a preset radius, searching a vertex in the circle, and setting an alternative point set; wherein the alternative point set comprises a next vertex of the circle center and a searched vertex in the circle;
selecting a vertex from all vertexes in the alternative point set, and when the selected vertex is determined not to coincide with the starting point, taking the selected vertex as a circle center and repeating the searching step;
and when the selected vertex is determined to be coincident with the starting point, sequentially connecting the starting point and all the vertices selected as circle centers to form a region formed by combining a plurality of polygonal distribution regions.
10. The electronic device according to claim 9, wherein the obtaining of the plurality of vertices of the plurality of polygonal distribution areas and the arranging of the plurality of vertices in the preset direction with the target salient point of the plurality of vertices as a starting point specifically comprises:
for a plurality of vertexes of each polygonal distribution area, taking any one of the vertexes of the polygonal distribution area as an initial point, and arranging the vertexes of the polygonal distribution area in a preset direction;
and sequentially connecting a plurality of vertexes of the polygon distribution area after arrangement end to obtain a large polygon distribution area, and arranging the plurality of vertexes of the large polygon distribution area in a preset direction by taking the target salient points in the large polygon distribution area as the starting points.
11. The electronic apparatus according to claim 10, wherein in taking any one of a plurality of vertices of the polygon delivery area as an initial point, the any one vertex is a vertex through which a circumscribed line of the polygon delivery area passes.
12. The electronic device according to claim 10, wherein the selecting one vertex from the vertices in the alternative point set specifically includes:
calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the circle center, the coordinate of the previous vertex of the circle center and the coordinate of each vertex in the alternative point set;
and selecting one vertex from the vertexes in the alternative point set according to the evaluation value of each vertex in the alternative point set.
13. The electronic device according to claim 12, wherein the calculating the evaluation value of each vertex in the alternative point set according to the coordinate of the center of the circle, the coordinate of the vertex immediately above the center of the circle, and the coordinate of each vertex in the alternative point set includes:
for each vertex in the alternative point set, computing a vector PxPYAnd vector PYPZAs an evaluation value of the vertex, where PxThe coordinate of the last vertex of the circle center, PYCoordinates representing the center of the circle, PZCoordinates representing each vertex in the set of alternative points.
14. The electronic device according to claim 13, wherein the selecting one vertex from the vertices in the alternative point set according to the evaluation values of the vertices in the alternative point set specifically includes:
determining whether each vertex in the alternative point set exists in the vector P according to the evaluation value of each vertex in the alternative point setxPYThe vertex on the right side;
if the vector P exists in each vertex in the alternative point setxPYVertex on the right, from the point located on the vector PxPYSelecting a vertex with the largest evaluation value from the vertices on the right side;
if the vector P does not exist in each vertex in the alternative point setxPYAnd the vertex on the right side selects the vertex with the smallest evaluation value from the vertexes in the alternative point set.
15. The electronic device according to claim 14, wherein the determination of whether or not there is any vertex in the alternative point set located in the vector P is performed based on the evaluation value of each vertex in the alternative point setxPYThe right vertex specifically includes:
determining whether the evaluation value of each vertex in the alternative point set has at least one vertex with a positive evaluation value;
if the evaluation value of each vertex in the alternative point set has at least one vertex evaluation value which is a positive value, determining that the at least one vertex is located in the vector PxPYRight side of (c);
if the evaluation value of each vertex in the alternative point set does not have the evaluation value of at least one vertex as a positive value, determining that each vertex in the alternative point set is not located in the vector PxPYTo the right of (a).
16. The electronic device according to any one of claims 9 to 15, wherein the preset direction is a counterclockwise direction.
17. A non-volatile storage medium storing a computer-readable program for causing a computer to execute the delivery area merging method according to any one of claims 1 to 7.
CN201811609511.8A 2018-12-27 2018-12-27 Distribution area merging method and device, electronic equipment and storage medium Active CN109685751B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811609511.8A CN109685751B (en) 2018-12-27 2018-12-27 Distribution area merging method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811609511.8A CN109685751B (en) 2018-12-27 2018-12-27 Distribution area merging method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109685751A CN109685751A (en) 2019-04-26
CN109685751B true CN109685751B (en) 2021-03-09

Family

ID=66189966

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811609511.8A Active CN109685751B (en) 2018-12-27 2018-12-27 Distribution area merging method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109685751B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111862137A (en) * 2020-07-15 2020-10-30 上海钧正网络科技有限公司 Method and device for determining graph boundary according to point set

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105184412A (en) * 2015-09-21 2015-12-23 北京农业信息技术研究中心 Logistics delivery route planning method and system based on geographic positions
CN105447667A (en) * 2015-11-17 2016-03-30 成都信息工程大学 Automatic distribution method of express delivery orders
CN106651247A (en) * 2016-11-16 2017-05-10 成都地图慧科技有限公司 Address area block matching method based on GIS topology analysis and address area block matching system thereof
CN106779529A (en) * 2016-11-23 2017-05-31 合肥壹客送网络科技有限公司 A kind of merchandise allocator and system
CN108960694A (en) * 2017-05-19 2018-12-07 北京京东尚科信息技术有限公司 Dispense area determination method and device

Family Cites Families (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH07160899A (en) * 1993-12-07 1995-06-23 Fujitsu Ltd Method and device for drawing divisionally polygon
DE102009018055A1 (en) * 2009-02-10 2010-08-19 Navigon Ag Method for operating a navigation device
CN106273480B (en) * 2016-08-11 2019-02-22 福建农林大学 Can concave region 3D printing speed paths planning method
CN106982438B (en) * 2017-03-28 2017-11-10 中国地质大学(武汉) It is a kind of to seek simultaneously confirmation method for more satellite sensor earth observation overlay areas
CN108335302B (en) * 2018-01-26 2021-10-08 上海思岚科技有限公司 Region segmentation method and device
CN108919954B (en) * 2018-06-29 2021-03-23 蓝色智库(北京)科技发展有限公司 Dynamic change scene virtual and real object collision interaction method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105184412A (en) * 2015-09-21 2015-12-23 北京农业信息技术研究中心 Logistics delivery route planning method and system based on geographic positions
CN105447667A (en) * 2015-11-17 2016-03-30 成都信息工程大学 Automatic distribution method of express delivery orders
CN106651247A (en) * 2016-11-16 2017-05-10 成都地图慧科技有限公司 Address area block matching method based on GIS topology analysis and address area block matching system thereof
CN106779529A (en) * 2016-11-23 2017-05-31 合肥壹客送网络科技有限公司 A kind of merchandise allocator and system
CN108960694A (en) * 2017-05-19 2018-12-07 北京京东尚科信息技术有限公司 Dispense area determination method and device

Also Published As

Publication number Publication date
CN109685751A (en) 2019-04-26

Similar Documents

Publication Publication Date Title
US10796022B2 (en) Weighted source data secured on blockchains
CN110990516B (en) Map data processing method, device and server
CN109657163B (en) Destination address determining method and device, electronic equipment and storage medium
CN112348317B (en) Method and system for generating project planning conditions of smart city
CN109683858B (en) Data processing method and device
CN111862204A (en) Method for extracting visual feature points of image and related device
CN109685751B (en) Distribution area merging method and device, electronic equipment and storage medium
CN109657022B (en) Merchant searching method and device, electronic equipment and storage medium
CN114596423A (en) Model rendering method and device based on virtual scene gridding and computer equipment
CN112887910B (en) Method and device for determining abnormal coverage area and computer readable storage medium
CN111435936B (en) Cloud host creation method, cloud host creation device, server and computer readable storage medium
CN105677843A (en) Method for automatically obtaining attribute of four boundaries of parcel
CN115779424A (en) Navigation grid path finding method, device, equipment and medium
CN114463499A (en) Building three-dimensional modeling method and device
CN111460237B (en) Data query method and device, readable storage medium and electronic equipment
CN116295466A (en) Map generation method, map generation device, electronic device, storage medium and vehicle
CN112734254A (en) Risk early warning method and device for transformer substation construction and computer equipment
WO2018205872A1 (en) Target object processing method, device, storage medium and electronic device
CN113065071B (en) Product information recommendation method and computer equipment
CN113064720B (en) Object allocation method, device, server and storage medium
CN111274272B (en) Object searching method and device and computer system
CN113312436B (en) Spatial index processing method and device
CN110075520B (en) Method, system and device for quickly searching resources in game map
CN115292428A (en) Map element loading method and device, server and computer readable storage medium
CN116932496A (en) Method and device for determining common object, storage medium and electronic equipment

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