Logistics network updating method and device
By constructing a shortest path tree in the logistics network and identifying associated transportation nodes, the shortest path is re-found, solving the problem of low update efficiency in the existing logistics network and achieving more efficient and real-time network updates.
Patent Information
- Application Number
- CN202310538143.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-12
- Publication Date
- 2024-11-12
AI Technical Summary
Existing logistics network update methods are inefficient and computationally complex when transportation nodes or routes change, affecting real-time performance and user experience.
Construct the shortest path tree of the logistics network, identify associated transportation nodes, and re-find the shortest path based on these nodes to locally update the logistics network.
It reduces computational complexity, improves the real-time performance and accuracy of logistics network updates, and saves computing resources.
Smart Images

Figure CN118941176A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of smart logistics technology, and in particular to a logistics network updating method and device. Background Art
[0002] With the development of Internet e-commerce, the scale of logistics networks including transportation nodes and transportation routes is getting larger and larger, and the corresponding complexity of logistics networks is also increasing. In the continuous changes in logistics business, it is often necessary to adjust the transportation nodes or transportation routes in the logistics network.
[0003] When the logistics network needs to be changed, the existing processing method usually recalculates all transportation paths of the starting transportation node related to the change, all intermediate transportation nodes related to the change, and the logistics terminal node related to the change in the logistics network; when the changes in the logistics network or transportation paths are relatively small, the existing methods have the problems of low efficiency and waste of computing resources, which affects the real-time nature of the logistics network update and user experience. Summary of the invention
[0004] In view of this, an embodiment of the present invention provides a logistics network updating method and device, which can use the shortest path tree constructed by the logistics network to determine the associated transportation nodes associated with the changed transportation nodes when the transportation reference indicator status between the transportation nodes changes, and re-search the shortest path based on the associated transportation nodes to update the transportation paths included in the logistics network; the embodiment of the present invention reduces the computational complexity of determining the shortest path to a large extent through local calculation of logistics network changes, saves computing resources, and improves the real-time, accuracy and efficiency of logistics network updates.
[0005] To achieve the above-mentioned purpose, according to one aspect of an embodiment of the present invention, a logistics network updating method is provided, characterized in that it includes: constructing one or more shortest path trees covering each transportation node included in the logistics network for the logistics network; in response to a change in the transportation reference index status between any two or more of the transportation nodes, determining one or more associated transportation nodes directly or indirectly associated with the changed transportation status from the shortest path tree; re-searching the shortest path for the associated transportation node based on the transportation relationship between the multiple transportation nodes, the transportation reference index corresponding to the transportation relationship and the changed transportation status; and updating the transportation path included in the logistics network based on the found shortest path of the associated transportation node.
[0006] Optionally, the logistics network updating method further includes: obtaining multiple transportation nodes included in the logistics network and the transportation relationships between the multiple transportation nodes and transportation reference indicators corresponding to the transportation relationships; based on the transportation relationships between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relationships, executing the step of constructing one or more shortest path trees covering each of the transportation nodes for the logistics network.
[0007] Optionally, the logistics network updating method further includes: obtaining multiple transportation nodes and the transportation relationships between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relationships from historical logistics information; generating corresponding data nodes for each of the transportation nodes; constructing directed edges between each of the data nodes according to the transportation relationships between the transportation nodes and the transportation reference indicators corresponding to the transportation relationships, and each of the data nodes and the directed edges constructs a network topology graph corresponding to the logistics network; the obtaining of the multiple transportation nodes included in the logistics network and the transportation relationships between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relationships includes: obtaining the multiple transportation nodes included in the logistics network and the transportation relationships between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relationships from the network topology graph.
[0008] Optionally, constructing one or more shortest path trees covering each of the transportation nodes for the logistics network includes: using a preset shortest path model to search and construct one or more shortest path trees covering each transportation node in the network topology graph.
[0009] Optionally, determining one or more associated transport nodes directly or indirectly associated with the changed transport condition from the shortest path tree includes: determining one or more first associated transport nodes directly associated with the changed transport condition; taking the first associated transport node as a starting point, and searching the shortest path tree for a second associated transport node directly or indirectly associated with the first associated transport node in the direction of the shortest path included in the shortest path tree.
[0010] Optionally, the re-searching the shortest path for the associated transport node includes: taking each associated transport node directly associated with the changed transport condition as a first associated transport node, and performing the following operations: separating a sub-path tree with the first associated transport node as the starting point from the shortest path tree to which the first associated transport node belongs; and re-searching the shortest path for one or more associated transport nodes included in the sub-path tree.
[0011] Optionally, re-searching the shortest path for one or more associated transport nodes included in the sub-path tree includes: searching for edge nodes in the sub-path tree based on the acquired transport relationship between the multiple transport nodes included in the logistics network, wherein the edge node is directly associated with other transport nodes that are not affected by the changed transport conditions; calculating the shortest path of the edge node based on the changed transport conditions, the acquired transport relationship between the multiple transport nodes included in the logistics network, the transport reference index corresponding to the transport relationship, and the starting transport node of the path tree to which the edge node belongs; and constructing the shortest path of the internal nodes in the sub-path tree except the edge node based on the shortest path of the edge node.
[0012] Optionally, the logistics network updating method further includes: constructing a priority path queue for the shortest path tree; for each shortest path included in the shortest path tree, performing the following operations: storing each transportation node included in the determined shortest path, the transportation relationship between the transportation nodes, and the transportation reference index corresponding to the transportation relationship into the priority path queue, so as to manage the transportation paths included in the logistics network through the priority path queue.
[0013] Optionally, the re-searching the shortest path for the associated transport node includes: determining multiple parent transport nodes associated with the associated transport node based on the transport relationship between the multiple transport nodes; obtaining the path reference index of the sub-path between the starting transport node and the parent transport node based on the transport relationship and corresponding transport reference index stored in the priority path queue including the parent transport node; calculating the path reference index of multiple candidate paths corresponding to the associated transport node based on the path reference index of the sub-path and the transport reference index between each of the parent transport node and the associated transport node; and determining the candidate path with the smallest path reference index as the shortest path of the associated transport node.
[0014] To achieve the above-mentioned purpose, according to a second aspect of an embodiment of the present invention, a logistics network updating device is provided, characterized in that it includes: a path tree building module, an associated node determination module and a network updating module; wherein,
[0015] The path tree construction module is used to construct one or more shortest path trees covering each transportation node included in the logistics network for the logistics network;
[0016] The associated node determination module is configured to determine, in response to a change in the transport reference index status between any two or more of the transport nodes, one or more associated transport nodes directly or indirectly associated with the changed transport status from the shortest path tree;
[0017] The network update module is used to re-search the shortest path for the associated transportation nodes based on the transportation relationship between the multiple transportation nodes, the transportation reference indicators corresponding to the transportation relationship and the changed transportation conditions; and update the transportation path included in the logistics network based on the shortest path of the associated transportation node found.
[0018] Optionally, the logistics network updating device is also used to obtain multiple transportation nodes included in the logistics network, the transportation relationships between the multiple transportation nodes, and the transportation reference indicators corresponding to the transportation relationships; based on the transportation relationships between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relationships, execute the step of constructing one or more shortest path trees covering each of the transportation nodes for the logistics network.
[0019] Optionally, the logistics network updating device is also used to obtain multiple transportation nodes and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations from historical logistics information; generate a corresponding data node for each of the transportation nodes; construct directed edges between each of the data nodes according to the transportation relations between the transportation nodes and the transportation reference indicators corresponding to the transportation relations, and each of the data nodes and the directed edges constructs a network topology graph corresponding to the logistics network; the acquisition of the multiple transportation nodes included in the logistics network and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations includes: obtaining the multiple transportation nodes included in the logistics network and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations from the network topology graph.
[0020] Optionally, the logistics network updating device is used to construct one or more shortest path trees covering each of the transportation nodes for the logistics network, including: using a preset shortest path model to search and construct one or more shortest path trees covering each transportation node in the network topology map.
[0021] Optionally, the logistics network updating device is used to determine one or more associated transport nodes that are directly or indirectly associated with the changed transport conditions from the shortest path tree, including: determining one or more first associated transport nodes that are directly associated with the changed transport conditions; taking the first associated transport node as the starting point, and searching the shortest path tree for a second associated transport node that is directly or indirectly associated with the first associated transport node in the direction of the shortest path included in the shortest path tree.
[0022] Optionally, the logistics network updating device is used to re-search the shortest path for the associated transport node, including: taking each associated transport node directly associated with the changed transport condition as the first associated transport node, and performing the following operations: separating a sub-path tree with the first associated transport node as the starting point from the shortest path tree to which the first associated transport node belongs; and re-searching the shortest path for one or more associated transport nodes included in the sub-path tree.
[0023] Optionally, the logistics network updating device is used to re-search the shortest path for one or more associated transport nodes included in the sub-path tree, including: searching for edge nodes in the sub-path tree based on the acquired transport relationship between the multiple transport nodes included in the logistics network, wherein the edge node is directly associated with other transport nodes that are not affected by the changed transport conditions; calculating the shortest path of the edge node based on the changed transport conditions, the acquired transport relationship between the multiple transport nodes included in the logistics network, the transport reference index corresponding to the transport relationship, and the starting transport node of the path tree to which the edge node belongs; and constructing the shortest path of the internal nodes in the sub-path tree except the edge node based on the shortest path of the edge node.
[0024] Optionally, the logistics network updating device is also used to construct a priority path queue for the shortest path tree; for each shortest path included in the shortest path tree, the following operations are performed: each transportation node included in the determined shortest path, the transportation relationship between the transportation nodes, and the transportation reference index corresponding to the transportation relationship are stored in the priority path queue, so as to manage the transportation paths included in the logistics network through the priority path queue.
[0025] Optionally, the logistics network updating device is used to re-search the shortest path for the associated transport node, including: determining multiple parent transport nodes associated with the associated transport node based on the transport relationship between the multiple transport nodes; obtaining the path reference index of the sub-path between the starting transport node and the parent transport node based on the transport relationship and corresponding transport reference index stored in the priority path queue including the parent transport node; calculating the path reference index of multiple candidate paths corresponding to the associated transport node based on the path reference index of the sub-path and the transport reference index between each of the parent transport node and the associated transport node; and determining the candidate path with the smallest path reference index as the shortest path of the associated transport node.
[0026] To achieve the above-mentioned purpose, according to the third aspect of an embodiment of the present invention, there is provided an electronic device for updating a logistics network, characterized in that it comprises: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement any method described in the above-mentioned logistics network updating method.
[0027] To achieve the above-mentioned purpose, according to the fourth aspect of an embodiment of the present invention, a computer-readable medium is provided, on which a computer program is stored, characterized in that when the program is executed by a processor, a method as described in any one of the above-mentioned logistics network update methods is implemented.
[0028] An embodiment of the above invention has the following advantages or beneficial effects: when the transportation reference indicator status between transportation nodes changes, the shortest path tree constructed by the logistics network can be used to determine the associated transportation nodes associated with the changed transportation nodes, and the shortest path can be re-searched based on the associated transportation nodes to update the transportation paths included in the logistics network; the embodiment of the present invention reduces the computational complexity of determining the shortest path to a large extent through local calculations on the logistics network, saves computing resources, and improves the real-time, accuracy and efficiency of updating the logistics network.
[0029] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0030] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0031] Figure 1 It is a flow chart of a logistics network updating method provided by an embodiment of the present invention;
[0032] Figure 1A is a schematic diagram of a logistics topology diagram provided by an embodiment of the present invention;
[0033] Figure 1B is a schematic diagram of a shortest path tree provided by an embodiment of the present invention;
[0034] Figure 1C It is a schematic diagram of a change in a transportation reference indicator status between transportation nodes provided by an embodiment of the present invention;
[0035] Figure 1D It is a schematic diagram of another change in the transportation reference indicator status between transportation nodes provided by an embodiment of the present invention;
[0036] Figure 1Eis a schematic diagram of a determined associated transport node provided by an embodiment of the present invention;
[0037] Figure 1F It is a structural schematic diagram of a logistics network after change provided by an embodiment of the present invention;
[0038] Figure 2 It is a schematic diagram of a process of re-finding the shortest path provided by an embodiment of the present invention;
[0039] Figure 3 It is a schematic diagram of another flow chart of logistics network update provided by an embodiment of the present invention;
[0040] Figure 4 It is a structural schematic diagram of a logistics network updating device provided by an embodiment of the present invention;
[0041] Figure 5 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0042] Figure 6 It is a schematic diagram of the structure of a computer system of a terminal device or a server suitable for implementing an embodiment of the present invention. DETAILED DESCRIPTION
[0043] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0044] It should be noted that the collection, collection, updating, analysis, processing, use, transmission, storage and other aspects of user personal information involved in the technical solution of this disclosure are in compliance with the provisions of relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken for user personal information to prevent illegal access to user personal information data and maintain the security of user personal information, network security and national security.
[0045] When collectors display logistics information, we will use technical means to de-identify the data and desensitize the information to protect information security.
[0046] In order to count the usage of our products / services, we will aggregate, analyze and use the technically processed user data and share the processed statistical information with third parties. We will use secure encryption technology and other methods to ensure that the recipient of the information cannot re-identify a specific individual.
[0047] At present, in the process of logistics business processing, it is usually necessary to make local adjustments to the logistics network according to the distribution of cargo volume, network anomalies, etc., such as adding or removing sorting centers, adjusting the routes between sorting centers, etc. As the scale of the logistics network becomes larger and larger, the time consumed for each global real-time calculation gradually becomes longer, especially for the situation where the logistics network structure changes frequently. Since it is impossible to determine which other nodes are affected by the change of one or more logistics nodes, it is also impossible to determine the affected logistics paths. Therefore, the exhaustive method of recalculating and refreshing each path of the logistics network is currently inefficient and has a high computational complexity. For example, the computational complexity is O(n 3 ). This affects the efficiency and real-time performance of logistics calculations.
[0048] In view of this, if Figure 1 As shown, an embodiment of the present invention provides a method for updating a logistics network. The embodiment of the present invention adopts an incremental method, that is, by constructing one or more shortest path trees with vertices as starting points, when the logistics network structure changes, by dynamically identifying the associated transportation nodes affected by the change, and updating the local network in real time, the computational complexity is reduced. For example, the computational complexity can be reduced to O(1), the computational performance is improved, and computational resources are saved. Specifically, the method may include the following steps:
[0049] Step S101: construct one or more shortest path trees for a logistics network, covering each transportation node included in the logistics network.
[0050] Specifically, in the logistics business, there are multiple transportation nodes and the transportation relationships between the transportation nodes that constitute the logistics network, and the logistics network may also include transportation reference indicators corresponding to the transportation relationships; wherein, the transportation nodes may include multiple types, such as item provider nodes, item recipient nodes, intermediate transportation nodes, etc.; in an embodiment of the present invention, various types of nodes involved in logistics or transportation are described by transportation nodes; the transportation reference indicators may be the transportation time, transportation costs, etc. between two or more transportation nodes; for example: the item is transported from transportation node A to transportation node B, then transportation node A and transportation node B have a transportation relationship, and the transportation time for the item to be transported from transportation node A to transportation node B is 9 hours (or the transportation cost is n, etc.), which is the transportation reference indicator corresponding to the transportation from transportation node A to transportation node B. By targeting the historical logistics data, the identification of each transportation node, the transportation relationship between transportation nodes, the transportation reference indicators corresponding to the transportation relationship, etc. can be obtained.
[0051] Furthermore, one or more shortest path trees covering each transport node included in the logistics network are constructed for the logistics network.
[0052] For example: multiple transportation nodes are obtained from logistics data, and the multiple transportation nodes are represented as: s, d, h, m, l, c, g, k, p, b, f, e, j, n, i, o; the transportation relationship between the transportation nodes is, for example: s->d, d->h, s->b...i->n, etc., where s->d means that one or more items are transported from transportation node s to transportation node d, and the transportation time required to transport from transportation node s to transportation node d is 3 hours (i.e., transportation reference indicator), and so on; it can be understood that any transportation node can have a transportation relationship with one or more other transportation nodes and transportation reference indicators associated with the transportation relationship (for example: transportation time, transportation cost, etc.).
[0053] In an embodiment of the present invention, there are two methods for constructing one or more shortest path trees covering each transport node included in the logistics network:
[0054] The first method: obtaining multiple transportation nodes and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations from the historical logistics data; executing the step of constructing one or more shortest path trees covering each of the transportation nodes for the logistics network according to the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations. Specifically, in this method, based on the acquired historical logistics data, one or more shortest path trees can be constructed directly based on the transportation nodes contained in the data and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations, using the Dijkstra model, Bellman-Ford model, Floyd-Warshall model, etc.
[0055] The second method is to obtain multiple transportation nodes, transportation relationships between the multiple transportation nodes and transportation reference indicators corresponding to the transportation relationships from historical logistics information, construct a network topology diagram corresponding to the logistics network, and further construct one or more shortest path trees based on the network topology diagram.
[0056] Figure 1A The schematic diagram of the structure of a network topology diagram corresponding to a logistics network is shown. Among them, s, d, h, m, l, c, g, k, p, b, f, e, j, n, i, o represent transportation nodes, the directed edge between s-> d represents the transportation relationship (such as transportation direction and other information), and the corresponding transportation reference index between s-> d (such as the number 7 represents the transportation time, or transportation cost, etc.). It can be seen that the network topology diagram can cover every transportation node in the logistics network, the transportation relationship between the transportation nodes, and the transportation reference index associated with the transportation relationship.
[0057] In an embodiment of the present invention, Figure 1A The transport nodes in are represented by letters (e.g., s, d, h, m, l, c, g, k, p, b, f, e, j, n, i, o); Figure 1B , Figure 1C , Figure 1D , Figure 1E , Figure 1F The transport nodes in are represented by numbers. Figure 1B , Figure 1C , Figure 1D , Figure 1E , Figure 1F The numbers of the nodes in the diagram correspond to the letters of the transport nodes through the transport reference index, for example: Figure 1A The transport node s corresponds to Figure 1B 0 in , 0 is a transportation reference indicator, for example, it means the transportation time is 0, and s is the root node; Figure 1A The transport node d corresponds to Figure 1B Node 7 in the figure represents the transportation reference index between the root node and the transportation node d; Figure 1A The transport node h corresponds to Figure 1B The node 10 in , 10 represents the transportation reference index from the root node to the transportation node h is 10; and so on, correspondingly, Figure 1C , Figure 1D It is understood that when the transport reference index between one or more transport nodes changes, the number corresponding to the transport node changes accordingly, such as Figure 1E , Figure 1F In the description of the present invention, it should be noted that the same transport node with a corresponding relationship can be described by letters or numbers.
[0058] Furthermore, based on the constructed network topology, a preset shortest path model is used to search and construct one or more shortest path trees covering each transport node in the network topology. It is understandable that by using different transport nodes as initial nodes (i.e., root nodes), shortest path trees of different structures can be constructed.
[0059] In an embodiment of the present invention, Figure 1A In the example shown, s is used as the root node, that is, multiple shortest paths determined for a certain transport node (transport node s) as the starting node are combined into a shortest path tree; corresponding to Figure 1A , Figure 1B FIG. 1 shows a schematic diagram of a shortest path tree constructed based on a network topology diagram with s as the root node. Figure 1B As shown, Figure 1AThe transport node identifier in is replaced by the calculation result based on the transport reference index, and a preset shortest path model is used (for example, using the single-source shortest path search algorithm Dijkstra algorithm) to determine multiple shortest paths. The multiple shortest paths cover all the transport nodes (i.e., data nodes) included in the logistics network. The multiple shortest paths belong to the shortest path tree, i.e., one or more shortest path trees covering each transport node; as shown in 1B, for example, 0->7->10->28 is a shortest path, and the corresponding transport nodes and transport relations are: s->d->h->m; for another example: 0->4->10 is another shortest path, and the corresponding transport nodes and transport relations are: s->b->e; other shortest paths such as Figure 1B Indicated by the bold arrow; the number on the arrow indicates the transportation reference index (transportation time or transportation cost, etc.). It can be understood that different shortest path trees can be constructed by taking different transportation nodes as root nodes. Figure 1B The shortest path tree shown is constructed with the transport node s as the root node, that is, one or more shortest path trees covering each of the transport nodes are constructed for the logistics network, including: using a preset shortest path model to search and construct one or more shortest path trees covering each transport node in the network topology graph.
[0060] Furthermore, each shortest path tree may be stored in a data format of storing a root node and adjacent child nodes corresponding to the root node through a tree-structured data structure, for example, in a memory.
[0061] The method is: obtaining multiple transportation nodes and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations from historical logistics information; generating a data node corresponding to each of the transportation nodes; constructing directed edges between each of the data nodes according to the transportation relations between the transportation nodes and the transportation reference indicators corresponding to the transportation relations, and each of the data nodes and the directed edges constructs a network topology graph corresponding to the logistics network; the obtaining of the multiple transportation nodes included in the logistics network and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations comprises: obtaining the multiple transportation nodes included in the logistics network and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations from the network topology graph.
[0062] Step S102: In response to a change in the transport reference indicator status between any two or more of the transport nodes, one or more associated transport nodes directly or indirectly associated with the changed transport status are determined from the shortest path tree.
[0063] Specifically, in application scenarios or logistics business, there is usually a need to change the transportation reference indicators between transportation nodes. For example, due to changes in transportation methods, changes in geographical conditions, etc., the transportation time or transportation costs of two or more transportation nodes change. It is understandable that when the transportation reference indicators between transportation nodes change, it is necessary to recalculate and determine one or more associated optimal logistics paths.
[0064] In an embodiment of the present invention, the associated optimal logistics path may be further recalculated by determining one or more associated transportation nodes directly or indirectly associated with the changed transportation status from the shortest path tree.
[0065] Further, determining one or more associated transport nodes directly or indirectly associated with the changed transport condition from the shortest path tree includes: determining one or more first associated transport nodes directly associated with the changed transport condition; taking the first associated transport node as a starting point, searching the shortest path tree for a second associated transport node directly or indirectly associated with the first associated transport node in the shortest path tree in the direction of the shortest path included in the shortest path tree.
[0066] The following describes a method for determining one or more associated transport nodes that are directly or indirectly associated with the changed transport status:
[0067] 1) Figure 1A , Figure 1C For example, suppose Figure 1A The transportation reference index (such as transportation time) between the transportation nodes c and g shown in has changed, such as Figure 1A , Figure 1C As shown, for example, if the transportation reference index (such as transportation time) between transportation nodes c and g changes from 7 to 9 (7+2), then one or more first associated transportation nodes directly associated with the changed transportation status are determined to be Figure 1A The transport node g in Figure 1C Transport node 9 in.
[0068] Further, in one embodiment of the present invention, the directed topology graph (such as Figure 1A As shown in the figure), taking the first associated transportation node as the starting point, according to the direction and transportation relationship included in the directed topological graph, determining the second associated transportation node directly or indirectly associated with the first associated transportation node; preferably, in another embodiment of the present invention, taking the first associated transportation node as the starting point, according to the direction of the shortest path included in the shortest path tree, searching for the second associated transportation node directly or indirectly associated with the first associated transportation node in the shortest path tree, according to the direction of the shortest path included in the shortest path tree, Figure 1C From the example of transport node 9 (i.e. Figure 1A The multiple shortest path trees where the transport node g) is located are represented as: 0->2->9->13->26, 0->2->9->13->24, 0->2->9->17->20, 0->2->9->17->21; then taking the first associated transport node (i.e., transport node 9) as the starting point, searching for the second associated transport node directly or indirectly associated with the first associated transport node according to the direction of the shortest path included in the shortest path tree (e.g., 0->2->9->13->26, etc.), then Figure 1C As shown, the searched second associated transport nodes directly or indirectly associated with the first associated transport node can be: 13, 17, 26, 24, 21, 20, etc. After determining the first associated transport node and the corresponding second associated transport node, the subsequent operation of re-determining the logistics path is performed. Among them, direct association is a direct transportation relationship, for example: 9->17, then transport node 9 and transport node 17 are directly associated, and indirect association is a transportation relationship established through other transport nodes, for example: 9->17->20, then transport node 9 and transport node 20 are indirectly associated.
[0069] 2) Figure 1A , Figure 1D For example, suppose that the transportation reference index (such as transportation time) between transportation nodes c and g has changed, and the transportation reference index (such as transportation time) between transportation nodes g and j has also changed, such as Figure 1A , Figure 1D As shown, for example: the transportation reference index (such as transportation time) between transportation nodes c and g has changed from 7 to 9 (7+2); the transportation reference index (such as transportation time) between transportation nodes g and j has also changed from 8 to 11 (8+3), then one or more first associated transportation nodes directly associated with the changed transportation status are Figure 1A The transport nodes g and j in Figure 1D Transport node 9 and transport node 17 in the.
[0070] Further, according to the directed topological graph (such as Figure 1A As shown in the figure), taking the first associated transport node as the starting point, according to the direction and transport relationship included in the directed topological graph, determining the second associated transport node directly or indirectly associated with the first associated transport node; preferably, taking the first associated transport node as the starting point, according to the direction of the shortest path included in the shortest path tree, searching for the second associated transport node directly or indirectly associated with the first associated transport node in the shortest path tree, and according to Figure 1D From the example of transport node 9 (i.e. Figure 1AThe multiple shortest path trees where the transport node g) is located are represented as: 0->2->9->13->26, 0->2->9->13->24, 0->2->9->17->20, 0->2->9->17->21; among them, the transport node 17 (i.e. Figure 1A The multiple shortest path trees where the transport node j) is located are represented as: 0->2->9->17->20, 0->2->9->17->21; then taking the first associated transport node (i.e., transport node 9, transport node 17) as the starting point, searching for the second associated transport node directly or indirectly associated with the first associated transport node according to the direction of the shortest path included in the shortest path tree, then Figure 1D As shown, the searched second associated transport nodes may be: 13, 26, 24, 21, 20, etc. After the first associated transport node and the corresponding second associated transport node are determined, the subsequent operation of redetermining the logistics path is performed.
[0071] Step S103: re-search the shortest path for the associated transport node based on the transport relationship between the plurality of transport nodes, the transport reference index corresponding to the transport relationship and the changed transport status; and update the transport path included in the logistics network based on the found shortest path for the associated transport node.
[0072] Specifically, in the embodiment of the present invention, there are two methods for re-finding the shortest path for the associated transport node whose transport status has changed:
[0073] The first method: Based on Figure 1 The specific circumstances of the change in the transportation status shown, or Figure 1D The specific circumstances of the change in the transportation status shown can be based on Figure 1C or Figure 1D For each shortest path in the included logistics network, the value of the new transport reference index (such as transport time, etc.) after the change is determined by calculation and comparison, so as to determine the shortest path from multiple paths based on the new transport reference index for the associated transport nodes whose transport conditions have changed.
[0074] Preferably, the second method: utilizes the construction of multiple sub-path trees to re-search the shortest path for the associated transport node. Specifically, utilizes a shortest path tree to construct multiple sub-path trees according to the transport relationship between the multiple transport nodes, the transport reference indicators corresponding to the transport relationship, and the changed transport conditions; and re-searches the shortest path through each sub-path tree. That is, the re-searching of the shortest path for the associated transport node includes: taking each associated transport node directly associated with the changed transport condition as the first associated transport node, and performing the following operations: from the shortest path tree to which the first associated transport node belongs, separating the sub-path tree with the first associated transport node as the starting point; and re-searching the shortest path for one or more associated transport nodes included in the sub-path tree. Specifically, as Figure 1C As shown, Figure 1C The sub-path tree separated from the transport node 9 is constructed starting from the transport node 9. The sub-path tree includes each transport node within the dotted line range. Figure 1C as shown; Figure 1D As shown, Figure 1D The sub-path trees separated from the transport node 9 include: the sub-path tree formed with the transport node 9 as the starting point, and the sub-path tree formed with the transport node 17 as the starting point. Each sub-path tree includes each transport node within the dotted line range, such as Figure 1D shown.
[0075] Furthermore, the shortest path is searched again for one or more associated transport nodes included in the sub-path tree, including: searching for edge nodes in the sub-path tree according to the acquired transport relationship between the multiple transport nodes included in the logistics network, wherein the edge nodes are directly associated with other transport nodes that are not affected by the changed transport conditions; calculating the shortest path of the edge node according to the changed transport conditions, the acquired transport relationship between the multiple transport nodes included in the logistics network, the transport reference index corresponding to the transport relationship, and the starting transport node of the path tree to which the edge node belongs; and constructing the shortest path of the internal nodes in the sub-path tree except the edge node according to the shortest path of the edge node. Specifically, the method of searching for edge nodes in the sub-path tree is to Figure 1D Take the two subpath trees contained in this example as an example. Figure 1D As shown, Figure 1D The sub-path trees separated from the transport node 9 include: a sub-path tree starting from the transport node 9, and a sub-path tree starting from the transport node 17. Each sub-path tree includes each transport node within the dotted line range. Figure 1D As shown, the sub-path tree includes the transportation relationship between the transportation nodes. Further, according to the obtained transportation relationship between the multiple transportation nodes included in the logistics network, the edge node is searched in the sub-path tree.
[0076] In an embodiment of the present invention, edge nodes are directly associated with other transport nodes that are not affected by the changed transport conditions, for example: Figure 1D The edge nodes in the sub-path tree formed with transport node 9 as the starting point include: transport node 13 (corresponding to Figure 1A k in), transport node 26 (corresponding to Figure 1A p); wherein, in addition to having a direct transportation relationship with transportation node 9, transportation node 13 also has a direct transportation relationship with transportation node 10 (i.e., other transportation nodes that are not affected by the changed transportation conditions); in addition to having a direct transportation relationship with transportation node 13, transportation node 26 also has a direct transportation relationship with transportation node 28 (i.e., other transportation nodes that are not affected by the changed transportation conditions); therefore, transportation node 13 and transportation node 26 are edge nodes.
[0077] according to Figure 1D It can be seen that transport nodes 20 and 28 are transport nodes that are not affected by the changed transport status (the changed transport nodes include 9, 17 and other related transport nodes); it can be seen that transport node 13 is an edge node described in the embodiment of the present invention. Similarly, transport node 26 and transport node 21 in the subpath tree formed with transport node 17 as the starting point are also edge nodes; and transport node 24 (corresponding to Figure 1A o in), transport node 20 (corresponding to Figure 1A The transport nodes with direct transport relationships associated with n) in are nodes that are both affected by the transport conditions. Therefore, these two transport nodes are not edge nodes. In the embodiment of the present invention, internal nodes are used to describe this type of transport nodes. Figure 1E Shown based on Figure 1D A schematic diagram of each edge node and internal node identified.
[0078] Further, according to the changed transportation status, the transportation relationship between the multiple transportation nodes included in the logistics network, the transportation reference index corresponding to the transportation relationship, and the starting transportation node of the path tree to which the edge node belongs, the shortest path of the edge node is calculated; specifically, after the edge node is determined, the shortest path of the edge node is calculated, still based on Figure 1D For example, for the transport node 13 of the edge node (corresponding to Figure 1A k), the path tree to which edge node 13 belongs is as follows Figure 1DAs shown, in the entire logistics network (including the path tree), the path passing through the transport node 13 may include: path 1: 0->2->9->13:; path 2: 0->7->10->13; path 3: 0->4->9->13, etc.; then the transport reference index corresponding to each path is calculated according to the changed transport status, the transport relationship between the multiple transport nodes included in the logistics network, the transport reference index corresponding to the transport relationship, and the starting transport node of the path tree to which the edge node belongs. For example: according to the changed transport reference index, it is calculated that: the transport reference index of the path corresponding to path 1 is 15; the transport reference index of the path of path 2 is 13; the transport reference index of the path of path 3 is 20; it can be seen that the total transport reference index of path 2 is the smallest, then path 2 is determined to be the shortest path of the edge node (that is, transport node 13). It can be understood that before the transport status is changed, such as Figure 1D As shown, transport node 13 (corresponding to Figure 1A The shortest path of k) is 0->2->9->13 (i.e., path 1). That is, it can be seen that in the case where the shortest path of the transport node 13 changes, the shortest path of the edge node is re-determined.
[0079] Further, according to the shortest path of the edge node, the shortest path of the internal nodes in the sub-path tree except the edge node is constructed; specifically, after determining the shortest path of the edge node, further, according to the association relationship between the internal node and the edge node, the shortest path for the internal node is determined. Figure 1E As shown, after the shortest paths are constructed for transport nodes 13 and 20, the shortest path can be constructed for transport node 24 (i.e., a path with a smaller path reference index is selected from 13->24 or 20->24); further, the steps of determining the shortest path after the change of the transport status for each edge node and internal node are executed in a loop.
[0080] Furthermore, the transportation paths included in the logistics network are updated according to the shortest paths of the associated transportation nodes found; after the shortest paths are calculated for all associated transportation nodes, the transportation paths included in the original logistics network are updated, that is, the original one or more shortest paths are updated. Figure 1F FIG. 1 shows a schematic diagram of a logistics network after a change provided by an embodiment of the present invention (specifically, a change in the transportation reference index between transportation nodes cg and gj). Figure 1F The changed transport nodes and corresponding transport reference indicators are shown. Figure 1F By comparing the transportation status before and after the change Figure 1B The logistics network shown, combined with specific changes in transportation conditions (such as Figure 1DAs shown), a new logistics network after the transportation status is changed is obtained. Further, the updated logistics network and the shortest paths included therein are sent to the logistics management party; thus, it can be seen that the embodiment of the present invention improves the accuracy and efficiency of determining the shortest path after the transportation change through the method of steps S101 to S103, thereby improving the user experience.
[0081] like Figure 2 As shown, an embodiment of the present invention provides a method for re-finding the shortest path, which may include the following steps:
[0082] Step S201: Acquire multiple transportation nodes and the transportation relationships between the multiple transportation nodes and transportation reference indicators corresponding to the transportation relationships from historical logistics information; generate data nodes corresponding to each of the transportation nodes; construct directed edges between each of the data nodes according to the transportation relationships between the transportation nodes and the transportation reference indicators corresponding to the transportation relationships, and each of the data nodes and the directed edges constructs a network topology graph corresponding to the logistics network.
[0083] Step S202: Acquire from the network topology diagram a plurality of transport nodes included in the logistics network, transport relations between the plurality of transport nodes, and transport reference indicators corresponding to the transport relations.
[0084] Step S203: using a preset shortest path model, searching and constructing one or more shortest path trees covering each transport node in the network topology graph.
[0085] Specifically, steps S201 to S203 describe the process of using logistics information to construct a network topology diagram of logistics, and constructing a shortest path tree based on the network topology diagram. The specific description is consistent with the description of step S101, and will not be repeated here. That is, multiple transportation nodes and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations are obtained from historical logistics information; data nodes corresponding to each of the transportation nodes are generated; directed edges are constructed between each of the data nodes according to the transportation relations between the transportation nodes and the transportation reference indicators corresponding to the transportation relations, and each of the data nodes and the directed edges construct a network topology diagram corresponding to the logistics network; the acquisition of the multiple transportation nodes included in the logistics network and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations includes: obtaining the multiple transportation nodes included in the logistics network and the transportation relations between the multiple transportation nodes and the transportation reference indicators corresponding to the transportation relations from the network topology diagram. The method of constructing one or more shortest path trees covering each of the transport nodes for the logistics network includes: using a preset shortest path model to search and construct one or more shortest path trees covering each of the transport nodes in the network topology graph.
[0086] Step S204: In response to a change in the transport reference indicator status between any two or more of the transport nodes, one or more associated transport nodes directly or indirectly associated with the changed transport status are determined from the shortest path tree.
[0087] Step S205: re-searching the shortest path for the associated transportation nodes according to the transportation relationship between the plurality of transportation nodes, the transportation reference index corresponding to the transportation relationship, and the changed transportation status.
[0088] Specifically, the description of step S204 to step S205 is consistent with the description of step S102 to step S103, and will not be repeated here.
[0089] like Figure 3 As shown, an embodiment of the present invention provides a process for updating a logistics network, which may include the following steps:
[0090] Step S301: For each shortest path included in the shortest path tree, perform the following operations: store each transport node included in the determined shortest path, the transport relationship between the transport nodes, and the transport reference index corresponding to the transport relationship into the priority path queue, so as to manage the transport paths included in the logistics network through the priority path queue.
[0091] Preferably, an embodiment of the present invention also includes: constructing a priority path queue for the shortest path tree; that is, using the priority path queue to manage the transportation paths included in the logistics network; managing the transportation paths included in the logistics network includes calculating the total transportation reference index of the path based on the transportation nodes, transportation relationships, and transportation reference index data contained in the priority path queue, and optionally, the edge nodes can also be calculated through the transportation nodes, transportation relationships, and transportation reference index data stored in the priority path queue.
[0092] In an embodiment of the present invention, for example, each transport node (i.e., each element) in the priority path queue is stored in the format of <ver, data, key>, where: ver represents a transport node in the shortest path tree, data is other information of the transport node, for example: other information is the data of the parent transport node, and key represents the transport reference index (for example: transport time, transport cost, etc.) of the transport node through the shortest path to the root node (the root node in the shortest path tree); for example, Figure 1A For example, for transport node d, the corresponding data is <"d", "s, g", 7>, for transport node k, the corresponding data is <"k", "h, g", 13>, etc. Preferably, the key value can be sorted from small to large, so as to improve the efficiency of managing the transport paths included in the logistics network through the priority path queue; it can be understood that<ver,data,key> The format and specific content of the priority path queue are only examples, and the present invention does not limit the specific form and content of the priority path queue.
[0093] Furthermore, before determining the candidate path with the smallest path reference index or after determining the candidate path with the smallest path reference index, it also includes: constructing a candidate path for each of the associated transport nodes; storing the multiple candidate paths corresponding to the associated transport nodes and the path reference indexes in the priority path queue; the determination of the candidate path with the smallest path reference index as the shortest path of the associated transport node includes: retaining only the candidate path with the smallest path reference index in the priority path queue. Retaining only the candidate path with the smallest path reference index in the priority path queue; that is, updating the priority path queue corresponding to the shortest path tree; that is, managing the transport paths included in the logistics network includes: updating the priority path queue according to the determined shortest path. And updating the transport paths included in the logistics network based on the new priority path queue.
[0094] It can be seen that through the method of the embodiment of the present invention, after the shortest path is re-determined according to the change of transportation conditions, the transportation conditions corresponding to the logistics network can be updated by updating the priority path queue and the corresponding shortest path tree, thereby improving the efficiency of the logistics network update and reducing the computational complexity of the logistics network update.
[0095] Optionally, in an embodiment of the present invention, a node queue may be constructed for one or more associated transport nodes that are directly or indirectly associated with the changed transport status, so as to improve the management efficiency of the associated transport nodes. That is, after determining one or more associated transport nodes that are directly or indirectly associated with the changed transport status from the shortest path tree, it also includes: constructing a node queue, storing all the determined associated transport nodes in the node queue; after re-finding the shortest path for each associated transport node, deleting the associated transport node that has re-finded the shortest path from the node queue. For example, in combination with Figure 1A and Figure 1E , exemplarily, the determined associated transport nodes may include: g, k, j, i, p, o, n; wherein the associated transport nodes may be edge nodes or internal nodes, so that the step of re-finding the shortest path may be performed based on each node in the node queue, and after the shortest path is re-finded for each associated transport node, the associated transport node that has re-finded the shortest path is deleted from the node queue, and further, when the node queue does not contain any associated transport nodes, it is determined that the transport path included in the logistics network is updated. That is, by determining whether the node queue is empty, it is determined whether all associated nodes have been processed, that is, the transport path included in the logistics network is updated.
[0096] It can be seen that the management and query efficiency of associated transport nodes is improved through the node queue, and each associated node is determined to be processed through the node queue, so that the process of redetermining the shortest path for the associated transport nodes is executed through the node queue combined with the loop operation of the associated nodes; thereby determining that the transport path included in the logistics network is updated.
[0097] Step S302: acquiring a path reference index of a sub-path between a starting transport node and the parent transport node according to the transport relationship and the corresponding transport reference index stored in the priority path queue including the parent transport node.
[0098] Step S303: Calculate the path reference indices of multiple candidate paths corresponding to the associated transport node based on the path reference index of the sub-path and the transport reference index between each of the parent transport node and the associated transport node; determine the candidate path with the smallest path reference index as the shortest path of the associated transport node.
[0099] Specifically, according to the transportation relationship between the plurality of transportation nodes, a plurality of parent transportation nodes associated with the associated transportation node are determined; according to the transportation relationship and the corresponding transportation reference index stored in the priority path queue including the parent transportation node, the path reference index of the sub-path between the starting transportation node and the parent transportation node is obtained; Figure 1D For example, the associated transport node is transport node 13 (corresponding to Figure 1A ), according to the transportation relationship between the transportation nodes, multiple parent transportation nodes associated with the associated transportation node are determined, for example, transportation node 9, transportation node 10, etc. It can be understood that when calculating the changed path, it is necessary to calculate from the root node (for example, transportation node 0, that is, the starting transportation node) as the starting point of the path, so it is necessary to obtain the value of the path reference index of the sub-path between the starting transportation node and the parent transportation node, so as to further calculate the entire path according to the sub-path; preferably, the data of the transportation node k can be obtained from the priority path queue, for example, according to the stored <"k", "h, g", 13>, its multiple parent transportation nodes (h, g) are obtained, so as to calculate different candidate paths corresponding to different parent transportation nodes; that is, according to the transportation relationship and the corresponding transportation reference index stored in the priority path queue including the parent transportation node, the path reference index of the sub-path between the starting transportation node and the parent transportation node is obtained. For example, for transport node 13 (i.e., transport node k), there are two candidate paths associated with its parent transport nodes (e.g., transport node h and transport node g), which are: 0->7->10, 0->2->9; further, according to the data corresponding to transport node h and transport node g in the priority path queue, the path reference indicators of the sub-paths between the starting transport node (i.e., root node s) and each parent transport node (e.g., transport node h, transport node g) are obtained, which are: 10 and 11, respectively, where 11 is the path reference indicator of the sub-path after the transport reference indicator between the two transport nodes cg is changed.
[0100] Further, according to the path reference index of the sub-path and the transportation reference index between each of the parent transportation nodes and the associated transportation node, the path reference indexes of multiple candidate paths corresponding to the associated transportation node are calculated. For example, for transportation node k, when the path reference indexes of two sub-paths (candidate paths) are calculated as 10 and 11, respectively, the path reference indexes of multiple candidate paths corresponding to the associated transportation node are further calculated according to the transportation reference index between each of the parent transportation nodes and the associated transportation node, such as Figure 1DAs shown, the calculated path reference indices are 13 (10+3) and 15 (11+4), respectively, so the path corresponding to 13 is determined as the new shortest path. It can be seen that the shortest path of the associated transport node can be determined by the minimum value of the path reference indices of multiple candidate paths, that is, the candidate path with the smallest path reference index is determined as the shortest path of the associated transport node. It can be understood that the associated transport node can be an edge node or an internal node.
[0101] The description of step S301-step S303 is that the re-searching the shortest path for the associated transport node includes: determining multiple parent transport nodes associated with the associated transport node based on the transport relationship between the multiple transport nodes; obtaining the path reference index of the sub-path between the starting transport node and the parent transport node based on the transport relationship and the corresponding transport reference index stored in the priority path queue including the parent transport node; calculating the path reference index of multiple candidate paths corresponding to the associated transport node based on the path reference index of the sub-path and the transport reference index between each of the parent transport node and the associated transport node; and determining the candidate path with the smallest path reference index as the shortest path of the associated transport node.
[0102] Optionally, steps S301 to S303 may also directly calculate various paths associated with the edge nodes through the transportation nodes, transportation relationships, and transportation reference indicators stored in the priority path queue.
[0103] Further, the method of using the priority path queue to add queue elements and pull queue elements to determine the shortest path for the edge node includes: calculating candidate paths for all edge nodes in the separated one or more sub-path trees respectively, the candidate paths are obtained by adding the shortest path between the parent transport nodes of the edge nodes and the changed transport reference index, adding the calculated candidate paths to the Minimum-Priority Queue, adding element method ENQUEUE(Q,<ver,data,key> )Add element method, the added data format is, for example,<a,candidate parent,candidate distance> ; If the element to be added already exists in the Queue, the element with a smaller key value is retained; for example: for transport node k, after the transport status changes, the element to be added is <"k", h, 13>, and the candidate path corresponding to transport node k is <"k", "h, g", 15>, then the element with the smallest key value is retained in the priority path queue, that is, the path corresponding to <"k", h, 13>, that is, it also includes: constructing a candidate path for each of the associated transport nodes; storing the multiple candidate paths corresponding to the associated transport nodes and the path reference indicators in the priority path queue; determining the candidate path with the smallest path reference index as the shortest path of the associated transport node includes: only retaining the candidate path with the smallest path reference index in the priority path queue.
[0104] Furthermore, the transport node corresponding to the minimum transport reference index, its parent transport node, and the shortest path obtained by accumulating multiple transport reference indexes are extracted from the priority path queue, which is the new shortest path of the transport node. Furthermore, the parent transport node and the shortest path of one or more child transport nodes directly associated with the transport node can be updated accordingly. Among them, the element extraction method EXTRACTMIN(Q) is to obtain the element corresponding to the minimum value of the transport reference index from the priority queue.
[0105] It can be seen that by using the priority queue to store information such as transport nodes, corresponding transport relationships (for example, including information such as corresponding parent transport nodes), corresponding transport reference indicators, etc., the efficiency of finding candidate paths for transport nodes, parent transport nodes, and associated transport nodes is improved, thereby improving the efficiency of re-determining new shortest paths for associated nodes where transport conditions have changed, and improving the efficiency of updating the logistics network.
[0106] like Figure 4 As shown, the embodiment of the present invention provides a logistics network updating device 400, including: a path tree building module 401, a related node determination module 402 and a network updating module 403; wherein,
[0107] The path tree construction module 401 is used to construct one or more shortest path trees covering each transportation node included in the logistics network for the logistics network;
[0108] The associated node determination module 402 is configured to determine, in response to a change in the transport reference index status between any two or more of the transport nodes, one or more associated transport nodes directly or indirectly associated with the changed transport status from the shortest path tree;
[0109] The updating network module 403 is used to re-search the shortest path for the associated transport nodes according to the transport relationship between the plurality of transport nodes, the transport reference index corresponding to the transport relationship and the changed transport conditions; and update the transport path included in the logistics network according to the shortest path of the associated transport node found.
[0110] An embodiment of the present invention also provides an electronic device for updating a logistics network, comprising: one or more processors; a storage device for storing one or more programs, and when the one or more programs are executed by the one or more processors, the one or more processors implement the method provided in any of the above embodiments.
[0111] An embodiment of the present invention further provides a computer-readable medium on which a computer program is stored. When the program is executed by a processor, the method provided in any of the above embodiments is implemented.
[0112] Figure 5 An exemplary system architecture 500 is shown to which the logistics network updating method or the logistics network updating device according to the embodiment of the present invention can be applied.
[0113] like Figure 5 As shown, system architecture 500 may include terminal devices 501, 502, 503, a network 504 and a server 505. Network 504 is used to provide a medium for communication links between terminal devices 501, 502, 503 and server 505. Network 504 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0114] Users can use terminal devices 501, 502, 503 to interact with server 505 through network 504 to receive or send messages, etc. Various client applications can be installed on terminal devices 501, 502, 503, such as e-commerce client applications, web browser applications, search applications, instant messaging tools, and email clients.
[0115] The terminal devices 501 , 502 , and 503 may be various electronic devices having a display screen and supporting various client applications, including but not limited to smart phones, tablet computers, laptop computers, desktop computers, and the like.
[0116] The server 505 may be a server that provides various services, such as a background management server that provides support for client applications used by users using the terminal devices 501, 502, and 503. The background management server may process the received information on changes in the transportation reference indicator status between any two or more of the transportation nodes, and feed back the transportation paths included in the updated logistics network to the terminal device.
[0117] It should be noted that the logistics network updating method provided in the embodiment of the present invention is generally executed by the server 505 , and accordingly, the logistics network updating device is generally arranged in the server 505 .
[0118] It should be understood that Figure 5 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0119] Reference below Figure 6 , which shows a schematic diagram of the structure of a computer system 600 of a terminal device suitable for implementing an embodiment of the present invention. Figure 6 The terminal device shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0120] like Figure 6 As shown, the computer system 600 includes a central processing unit (CPU) 601, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 602 or a program loaded from a storage part 608 into a random access memory (RAM) 603. In the RAM 603, various programs and data required for the operation of the system 600 are also stored. The CPU 601, the ROM 602, and the RAM 603 are connected to each other via a bus 604. An input / output (I / O) interface 605 is also connected to the bus 604.
[0121] The following components are connected to the I / O interface 605: an input section 606 including a keyboard, a mouse, etc.; an output section 607 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 608 including a hard disk, etc.; and a communication section 609 including a network interface card such as a LAN card, a modem, etc. The communication section 609 performs communication processing via a network such as the Internet. A drive 610 is also connected to the I / O interface 605 as needed. A removable medium 611, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 610 as needed, so that a computer program read therefrom is installed into the storage section 608 as needed.
[0122] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 609, and / or installed from the removable medium 611. When the computer program is executed by the central processing unit (CPU) 601, the above-mentioned functions defined in the system of the present invention are executed.
[0123] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0124] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0125] The modules and / or units involved in the embodiments of the present invention may be implemented in software or hardware. The modules and / or units described may also be provided in a processor. For example, they may be described as follows: a processor includes a module for constructing a path tree, a module for determining associated nodes, and a module for updating a network. The names of these modules do not, in some cases, constitute limitations on the modules themselves. For example, the module for constructing a path tree may also be described as a "module for constructing a shortest path tree for a logistics network."
[0126] As another aspect, the present invention also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device includes: constructing one or more shortest path trees covering each transportation node included in the logistics network for the logistics network; in response to a change in the transportation reference index status between any two or more of the transportation nodes, determining one or more associated transportation nodes directly or indirectly associated with the changed transportation status from the shortest path tree; based on the transportation relationship between the multiple transportation nodes, the transportation reference index corresponding to the transportation relationship, and the changed transportation status, re-searching the shortest path for the associated transportation node; and updating the transportation path included in the logistics network based on the shortest path of the associated transportation node found.
[0127] The embodiments of the present invention can, when the transportation reference indicator status between transportation nodes changes, use the shortest path tree constructed by the logistics network to determine the associated transportation nodes associated with the changed transportation nodes, and re-search the shortest path based on the associated transportation nodes to update the transportation paths included in the logistics network; the embodiments of the present invention can reduce the computational complexity of determining the shortest path to a large extent through local calculation of changes in the logistics network, save computing resources, and improve the real-time, accuracy and efficiency of updating the logistics network.
[0128] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A logistics network updating method, characterized in that: include: Constructing one or more shortest path trees for the logistics network covering each transportation node included in the logistics network; In response to a change in the transport reference indicator status between any two or more of the transport nodes, determining from the shortest path tree one or more associated transport nodes directly or indirectly associated with the changed transport status; Re-searching the shortest path for the associated transport nodes according to the transport relationship between the plurality of transport nodes, the transport reference index corresponding to the transport relationship, and the changed transport status; The transportation paths included in the logistics network are updated according to the found shortest paths of the associated transportation nodes.
2. The logistics network updating method according to claim 1, characterized in that: Also includes: Acquire a plurality of transport nodes included in the logistics network, a transport relationship between the plurality of transport nodes, and a transport reference index corresponding to the transport relationship; According to the transportation relationship between the plurality of transportation nodes and the transportation reference index corresponding to the transportation relationship, the step of constructing one or more shortest path trees covering each of the transportation nodes for the logistics network is performed.
3. The method according to claim 2, characterized in that Also includes: Acquire multiple transportation nodes, transportation relationships between the multiple transportation nodes, and transportation reference indicators corresponding to the transportation relationships from historical logistics information; Generating a corresponding data node for each of the transport nodes; According to the transport relationship between the transport nodes and the transport reference index corresponding to the transport relationship, a directed edge is constructed between each of the data nodes, and each of the data nodes and the directed edge constructs a network topology graph corresponding to the logistics network; The step of acquiring a plurality of transport nodes included in the logistics network, transport relationships between the plurality of transport nodes, and transport reference indicators corresponding to the transport relationships includes: A plurality of transport nodes included in the logistics network, transport relations between the plurality of transport nodes and transport reference indicators corresponding to the transport relations are obtained from the network topology diagram.
4. The method according to claim 3, characterized in that: The step of constructing one or more shortest path trees covering each of the transport nodes for the logistics network includes: Using a preset shortest path model, one or more shortest path trees covering each transport node are searched and constructed in the network topology graph.
5. The method according to claim 1, characterized in that: The determining, from the shortest path tree, one or more associated transport nodes directly or indirectly associated with the changed transport status includes: Determining one or more first associated transport nodes directly associated with the changed transport status; Taking the first associated transportation node as a starting point, searching the shortest path tree for a second associated transportation node that is directly or indirectly associated with the first associated transportation node in accordance with the direction of the shortest path included in the shortest path tree.
6. The method according to claim 1 or 5, characterized in that: The re-searching the shortest path for the associated transport node includes: Each associated transport node directly associated with the changed transport status is used as the first associated transport node, and the following operations are performed: Separating a sub-path tree with the first associated transport node as a starting point from the shortest path tree to which the first associated transport node belongs; Re-search the shortest path for one or more associated transport nodes included in the sub-path tree.
7. The method according to claim 6, characterized in that The re-searching the shortest path for one or more associated transport nodes included in the sub-path tree comprises: According to the acquired transport relationship between the multiple transport nodes included in the logistics network, searching for edge nodes in the sub-path tree, wherein the edge nodes are directly associated with other transport nodes that are not affected by the changed transport status; Calculate the shortest path of the edge node according to the changed transportation status, the acquired transportation relationship between the multiple transportation nodes included in the logistics network, the transportation reference index corresponding to the transportation relationship, and the starting transportation node of the path tree to which the edge node belongs; According to the shortest path of the edge node, the shortest path of the internal nodes in the sub-path tree except the edge node is constructed.
8. The method according to claim 1, characterized in that Also includes: Constructing a priority path queue for the shortest path tree; For each shortest path included in the shortest path tree, perform the following operations: Each transport node included in the determined shortest path, the transport relationship between the transport nodes, and the transport reference index corresponding to the transport relationship are stored in the priority path queue to manage the transport paths included in the logistics network through the priority path queue.
9. The method according to claim 8, characterized in that The re-searching the shortest path for the associated transport node comprises: Determining a plurality of parent transport nodes associated with the associated transport node according to the transport relationship between the plurality of transport nodes; According to the transport relationship and the corresponding transport reference index stored in the priority path queue including the parent transport node, a path reference index of a sub-path between the starting transport node and the parent transport node is obtained; Calculating path reference indices of a plurality of candidate paths corresponding to the associated transport node according to the path reference indices of the sub-paths and the transport reference indices between each of the parent transport node and the associated transport node; The candidate path with the smallest path reference index is determined as the shortest path of the associated transport node.
10. The method according to claim 8, characterized in that The managing of the transport paths included in the logistics network includes: The priority path queue is updated according to the determined shortest path.
11. The method according to claim 9, characterized in that Also includes: constructing a candidate path for each of the associated transport nodes; Storing the plurality of candidate paths corresponding to the associated transport node and the path reference index in the priority path queue; The step of determining the candidate path with the smallest path reference index as the shortest path of the associated transport node includes: Only the candidate path with the smallest path reference index is retained in the priority path queue.
12. The method according to claim 11, characterized in that The managing of the transport paths included in the logistics network further comprises: The transportation paths included in the logistics network are updated based on the new priority path queue.
13. The method according to claim 1, characterized in that After determining one or more associated transport nodes directly or indirectly associated with the changed transport status from the shortest path tree, the method further includes: A node queue is constructed, and all determined associated transport nodes are stored in the node queue; after the shortest path is re-found for each associated transport node, the associated transport node for which the shortest path is re-found is deleted from the node queue.
14. The method according to claim 13, characterized in that Further including: In the case that the node queue does not contain any associated transport node, it is determined that the transport path included in the logistics network is updated.
15. A logistics network updating device, characterized in that: include: Construct path tree module, determine associated node module and update network module; among them, The path tree construction module is used to construct one or more shortest path trees covering each transportation node included in the logistics network for the logistics network; The associated node determination module is used to determine one or more associated transportation nodes directly or indirectly associated with the changed transportation status from the shortest path tree in response to a change in the transportation reference index status between any two or more of the transportation nodes; The network update module is used to re-search the shortest path for the associated transportation nodes based on the transportation relationship between the multiple transportation nodes, the transportation reference indicators corresponding to the transportation relationship and the changed transportation conditions; and update the transportation path included in the logistics network based on the shortest path of the associated transportation node found.
16. An electronic device, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 14.
17. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 14 is implemented.
Citation Information
Cited By
Internet of Things distribution terminal sorting data dynamic processing system based on cloud computing
CN119228245A
