CN108665117B - Calculation method and device for shortest indoor space path, terminal equipment and storage medium - Google Patents

Calculation method and device for shortest indoor space path, terminal equipment and storage medium Download PDF

Info

Publication number
CN108665117B
CN108665117B CN201810495043.XA CN201810495043A CN108665117B CN 108665117 B CN108665117 B CN 108665117B CN 201810495043 A CN201810495043 A CN 201810495043A CN 108665117 B CN108665117 B CN 108665117B
Authority
CN
China
Prior art keywords
path
point
starting point
area
network node
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.)
Expired - Fee Related
Application number
CN201810495043.XA
Other languages
Chinese (zh)
Other versions
CN108665117A (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.)
Xiamen University of Technology
Original Assignee
Xiamen University of Technology
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 Xiamen University of Technology filed Critical Xiamen University of Technology
Priority to CN201810495043.XA priority Critical patent/CN108665117B/en
Publication of CN108665117A publication Critical patent/CN108665117A/en
Application granted granted Critical
Publication of CN108665117B publication Critical patent/CN108665117B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • 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/04Forecasting or optimisation specially adapted for administrative or management purposes, e.g. linear programming or "cutting stock problem"
    • G06Q10/047Optimisation of routes or paths, e.g. travelling salesman problem

Abstract

The embodiment of the invention discloses a method for calculating the shortest path of an indoor space, which comprises the following steps: setting network nodes according to indoor space layout and barrier distribution; the method comprises the steps that network nodes are arranged at space change points, the indoor space is divided into a plurality of sub-areas, a starting point sub-area and an end point sub-area where a starting point and an end point are respectively located are obtained, and according to the starting point sub-area and the end point sub-area, a first path from the network nodes of the starting point sub-area to the network nodes of the end point sub-area, a second path from the starting point in the starting point sub-area to the network nodes of the starting point sub-area and a third path from the end point in the end point sub-area to the network nodes of the end point sub-area are determined; the first path, the second path and the third path are respectively the shortest paths between two corresponding points, and the shortest path from the starting point to the end point is calculated according to the first path, the second path and the third path.

Description

Calculation method and device for shortest indoor space path, terminal equipment and storage medium
Technical Field
The present invention relates to the field of computer technologies, and in particular, to a method and an apparatus for calculating a shortest indoor space path, a terminal device, and a storage medium.
Background
With the acceleration of the urbanization process, large indoor buildings are more and more, the internal structures of the large indoor buildings are more and more complex, the indoor activity time of people is longer and longer, and the indoor navigation path planning has practical significance. In the path planning algorithm, Dijkstra (Dijkstra) algorithm is an effective algorithm for solving the shortest path from a certain source point to other points in the directed graph, and the algorithm is suitable for network topology change, has stable performance and is a classical algorithm for path planning.
The idea of the Dijkstra algorithm is as follows: and G-E is a weighted directed graph, the set V of all vertexes in the graph is divided into two groups, the first group is a vertex set (represented by S, only one source point in S is initially obtained, every shortest path is obtained, the vertex set is added into the set S until all vertexes are added into S, the algorithm is finished), the second group is a vertex set (represented by U) of the rest undetermined shortest paths, and the vertexes of the second group are added into S in sequence according to the ascending order of the lengths of the shortest paths. In the joining process, the shortest path length from the source point v to each vertex in S is always kept no longer than the shortest path length from the source point v to any vertex in U. In addition, each vertex corresponds to a distance, the distance of the vertex in S is the shortest path length from v to the vertex, and the distance of the vertex in U is the current shortest path length from v to the vertex, only including the vertex in S as the middle vertex.
Dijkstra algorithm steps:
a. initially, S only contains the source point, i.e., S ═ v, where v is 0 in distance. U includes vertices other than v, i.e., U ═ other vertices, where if v has an edge with vertex U in U, then < U, v > has a weight other than ∞, and if U is not an edge adjacency point of v, then the < U, v > weight is ∞.
b. And selecting a vertex k with the minimum distance v from the U, and adding k into S (the selected distance is the length of the shortest path from v to k).
c. Modifying the distance of each vertex in the U by taking k as a newly considered middle point; if the distance from the source point v to the vertex u (passing through the vertex k) is shorter than the original distance (not passing through the vertex k), the distance value of the vertex u is modified, and the weight of the distance of the vertex k of the modified distance value is added to the upper side.
d. Repeating steps b and c until all vertices are contained in S.
The Dijkstra algorithm can obtain the shortest path from a starting point to a terminal point, but in the problem of actual indoor path planning, due to the complexity and diversity of indoor environments, the actual indoor path selection is personalized and diversified, so that people can select the indoor path not only by taking the path distance as a unique standard, but also by considering other factors influencing the path selection, and the indoor path selection requirements of people cannot be met only by considering the path distance. In an indoor environment, the distance between moving objects is relatively small, and there is a possibility that the objects are blocked by obstacles, which makes a query more precise, and therefore, the distance cannot be easily abstracted to the euclidean distance between two points for approximate calculation.
In view of this, how to overcome the limitation of the existing algorithm, from the perspective of an indoor obstacle, providing an indoor shortest path method to search for the shortest path considering the obstacle becomes a technical problem to be solved at present.
Disclosure of Invention
The embodiment of the invention provides a method and a device for calculating the shortest path of an indoor space, terminal equipment and a storage medium. By effectively organizing and managing the spatial data of the regions, the nodes and the like, the Dijkstra shortest path algorithm is optimally designed under the indoor discrete grid space environment. The shortest paths between the sub-areas and the shortest paths in the areas are separately processed, particularly, the intersection point of the shortest paths and the shortest path is searched in the starting and ending point sub-area to replace the network node in the sub-area, and finally, the comprehensive optimal shortest path is obtained.
In a first aspect, an embodiment of the present invention provides a method for calculating a shortest indoor space, which specifically includes:
setting network nodes according to indoor space layout and barrier distribution; the network nodes are arranged at the space change points;
dividing an indoor space into a plurality of sub-areas; the secondary region comprises at least one network node, and any point in the secondary region can be directly connected to the network node in the secondary region through one to two times of rows or columns;
acquiring a starting point sub-area and an end point sub-area where a starting point and an end point are respectively located;
determining a first path from the network node of the starting point sub-area to the network node of the end point sub-area, a second path from the starting point in the starting point sub-area to the network node of the starting point sub-area, and a third path from the end point in the end point sub-area to the network node of the end point sub-area according to the starting point sub-area and the end point sub-area; the first path, the second path and the third path are respectively the shortest paths between two corresponding points;
and calculating the shortest path from the starting point to the end point according to the first path, the second path and the third path.
Further, the shortest path calculation is performed on the first path by using Dijkstra algorithm.
Further, the shortest path calculation step of the second path includes:
acquiring an intersection point of the first path and the starting point secondary region, a network node in the starting point secondary region and a starting point;
and constructing a triangle with the intersection point of the first path and the starting point secondary area, the network node in the starting point secondary area and the starting point as a vertex, and determining the path from the starting point to the intersection point as the second path.
Further, the calculating of the third path includes:
acquiring an intersection point of the first path and the terminal sub-area, a network node in the terminal sub-area and a terminal;
and constructing an intersection point of the first path and the end point sub-area, a network node in the end point sub-area and a triangle with the end point as a vertex, and determining that a path from the end point to the intersection point is a third path.
Further, by locating locations in the indoor space in a plurality of consecutive equal grid compositions, all locations of the indoor space can be labeled by row-column coding of the grids.
Further, the spatial variation point of the indoor space includes a gate position, an intersection or a branch of a corridor, a corner having an obstacle in the indoor space.
In a second aspect, an embodiment of the present invention provides an apparatus for calculating a shortest indoor spatial path, where the apparatus includes:
the network node setting module is used for setting network nodes according to indoor space layout and barrier distribution; wherein the network node is arranged at a spatial variation point;
a dividing module for dividing the indoor space into a plurality of sub-regions; the secondary region comprises at least one network node, and any point in the secondary region can be directly connected to the network node in the secondary region through one to two rows or columns;
the acquisition module is used for acquiring a starting point sub-area and an end point sub-area where a starting point and an end point are respectively located;
the system comprises a network node, a starting point and a first path, wherein the network node is used for acquiring an intersection point of the first path and a starting point secondary area, and the network node and the starting point in the starting point secondary area;
the system is used for acquiring an intersection point of the first path and the terminal sub-area, a network node in the terminal sub-area and a terminal;
a path determining module, configured to determine, according to the starting point secondary region and the ending point secondary region, a first path between a network node of the starting point secondary region and a network node of the ending point secondary region, a second path between the starting point in the starting point secondary region and the network node of the starting point secondary region, and a third path between the ending point in the ending point secondary region and the network node of the ending point secondary region; the first path, the second path and the third path are respectively the shortest paths between two corresponding points;
the calculation module is used for calculating the shortest path from the starting point to the end point according to the first path, the second path and the third path; for performing a shortest path calculation on the first path by using Dijkstra algorithm; a shortest path calculation for the second path and the third path; the computing module further comprises a construction module and a labeling module;
the construction module is configured to construct a triangle with an intersection of the first path and the starting point secondary region, a network node in the starting point secondary region, and the starting point as a vertex, and determine that a path from the starting point to the intersection is the second path; the triangle is used for constructing an intersection point of the first path and the end point sub-area, a network node in the end point sub-area and a triangle with the end point as a vertex, and determining that a path from the end point to the intersection point is the third path;
the labeling module is used for positioning the positions in the indoor space by forming a plurality of continuous equal grids, so that all the positions of the indoor space can be labeled by the row and column coding of the grids.
In a third aspect, an embodiment of the present invention provides a terminal device, which includes a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, where the processor, when executing the computer program, implements the indoor space shortest path calculation method as described above.
In a fourth aspect, the present invention provides a computer-readable storage medium, where the computer-readable storage medium includes a stored computer program, where the computer program, when running, controls an apparatus where the computer-readable storage medium is located to perform the indoor space shortest path calculation method as described above.
The embodiment of the invention has the following beneficial effects:
1. and (4) discrete grid space coding and shortest path planning thereof.
2. The precise point position shortest path between any two grid points is obtained in a mode of combining the areas and the areas, and therefore the method can be used for automatic addressing and route planning of indoor robots.
3. And finally forming an indoor discrete space shortest path navigation planning method by applying the intersection point of the line and the boundary of the region in the shortest path calculation in the region.
Drawings
In order to more clearly illustrate the technical solution of the present invention, 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 that other drawings can be obtained according to the drawings without creative efforts.
Fig. 1 is a schematic flow chart of a method for calculating a shortest indoor spatial path according to an embodiment of the present invention.
Fig. 2 is a schematic structural diagram of three parts of an indoor shortest path according to an embodiment of the present invention.
Fig. 3 is a schematic structural diagram of a shortest path design of a start-end area and an end-end area according to an embodiment of the present invention.
Fig. 4 is a network node distribution diagram according to an embodiment of the present invention.
Fig. 5 is a schematic structural diagram of an indoor spatial shortest path calculating device according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
The first embodiment of the present invention:
referring to fig. 1 to 3, fig. 1 is a schematic flow chart of a method for calculating a shortest path in an indoor space according to an embodiment of the present invention, fig. 2 is a schematic structural diagram of three parts of a shortest path in an indoor space according to an embodiment of the present invention, and fig. 3 is a schematic structural diagram of a shortest path design in an origin and destination area according to an embodiment of the present invention. The embodiment of the invention aims at the shortest path planning problem in the indoor discrete grid environment, and performs sub-area division, geocoding, network node selection and the like on a positioning area according to indoor space layout and barrier distribution. By effectively organizing and managing the spatial data of the regions, the nodes and the like, the Dijkstra shortest path algorithm is optimally designed under the indoor discrete grid space environment. The shortest paths between the sub-areas and the shortest paths in the areas are separately processed, particularly, the intersection point of the shortest paths and the shortest path is searched in the starting and ending point sub-area to replace the network node in the sub-area, and finally, the comprehensive optimal shortest path is obtained.
The embodiment of the invention provides a method for calculating the shortest path of an indoor space, which specifically comprises the following steps:
s10, setting network nodes according to indoor space layout and obstacle distribution; wherein the network node is arranged at a spatial variation point.
The spatial variation points of indoor space described herein include door locations in the indoor space, intersections or branches of corridors, corners with obstacles, and by being positioned with a plurality of consecutive equal grid compositions, locations in the indoor space so that all locations of the indoor space can be marked by row-column coding of the grids.
The whole indoor space is composed of continuous grids with the same size, the area of each grid is 1 square meter, the starting point of grid row-column coding is the lower left corner (1, 1), the number of rows is increased from bottom to top and the number of columns is increased from left to right, and the grids are distributed in the whole navigation area. Meanwhile, the encoding mode can obtain the geographic coordinates of all grid points by projecting in proportion as long as the geographic coordinates of the lower left corner and the map scale are given, so that seamless connection with an outdoor map is established.
The network nodes are chosen to balance the density of the arrangement and to be distributed uniformly as much as possible. And under the conditions of ensuring that the density is small and improving the calculation efficiency, all grid points can establish a passing route through the series connection of the network nodes. The indoor grid space is often complex in structure, and has walls, doors, corridors, various barriers and the like. For this purpose, the network nodes must also be selected from the indoor structure, the network nodes must be arranged at the door positions of small spaces like offices, the network nodes must be arranged at the intersections or branches of corridors, and the network nodes must be arranged at the corners having obstacles.
Referring to fig. 4, the gray grid points in fig. 4 are selected network nodes, including A, B, C, D, F, G, K, L, M, N, Q, R for all door positions, Z0901, Z1401, Z4001 of the hallway, and Z0101, Z0201, Z0301, a. All these network nodes can be classified into two categories according to whether they affect the division of the sub-area. Wherein the network nodes starting with the letter Z determine the subsequent sub-area division and the numbers following the Z letter indicate the number of the sub-area and the number of the network nodes in the sub-area. The network nodes starting from the rest letters do not influence the division of the secondary area, but occupy one grid in the area.
S20, dividing the indoor space into a plurality of sub-areas; the secondary region comprises at least one network node, and any point in the secondary region can be directly connected to the network node in the secondary region through one to two rows or columns.
The indoor grid spaces are often connected through doors, corridors and the like between the sub-areas after function division, and therefore, the influence of walls and various obstacles on traffic obstruction must be considered during space division. More importantly, each area needs to take the position of the key node into consideration, so that any point in the control area can be directly connected to the only key node in the control area through 1-2 times of rows or columns. In order not to miss any grid points, the whole indoor grid space is divided into sub-regions comprising rectangles, lines, etc., and no overlap is allowed between the sub-regions. Meanwhile, no wall with a completely blocked passage can be arranged in any secondary area.
And S30, acquiring a starting point sub-area and an end point sub-area where the starting point and the end point are respectively positioned.
S40, determining a first path from the network node in the starting point sub-area to the network node in the ending point sub-area, a second path from the starting point in the starting point sub-area to the network node in the starting point sub-area, and a third path from the ending point in the ending point sub-area to the network node in the ending point sub-area according to the starting point sub-area and the ending point sub-area; the first path, the second path and the third path are respectively the shortest paths between two corresponding points.
And S50, calculating the shortest path from the starting point to the end point according to the first path, the second path and the third path.
Referring to fig. 2, after the positions of the start point and the end point are given, usually by column and row coding, the secondary areas where the start point and the end point are located are first determined, then Dijkstra shortest path calculation is performed with the network nodes in the two secondary areas as the start point and end point network nodes facing the area, that is, the first path1 between the network node of the start point secondary area and the network node of the end point secondary area shown in fig. 2 is performed, and the corresponding path and path length are obtained. The secondary area has a unique network node, and the shortest path calculation between the secondary areas where the starting point and the end point are respectively located is also converted into the shortest path calculation between two secondary area network nodes. All network nodes are stored in a spatial database, and for this purpose, the Dijkstra algorithm can be directly applied to obtain the shortest path and the path length between the network nodes.
Next, the shortest paths to the network nodes in its secondary region, respectively, are calculated in the starting point and end point secondary regions, i.e. the second path2 between the network nodes of the starting point to the starting point secondary region in the starting point secondary region and the third path3 between the network nodes of the end point to the end point secondary region in the end point secondary region as shown in fig. 2. The shortest calculation step of the second path and the third path includes: with reference to figure 3 of the drawings,
acquiring an intersection point of the first path and the starting point sub-area, a network node in the starting point sub-area, and a starting point, acquiring an intersection point of the first path and the ending point sub-area, a network node in the ending point sub-area, and an ending point;
the two first and last edges of the shortest path in the starting point sub-area and the ending point sub-area intersect with the sub-area including the starting point sub-area and the ending point, respectively, and the intersection points are assumed to be PZS (i.e. the intersection point of the first path and the starting point sub-area) and PZT (i.e. the intersection point of the first path and the ending point sub-area), respectively, as shown in fig. 3;
and constructing an intersection point of the first path and the end point sub-area, a network node in the sub-area and a triangle with the end point as a vertex, determining a path from the end point to the intersection point as a third path, constructing the intersection point of the first path and the starting point sub-area, the network node in the starting point sub-area and the triangle with the starting point as the vertex, and determining a path from the starting point to the intersection point as a second path.
Referring to fig. 3, according to the creation rule of the sub-region, any two points in the region have a direct connection or a connection after 1 turn, and for this reason, in a triangle formed by the network node Z0101 where the starting point sub-region is located, the starting point S and the PZS, the side length of the triangle side starting point SPZS is always smaller than the sum of the two outer side lengths, so the shortest path in the starting point sub-region is the side of the starting point S-PZS. Therefore, the shortest path edge is calculated by subtracting the corresponding row and column directly, taking the absolute value and adding. Assuming starting point secondary zone intersection coordinates PZS (XPZS, YPZS) and starting point coordinates S (XS, YS), the shortest path length is formulated as: d ═ XPZS-XS | + | YPZS-YS |, the shortest path is: (XS, YS) - - > (XPZS, YS) - - > (XPZS, YPZS). The process is also suitable for the shortest path situation of the secondary area where the terminal point T is located. The synthesis of the three paths is the final shortest path planning result.
The indoor discrete grid space shortest path navigation relates to the application of network nodes, secondary areas and other space data, and therefore, the efficiency and the effect of path planning are directly influenced by the organization and storage of the data. The types of data that need to be organized for storage include: regional spatial geometry data, network node data, direct connection node edge data, and the like.
Second embodiment of the invention:
on the basis of the first embodiment, referring to fig. 5, fig. 5 is a schematic structural diagram of an indoor spatial shortest path calculation apparatus according to an embodiment of the present invention. The embodiment of the invention provides a device for calculating the shortest path of an indoor space, which comprises:
a network node setting module 100, configured to set network nodes according to an indoor spatial layout and obstacle distribution; wherein the network node is arranged at a spatial variation point;
a dividing module 200, configured to divide the indoor space into a plurality of sub-regions; the secondary region comprises at least one network node, and any point in the secondary region can be directly connected to the network node in the secondary region through one to two rows or columns;
an obtaining module 300, configured to obtain a starting point sub-region and an ending point sub-region where a starting point and an ending point are located respectively;
the system comprises a network node, a starting point and a first path, wherein the network node is used for acquiring an intersection point of the first path and a starting point secondary area, and the network node and the starting point in the starting point secondary area;
the system is used for acquiring an intersection point of the first path and the terminal sub-area, a network node in the terminal sub-area and a terminal;
a path determining module 400, configured to determine, according to the starting point secondary region and the ending point secondary region, a first path from a network node in the starting point secondary region to a network node in the ending point secondary region, a second path from a starting point in the starting point secondary region to the network node in the starting point secondary region, and a third path from an ending point in the ending point secondary region to the network node in the ending point secondary region; the first path, the second path and the third path are respectively the shortest paths between two corresponding points;
a calculating module 500, configured to calculate a shortest path from a starting point to the end point according to the first path, the second path, and the third path; for performing a shortest path calculation on the first path by using Dijkstra algorithm; a shortest path calculation for the second path and the third path; wherein, the computing module further comprises a construction module 600 and an annotation module 700.
The constructing module 600 is configured to construct a triangle with an intersection of the first path and the starting point secondary region, a network node in the starting point secondary region, and the starting point as a vertex, and determine that a path from the starting point to the intersection is the second path; the triangle is used for constructing an intersection point of the first path and the end point sub-area, a network node in the end point sub-area and a triangle with the end point as a vertex, and determining that a path from the end point to the intersection point is the third path;
the labeling module 700 is configured to locate a position in the indoor space by composing a plurality of consecutive equal grids such that all positions of the indoor space can be labeled by row-column coding of the grids.
Third embodiment of the invention:
a third embodiment of the present invention provides an indoor spatial shortest path calculation terminal device, including a processor, a memory, and a computer program stored in the memory and configured to be executed by the processing. The processor, when executing the computer program, implements the steps in any one of the above embodiments of the method for calculating an indoor shortest spatial path, such as step S10 shown in fig. 1. Alternatively, the processor, when executing the computer program, implements the functions in the above-mentioned device examples, such as the network node module 100 shown in fig. 3.
The fourth embodiment of the present invention:
a fourth embodiment of the present invention provides a computer-readable storage medium including a stored computer program, such as a program of an indoor spatial shortest path calculation method. When the computer program runs, the apparatus on which the computer readable storage medium is located is controlled to execute the method for calculating an indoor spatial shortest path described in the first embodiment.
Illustratively, the computer programs described in the third and fourth embodiments of the present invention may be partitioned into one or more modules, which are stored in the memory and executed by the processor to implement the present invention. The one or more modules may be a series of computer program instruction segments capable of performing specific functions, the instruction segments describing the execution process of the computer program in the computing device for implementing an indoor shortest spatial path. For example, the apparatus described in embodiment two of the present invention.
The Processor may be a Central Processing Unit (CPU), other general purpose Processor, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), an off-the-shelf programmable Gate Array (FPGA) or other programmable logic device, discrete Gate or transistor logic, discrete hardware components, etc. The general processor may be a microprocessor or the processor may be any conventional processor, etc., and the processor is a control center of the indoor space shortest path calculation method, and various interfaces and lines are used to connect the various parts of the whole indoor space shortest path calculation method.
The memory may be used to store the computer programs and/or modules, and the processor may implement various functions of the indoor space shortest path calculation method by operating or executing the computer programs and/or modules stored in the memory and calling data stored in the memory. The memory may mainly include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required by at least one function (such as a sound playing function, a text conversion function, etc.), and the like; the storage data area may store data (such as audio data, text message data, etc.) created according to the use of the cellular phone, etc. In addition, the memory may include high speed random access memory, and may also include non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), at least one magnetic disk storage device, a Flash memory device, or other volatile solid state storage device.
Wherein, the modules of the indoor space shortest path calculating device can be stored in a computer readable storage medium if the modules are realized in the form of software functional units and sold or used as independent products. Based on such understanding, all or part of the flow of the method according to the embodiments of the present invention may also be implemented by a computer program, which may be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the method embodiments may be implemented. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer-readable medium may include: any entity or device capable of carrying the computer program code, recording medium, usb disk, removable hard disk, magnetic disk, optical disk, computer Memory, Read-only Memory (ROM), Random Access Memory (RAM), electrical carrier wave signals, telecommunications signals, software distribution medium, etc. It should be noted that the computer readable medium may contain content that is subject to appropriate increase or decrease as required by legislation and patent practice in jurisdictions, for example, in some jurisdictions, computer readable media does not include electrical carrier signals and telecommunications signals as is required by legislation and patent practice.
It should be noted that the above-described device embodiments are merely illustrative, where the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. In addition, in the drawings of the embodiment of the apparatus provided by the present invention, the connection relationship between the modules indicates that there is a communication connection between them, and may be specifically implemented as one or more communication buses or signal lines. One of ordinary skill in the art can understand and implement it without inventive effort.
While the foregoing is directed to the preferred embodiment of the present invention, it will be understood by those skilled in the art that various changes and modifications may be made without departing from the spirit and scope of the invention.

Claims (4)

1. A method for calculating shortest path to indoor space, the method comprising:
setting network nodes according to the layout of the indoor space and the distribution of the obstacles; wherein the network node is disposed at a spatial variation point of the indoor space including a door position, a crossing or a branching of a corridor, a corner with an obstacle in the indoor space;
locating locations in the indoor space by being composed of a plurality of consecutive equal grids such that all locations of the indoor space can be labeled by row-column coding of the grids;
dividing the indoor space into a plurality of sub-regions; the secondary region comprises at least one network node, and any point in the secondary region can be directly connected to the network node in the secondary region through one to two rows or columns;
acquiring a starting point sub-area and an end point sub-area where a starting point and an end point are respectively located;
according to the starting point secondary region and the ending point secondary region, determining a first path from a network node of the starting point secondary region to a network node of the ending point secondary region, a second path from the starting point to the network node of the starting point secondary region in the starting point secondary region, and a third path from the ending point to the network node of the ending point secondary region in the ending point secondary region; the first path, the second path and the third path are respectively the shortest paths between two corresponding points;
calculating the shortest path from the starting point to the end point according to the first path, the second path and the third path;
wherein the shortest path calculation is performed on the first path by using Dijkstra algorithm;
the shortest path calculation step of the second path includes:
acquiring a first intersection point of the first path and the starting point secondary area, a network node in the starting point secondary area and the starting point;
constructing a triangle with the first path and a first intersection point of the starting point secondary region, a network node in the starting point secondary region and the starting point as vertexes, and determining a path from the starting point to the first intersection point as the second path;
the calculating of the third path comprises:
acquiring a second intersection point of the first path and the destination sub-area, a network node in the destination sub-area and the destination;
and constructing a second intersection point of the first path and the secondary end point area, a network node in the secondary end point area and a triangle with the end point as a vertex, and determining that a path from the end point to the second intersection point is the third path.
2. An apparatus for indoor spatial shortest path computation, the apparatus comprising:
the network node setting module is used for setting network nodes according to indoor space layout and barrier distribution; wherein the network node is arranged at a spatial variation point;
a dividing module for dividing the indoor space into a plurality of sub-regions; the secondary region comprises at least one network node, and any point in the secondary region can be directly connected to the network node in the secondary region through one to two rows or columns;
the acquisition module is used for acquiring a starting point sub-area and an end point sub-area where a starting point and an end point are respectively located;
the first intersection point used for obtaining the first path and the starting point secondary area, the network node in the starting point secondary area and the starting point;
the second intersection point used for obtaining the first path and the terminal secondary area, the network node in the terminal secondary area and the terminal;
a path determining module, configured to determine, according to the starting point secondary region and the ending point secondary region, a first path between a network node of the starting point secondary region and a network node of the ending point secondary region, a second path between the starting point in the starting point secondary region and a network node of the starting point secondary region, and a third path between the ending point in the ending point secondary region and a network node of the ending point secondary region; the first path, the second path and the third path are respectively the shortest paths between two corresponding points;
the calculation module is used for calculating the shortest path from the starting point to the end point according to the first path, the second path and the third path; for performing a shortest path calculation on the first path by using Dijkstra algorithm; a shortest path calculation for the second path and the third path; the computing module further comprises a construction module and a labeling module;
the construction module is configured to construct a triangle with the first intersection of the first path and the starting point secondary region, the network node in the starting point secondary region, and the starting point as a vertex, and determine that a path from the starting point to the first intersection is the second path; a second intersection point of the first path and the secondary end point area, a network node in the secondary end point area, and a triangle with the end point as a vertex are constructed, and a path from the end point to the second intersection point is determined as the third path;
the labeling module is used for positioning the positions in the indoor space by forming a plurality of continuous equal grids, so that all the positions of the indoor space can be labeled by the row and column coding of the grids.
3. A terminal device comprising a processor, a memory, and a computer program stored in the memory and configured to be executed by the processor, the processor implementing the indoor space shortest path calculation method of claim 1 when executing the computer program.
4. A computer-readable storage medium, comprising a stored computer program, wherein the computer program, when executed, controls an apparatus at which the computer-readable storage medium is located to perform the indoor space shortest path calculation method according to claim 1.
CN201810495043.XA 2018-05-22 2018-05-22 Calculation method and device for shortest indoor space path, terminal equipment and storage medium Expired - Fee Related CN108665117B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810495043.XA CN108665117B (en) 2018-05-22 2018-05-22 Calculation method and device for shortest indoor space path, terminal equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810495043.XA CN108665117B (en) 2018-05-22 2018-05-22 Calculation method and device for shortest indoor space path, terminal equipment and storage medium

Publications (2)

Publication Number Publication Date
CN108665117A CN108665117A (en) 2018-10-16
CN108665117B true CN108665117B (en) 2021-03-12

Family

ID=63777505

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810495043.XA Expired - Fee Related CN108665117B (en) 2018-05-22 2018-05-22 Calculation method and device for shortest indoor space path, terminal equipment and storage medium

Country Status (1)

Country Link
CN (1) CN108665117B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111323015B (en) * 2018-12-17 2022-08-26 北京三快在线科技有限公司 Method and device for estimating travel information and electronic equipment
CN110012422A (en) * 2019-03-19 2019-07-12 华南理工大学 A kind of wireless sensor network mobile base station barrier-avoiding method in complicated region
CN110020470B (en) * 2019-03-27 2023-06-30 苏州华恒展览设计营造有限公司 Showcase moving method for layout planning in exhibition hall
CN111256722B (en) * 2020-02-28 2023-08-01 广东博智林机器人有限公司 Path planning method, device, equipment and storage medium
CN113469398A (en) * 2020-03-31 2021-10-01 广东博智林机器人有限公司 Path planning method and device, electronic equipment and storage medium
CN112161637B (en) * 2020-08-28 2022-07-29 深圳市跨越新科技有限公司 Bidirectional simulation-based freight car route planning method and system
CN113255971A (en) * 2021-05-07 2021-08-13 广东省科学院智能制造研究所 Shortest path planning method and device based on MapReduce, terminal equipment and storage medium
CN113465601A (en) * 2021-05-13 2021-10-01 上海师范大学 Indoor navigation based on visual path

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102521328A (en) * 2011-12-06 2012-06-27 上海京颐信息科技有限公司 Optimization method for track playback function in indoor positioning system
CN102725607A (en) * 2009-10-01 2012-10-10 高通股份有限公司 Routing graphs for buildings
CN105716613A (en) * 2016-04-07 2016-06-29 北京进化者机器人科技有限公司 Method for planning shortest path in robot obstacle avoidance
CN106197419A (en) * 2016-06-23 2016-12-07 北京建筑大学 Take barrier and the indoor navigation method of subspace subdivision and system into account

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7587274B2 (en) * 2006-03-14 2009-09-08 Sap Ag System and method for navigating a facility

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102725607A (en) * 2009-10-01 2012-10-10 高通股份有限公司 Routing graphs for buildings
CN102521328A (en) * 2011-12-06 2012-06-27 上海京颐信息科技有限公司 Optimization method for track playback function in indoor positioning system
CN105716613A (en) * 2016-04-07 2016-06-29 北京进化者机器人科技有限公司 Method for planning shortest path in robot obstacle avoidance
CN106197419A (en) * 2016-06-23 2016-12-07 北京建筑大学 Take barrier and the indoor navigation method of subspace subdivision and system into account

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Dijkstra算法在室内移动导航最短路径寻址的改进;黄艺坤;《福建师范大学学报(自然科学版)》;20170531;第33卷(第3期);第13-18页、图1-图3 *
室内离散格网空间Dijkstra最短路径算法优化;张爱国;《厦门理工学院学报》;20181031;第26卷(第5期);第36-43、67页 *

Also Published As

Publication number Publication date
CN108665117A (en) 2018-10-16

Similar Documents

Publication Publication Date Title
CN108665117B (en) Calculation method and device for shortest indoor space path, terminal equipment and storage medium
CN102346795B (en) Automatic quick wiring method for electric and electronic virtual experiments
CN111750862A (en) Multi-region-based robot path planning method, robot and terminal equipment
CN107367278A (en) A kind of indoor navigation method and equipment
CN109668561B (en) Indoor path planning method, terminal and readable storage medium
Pelechano et al. Hierarchical path-finding for Navigation Meshes (HNA⁎)
CN108268039A (en) The paths planning method and system of mobile robot
EP1754955A1 (en) Navigation method and corresponding system for determining a travel related time
CN107390700B (en) Dynamic mapping method and chip for robot
KR20220034748A (en) Vehicle track planning method, device, computer device and computer-readable storage medium
CN110967028A (en) Navigation map construction method and device, robot and storage medium
CN111080786A (en) BIM-based indoor map model construction method and device
CN110909961A (en) BIM-based indoor path query method and device
CN105352506B (en) Indoor railway network planning method and device
Malik et al. Agent-based modelling for urban sprawl in the region of Waterloo, Ontario, Canada
CN109460564B (en) Power grid tidal current graph wiring method
CN116625378B (en) Cross-regional path planning method and system and storage medium
De Berg et al. Shortest path queries in rectilinear worlds
CN115063175A (en) Shop service range defining method, system, computer device and storage medium
CN112417070B (en) Road network topology construction method and device, electronic equipment and storage medium
CN115779424A (en) Navigation grid path finding method, device, equipment and medium
CN115657166A (en) Method and device for determining weather forecast value across multiple climate areas
CN113970321A (en) Method and device for calculating house type dynamic line
CN109726895B (en) Multi-target-point task execution planning method and device
CN114186306A (en) Customizable reinforcement learning for post placement in structural design

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
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20210312