Large-scale travel order connection plan automatic generation method and device considering time-varying network, and readable storage medium
By transforming the problem of large-scale travel order transfer plan into multi-backpack problem and using genetic algorithms to solve it, the problems of low efficiency and poor results in the existing technology are solved, and the effect of efficient generation of large-scale travel order transfer plan is achieved.
Patent Information
- Application Number
- CN202411771696.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-03-14
AI Technical Summary
The existing technology is inefficient and poor in handling large-scale travel order transfer plans, making it difficult to effectively solve the high computing cost and search difficulty caused by time-varying networks.
The method of spatial and temporal clustering combined with local path planning and merged route listing is adopted to transform large-scale path planning problems into multi-backpack problems with object incompatible attribute constraints, and a genetic algorithm is designed to improve solution capabilities and efficiency.
Through problem transformation and genetic algorithm solution, the computational complexity and calculation cost are significantly reduced, the solution efficiency and the feasibility and practicality of the results are improved, and large-scale travel order transfer plans can be generated in a short time.
Smart Images

Figure CN119624022A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of transportation, and in particular to a method, device and readable storage medium for automatically generating a large-scale travel order connection plan considering a time-varying network. Background Art
[0002] In the field of transportation in large cities, generating travel order plans is a crucial task. With the acceleration of urbanization and the continuous growth of people's travel needs, the number of trips is showing a rapid upward trend. This makes the difficulty of formulating connection plans also increase sharply.
[0003] At present, in the face of large-scale travel orders, existing inventions usually directly solve the original problem under the conditions of considering multiple constraints such as orders, vehicles, and drivers. However, this solution method has many shortcomings. First, due to the existence of time-varying networks, when directly solving the path planning problem, each search for a feasible solution requires a lot of resources to calculate the path time, which leads to high computational costs. Secondly, the original problem contains constraints in multiple dimensions, such as the time and location requirements of the order, the driver's working hours, the vehicle's full load rate, etc. Solving these multi-dimensional constraints at the same time makes the search extremely difficult. For large-scale problems, this direct solution method is not only inefficient, but also often fails to obtain satisfactory solutions.
[0004] In summary, existing technologies face challenges such as low efficiency and poor results when dealing with the connection planning problem of large-scale travel orders. Therefore, developing a method that can efficiently and automatically generate connection plans for large-scale travel orders has important practical significance and application value. Summary of the invention
[0005] The embodiments of the present invention provide a method, device and readable storage medium for automatically generating a large-scale travel order connection plan considering a time-varying network, which aims to address the problems existing in the current technology of processing large-scale travel order connection plans, such as poor solution results due to the complexity and inefficiency of direct solution.
[0006] The core technology of the present invention is to transform the large-scale path planning problem into a multi-knapsack problem with incompatible attribute constraints of items by using spatiotemporal clustering combined with local path planning to merge the way-by-way orders, and to design a genetic algorithm to solve it in order to improve the solving ability and efficiency.
[0007] In a first aspect, the present invention provides a method for automatically generating a large-scale travel order connection plan considering a time-varying network, the method comprising the following steps: S00, read basic information, including travel order information and available vehicle information, and perform parameter configuration; S10: Based on the configured parameters and the read basic information, the orders are spatiotemporally clustered, local path planning is performed, and the orders along the way are merged; S20. Use a genetic algorithm to assign orders and generate a connection plan for each vehicle / driver.
[0008] Furthermore, in step S00, the travel order information includes: Departure order information: high-speed rail and airplane arrival station, time, and destination address; Return order information: the passenger's departure address, as well as the station and time of the return high-speed rail or flight departure; Order type: carpooling order or private car order.
[0009] Furthermore, in step S00, the available vehicle information includes: Number of vehicles, and the maximum number of passengers that each vehicle can carry; The location where the driver departs and eventually returns.
[0010] Furthermore, in step S00, parameter configuration includes: Group order time: used to reduce passengers’ waiting time at the station; Detour ratio: used to control the passenger's riding distance; Driver's maximum working hours: the single-day working hours of each driver; Driver rest: Each driver needs to take a mandatory rest for t minutes after driving for T hours continuously; Maximum vehicle load factor: reserve some seats for the vehicle.
[0011] Furthermore, in step S10, the specific steps of spatiotemporal clustering of orders include: Define the order as a virtual point, and the time and space distance between the pick-up and drop-off points between orders as the virtual distance; For orders with the same pick-up point and arrival / departure time within the constraint threshold, the virtual distance is defined as a smaller value, otherwise it is defined as a larger value; A series of small-scale order sub-problems are obtained through clustering algorithm.
[0012] Furthermore, in step S10, the specific steps of local path planning include: Perform local path planning for each small-scale order sub-problem to determine the en-route orders that can be shared; Combine drop-off orders into a new order.
[0013] Furthermore, in step S20, the specific steps of using the genetic algorithm to assign orders include: Sort the orders in chronological order; Calculate the time conflict relationship between two orders; Use genetic algorithms to assign orders to ensure that there is no time conflict between orders on each vehicle; The orders assigned to each vehicle are sorted in chronological order, and a connection plan for each vehicle / driver is generated.
[0014] In a second aspect, the present invention provides a device for automatically generating a large-scale travel order connection plan considering a time-varying network, comprising: Data reading module: used to read order information and available vehicle information. Order information includes departure orders and return orders, including relevant stations, time, destination address or departure address of high-speed rail or airplane, and order type. Available vehicle information includes the number of vehicles, the maximum number of passengers of each vehicle, and the departure and final return locations of the driver; Parameter configuration module: used to configure parameters, including the group-order time and detour ratio for passenger experience, as well as the maximum working hours, rest time and maximum load factor of drivers and vehicles; Order processing module: used to cluster orders with the possibility of carpooling, obtain small-scale order sub-problems, perform local path planning for each sub-problem, merge on-the-way orders, and obtain virtual orders that cannot be carpooled with other orders; Order assignment module: used to sort orders in chronological order, calculate the relationship between orders, estimate the arrival time of each node considering the time-varying network, model the problem as a multi-knapsack problem with item conflicts, design a genetic algorithm to solve it, sort the orders assigned to each vehicle in chronological order, and obtain the docking plan for each vehicle / driver.
[0015] In a third aspect, the present invention provides an electronic device including a memory and a processor, wherein the memory stores a computer program, and the processor is configured to run the computer program to execute the above-mentioned method for automatically generating a large-scale travel order connection plan considering a time-varying network.
[0016] In a fourth aspect, the present invention provides a readable storage medium, in which a computer program is stored. The computer program includes a program code for controlling a process to execute the process. The process includes a method for automatically generating a large-scale travel order connection plan based on the above-mentioned time-varying network.
[0017] The main contributions and innovations of the present invention are as follows: 1. The present invention transforms the large-scale path planning problem into a multi-knapsack problem with incompatible attribute constraints of items. This transformation method not only simplifies the complexity of the problem, but also makes the solution process more efficient. By transforming the problem, the high computational cost and low solution efficiency of directly solving the large-scale path planning problem are avoided, thereby generating a large-scale travel order connection plan in a relatively short time.
[0018] 2. The present invention uses a spatiotemporal clustering method to preliminarily process the orders, decomposing the large-scale problem into multiple small-scale sub-problems. Then, local path planning is performed for each sub-problem to merge the orders along the way. This method significantly reduces the computational complexity and improves the solution speed. At the same time, through local path planning, the rationality and feasibility of order merging are ensured.
[0019] 3. The present invention designs a genetic algorithm specifically for solving the transformed multi-knapsack problem. The algorithm effectively searches for the optimal solution through operations such as encoding, crossover and mutation. The genetic algorithm can handle complex multi-dimensional constraints, improving the robustness and accuracy of the solution. At the same time, the parallelism of the genetic algorithm also makes the solution process more efficient.
[0020] 4. In the problem preprocessing stage, the present invention incorporates the time-varying network information into the "item conflict constraint" to avoid additional calculation of the time-consuming path in the time-varying network in the main process solution. This method effectively reduces the amount of calculation in the main process and improves the solution efficiency. Especially in large-scale problems, the impact of the time-varying network becomes more significant, and the advantages of this method are more obvious.
[0021] 5. The present invention comprehensively considers multi-dimensional constraints such as orders, drivers, and vehicles, and ensures that the generated docking plan meets actual needs through parameter configuration and algorithm design. This method improves the feasibility and practicality of the docking plan, reduces the workload of staff, and improves the utilization rate of docking vehicles.
[0022] 6. The present invention effectively solves the challenges in generating large-scale travel order connection plans through innovative problem transformation methods, spatiotemporal clustering combined with local path planning, genetic algorithm optimization, time-varying network considerations and multi-dimensional constraint processing, and has significant technical advantages and practical application value.
[0023] The details of one or more embodiments of the invention are set forth in the following drawings and description so that other features, objects, and advantages of the invention are more readily apparent. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] The drawings described herein are used to provide a further understanding of the present invention and constitute a part of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the drawings: Figure 1 is a flowchart of a method for automatically generating a large-scale travel order connection plan considering a time-varying network according to an embodiment of the present invention; Figure 2 is a flow chart of performing order assignment according to a genetic algorithm according to an embodiment of the present invention; Figure 34 is a schematic diagram of the hardware structure of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0025] Exemplary embodiments will be described in detail herein, examples of which are shown in the accompanying drawings. When the following description refers to the drawings, the same numbers in different drawings represent the same or similar elements unless otherwise indicated. The implementations described in the following exemplary embodiments do not represent all implementations consistent with one or more embodiments of this specification. Instead, they are merely examples of devices and methods consistent with some aspects of one or more embodiments of this specification as detailed in the appended claims.
[0026] It should be noted that: in other embodiments, the steps of the corresponding method are not necessarily performed in the order shown and described in this specification. In some other embodiments, the steps included in the method may be more or less than those described in this specification. In addition, a single step described in this specification may be decomposed into multiple steps for description in other embodiments; and multiple steps described in this specification may be combined into a single step for description in other embodiments.
[0027] Existing inventions all directly solve the original problem under the constraints of orders, vehicles, and drivers, which is highly complex. For large-scale problems, such a solution is relatively inefficient and the solution results are generally poor. Therefore, developing a method that can automatically generate a connection plan for large-scale travel orders has significant practical application value.
[0028] Based on this, the present invention solves the problems existing in the prior art by combining spatiotemporal clustering with local path planning to merge waypoints.
[0029] Embodiment 1 The present invention aims to propose a method for automatically generating a large-scale travel order connection plan considering a time-varying network. Specifically, referring to Figure 1 , the method comprising: Step 1: Basic data reading, parameter configuration and preprocessing.
[0030] First, you need to read the basic information, which mainly includes order information and available vehicle information.
[0031] 1) Travel order information includes departure orders and return orders: ① Departure order information must include the arrival station, time, and destination address of the high-speed rail or airplane; ② Return order information must include the passenger's departure address, as well as the departure station and time of the return high-speed rail or airplane; ③ Whether the order is a carpooling order or a private car order. Carpooling orders can share a car with other orders, while private car orders have their own car.
[0032] 2) Available vehicle information includes basic information about vehicles and drivers, such as the number of vehicles, the maximum number of passengers that each vehicle can carry, the driver's departure and final return locations, etc.
[0033] Secondly, parameter configuration is performed. The algorithm parameters take into account both the passenger experience and the driver's vehicle.
[0034] 1) In terms of passenger experience, the configuration parameters include: ① Shared order time: used to reduce the waiting time of passengers at the station. That is, for shared order, if the high-speed rail and flight of two orders arrive / depart at the same station, and the arrival / departure time is less than the shared order time, the orders are allowed to take the same car. ② Detour ratio: used to control the passenger's travel distance. The travel distance of shared passengers cannot exceed a certain proportion of the direct distance between their boarding and alighting points due to shared order.
[0035] 2) Driver and vehicle configuration parameters include: ① Maximum working hours for drivers: To ensure safety, the daily working hours of each driver cannot exceed a certain value; ② Driver rest: To ensure safety, each driver needs to take a mandatory rest of t minutes after driving continuously for T hours; ③ Maximum vehicle load rate: Taking into account driving safety and in some cases due to communication reasons, the actual number of passengers is greater than the number of passengers when the order is placed, so the maximum load rate needs to be set. This value can be used to reserve some seats for the vehicle during calculation.
[0036] Step 2: Cluster orders in time and space, perform local route planning, and merge en route orders.
[0037] Due to the large scale of the problem, it is extremely inefficient to directly plan the paths for all orders and vehicles. In addition, due to the large scale of data, the requirements for algorithms and hardware equipment are extremely high, so the problem needs to be broken down. It is noted that one of the pick-up and drop-off points for the connecting order must be a high-speed rail station or airport. The arrival or departure time of the passengers follows the arrival and departure time of the high-speed rail and airplane, and the high-speed rail station or airport is a certain distance away from most hotels, homestays, etc. Therefore, under the strict constraints of the order-sharing time and detour ratio, there are actually fewer orders that can be combined into the same car. Therefore, it is not necessary to put all orders and vehicles into one model to solve them together, but to first decompose the problem and reduce its scale.
[0038] Specifically, we can first cluster the orders that have the possibility of carpooling. In this problem, we can define the orders as virtual points, and the time-space distance between the boarding and alighting points between the orders as the virtual distance. For example, considering the above-mentioned carpooling constraints, the virtual distance that can be defined as a smaller value for the same boarding point and the arrival / departure time within the constraint threshold, otherwise the virtual distance is a larger value. After clustering, we get a series of small-scale order sub-problems, and perform local path planning for each sub-problem. From the results, we can get the orders that can be shared along the way. Finally, merge the orders along the way as a virtual order that cannot be shared with other orders.
[0039] Preferably, the specific operations of order spatiotemporal clustering are as follows: 1) Define virtual points: Order virtual point: Each order is considered as a virtual point. Each virtual point contains the order's departure time and location, arrival time and location, etc.
[0040] Space-time distance: defines the space-time distance between orders. Space-time distance not only considers the spatial distance (i.e. the physical distance between the order start and end points), but also includes the time factor (i.e. the departure time and arrival time of the order).
[0041] 2) Calculate virtual distance: Space-time distance formula: Define a space-time distance formula to calculate the virtual distance between two orders. For example, you can use the following formula: First, the virtual distance between a single node is introduced as follows:
[0042]
[0043] Where m and n are two nodes. In the order, m and n are both departure points or arrival points. The departure / arrival time of node m is before that of node n. Represents the virtual distance between two nodes m and n. space_distance(m,n) is the spatial distance between nodes m and n; time_difference(m,n) is the time difference between nodes m and n; (m,n) is the virtual time difference between node m and node n, where
[0044] , which means that the vehicle starts from node m and goes to node n. If the estimated access time of node n happens to be reached when the vehicle arrives, it is also considered that there is a possibility that the two nodes are on the same route; α and β are weight coefficients, which are used to balance the importance of spatial distance and time difference.
[0045] Assuming that m and n are the starting points of orders i and j respectively, and h and k are the arrival points of orders i and j respectively, then the virtual distance between orders i and j is as follows:
[0046] Among them, the departure time of order i is before order j, and Dij is the virtual distance between order i and order j.
[0047] 3) Set the clustering threshold: Group order time threshold: Set a group order time threshold to determine whether two orders can be grouped. If the departure or arrival time difference between two orders is less than the group order time threshold, the two orders are considered to be grouped.
[0048] Detour ratio threshold: Set a detour ratio threshold to control the passenger's riding distance. If the passenger's riding distance after carpooling exceeds a certain ratio of the direct distance between the pick-up and drop-off points, the two orders are considered unsuitable for carpooling.
[0049] 4) Clustering algorithm selection: Common clustering algorithms: You can choose from a variety of clustering algorithms, such as K-means, DBSCAN, etc. These algorithms can divide orders into multiple clusters based on the temporal and spatial distances of the orders.
[0050] K-means algorithm: randomly divides orders into k initial clusters, and then iteratively adjusts the cluster to which each order belongs until convergence.
[0051] DBSCAN algorithm: A density-based clustering algorithm that can find clusters of any shape and is suitable for situations where order distribution is uneven.
[0052] 5) Clustering result processing: Generate small-scale sub-problems: Through clustering algorithms, large-scale order sets are decomposed into multiple small-scale sub-problems. Each sub-problem contains a group of orders with similar spatiotemporal characteristics.
[0053] Local path planning: Perform local path planning for each small-scale sub-problem to determine which orders can be merged into on-the-way orders. The specific steps include: Path planning: Use a path planning algorithm (such as Dijkstra algorithm, A* algorithm, etc.) to calculate the optimal path for the orders in each subproblem.
[0054] Merge en route orders: Merge en route orders that can be merged into a new order. The new order is regarded as an indivisible whole with a fixed start and end point.
[0055] Suppose we have the following order data: Order A: departure time 8:00, departure location X, arrival time 8:30, arrival location Y; Order B: departure time 8:05, departure location X, arrival time 8:35, arrival location Y; Order C: departure time 8:10, departure location Z, arrival time 8:40, arrival location W; Order D: departure time 8:15, departure location Z, arrival time 8:45, arrival location W; The distance matrix is assumed to be as follows: Table 1
[0056] The vehicle speed is assumed to be: 500 m / min Space-time distance formula weight:
[0057] Calculate virtual distance: Virtual distance between order A and order B:
[0058]
[0059] Virtual distance between order A and order C: )
[0060] Virtual distance between order A and order D:
[0061]
[0062] Virtual distance between order B and order C: )
[0063] Virtual distance between order B and order D:
[0064]
[0065] Virtual distance between order C and order D:
[0066]
[0067] Clustering: Use K-means or DBSCAN algorithm to group orders A and B into one cluster, and orders C and D into another cluster.
[0068] Local path planning: Set thresholds: Order grouping time threshold: 5 minutes; Detour ratio threshold: 10%; Perform route planning for orders A and B to determine the best route. Perform route planning for orders C and D to determine the best route. Merge on-the-way orders to generate new orders AB and CD.
[0069] Step 3: Genetic algorithm is used to assign orders.
[0070] Based on step 2, N orders can be obtained, and each order cannot be shared with other orders. Therefore, in dispatching orders and route planning, we only need to consider whether the time of each order dispatched to the same vehicle conflicts.
[0071] The definition of conflict is explained below: Suppose there are two adjacent orders R1 and R2 for the same vehicle; the pick-up point of the preceding order is O1 (estimated arrival time is T_o1) and the drop-off point is D1 (estimated arrival time is T_d1), the pick-up point of the subsequent order is O2 (estimated order acceptance time is T_o2) and the drop-off point is D2 (estimated arrival time is T_d2), the navigation time from D1 to O2 is S, and the maximum working time of the driver is H. If T_d1+S>T_o2 (order R2 cannot be received in time) or T_d2-T_o1>H (driver working time exceeds), the relationship between the two orders is called a conflict, and the two orders need to be dispatched to different vehicles.
[0072] Therefore, we can first sort the orders in chronological order and calculate the relationship between them. At the same time, we should pay attention to considering the time-varying network in the calculation. Specifically, for any, when estimating the arrival time of each node, we need to first decide the departure time of the previous node, and use historical data to predict the navigation time. In this problem, the navigation time at any moment can be regarded as a known parameter input into the model. At this point, this problem can be modeled as a multi-knapsack problem with item conflicts. The items are the orders in this problem, the knapsacks are the vehicles, and the decision variables are which vehicle is assigned to each order. Finally, the orders assigned to each vehicle are sorted in chronological order to obtain the docking plan for each vehicle / driver.
[0073] In this embodiment, if Figure 2 As shown in the figure, the specific operations of genetic algorithm for order assignment are as follows: 1. Coding Encoding method: The vehicle to which each order is assigned is represented as a chromosome. Each chromosome is a vector with a length equal to the number of orders, and each element in the vector represents the vehicle number assigned to the corresponding order.
[0074] For example, if there are 5 orders and 3 vehicles, a possible chromosome representation is: 1,2,3,1,2, which means that order 1 and order 4 are assigned to vehicle 1, order 2 and order 5 are assigned to vehicle 2, and order 3 is assigned to vehicle 3.
[0075] 2. Initialize the population Population initialization: Randomly generate a certain number of initial chromosomes to form an initial population. Each chromosome represents a possible order assignment scheme.
[0076] 3. Fitness Function Fitness function: Define a fitness function to evaluate the quality of each chromosome. The fitness function usually considers the following factors: Total travel time: The sum of the time required for all vehicles to complete all orders.
[0077] Vehicle utilization: the average load factor of each vehicle.
[0078] Time conflict: whether there is a time conflict between orders, such as the end time of one order is later than the start time of the next order.
[0079] Driver working hours: Ensure that each driver’s working hours do not exceed the specified maximum working hours.
[0080] Detour ratio: The passenger's riding distance should not exceed a certain ratio of the direct distance between their boarding and alighting points.
[0081] 4. Select Selection operation: According to the fitness function value, a part of chromosomes is selected from the current population to enter the next generation. Common selection methods include roulette wheel selection, tournament selection, etc.
[0082] Roulette wheel selection: The chromosome with higher fitness value has a greater probability of being selected.
[0083] Tournament selection: Randomly select several chromosomes for comparison and select the chromosome with the highest fitness value.
[0084] 5. Cross Crossover operation: select two chromosomes to cross and generate a new chromosome. Common crossover methods include single-point crossover, multi-point crossover, uniform crossover, etc.
[0085] Single-point crossover: A crossover point is randomly selected and the parts of the two chromosomes after that point are exchanged.
[0086] Multi-point crossover: Multiple crossover points are randomly selected and the parts of the two chromosomes between these points are exchanged.
[0087] 6. Mutation Mutation operation: Randomly change certain genes of chromosomes with a certain probability to introduce new genetic diversity. Common mutation methods include bit flip mutation, exchange mutation, etc.
[0088] Bit-flip mutation: randomly selects a gene position and changes its value to another random value.
[0089] Swap mutation: randomly select two gene positions and swap their values.
[0090] 7. Replace Replacement operation: replace part of the chromosomes in the current population with the newly generated chromosomes to form a new generation of population. Elite retention strategy: retain the chromosomes with the highest fitness value in the current population, and replace the rest of the chromosomes with the newly generated chromosomes.
[0091] 8. Termination Conditions Termination condition: Set a termination condition to stop the genetic algorithm when the condition is met. Common termination conditions include: Maximum number of iterations: Reach the predetermined maximum number of iterations.
[0092] Fitness Threshold: Find chromosomes whose fitness values meet or exceed a certain threshold.
[0093] Convergence condition: The fitness value of the population changes very little, indicating that the algorithm has converged.
[0094] In this example, assume that we have 5 orders and 3 vehicles, and the initial population contains 4 chromosomes: Chromosome 1:1,2,3,1,2; Chromosome 2: 1,1,2,3,3; Chromosome 3: 2,3,1,2,3; Chromosome 4: 3,1,2,1,3; Fitness evaluation: The fitness value of each chromosome is calculated, considering factors such as total travel time, vehicle utilization, and time conflicts.
[0095] choose: According to the fitness value, the chromosome with higher fitness value is selected to enter the next generation.
[0096] cross: Select chromosome 1 and chromosome 2 for single-point crossover to generate new chromosome 5 and chromosome 6.
[0097] For example, if the intersection point is 3, we generate: Chromosome 5:1,2,3,3,3; Chromosome 6: 1,1,2,1,2; Mutation: Mutate chromosome 5 and chromosome 6 with a certain probability.
[0098] For example, the 4th gene of chromosome 5 mutates to 1, resulting in: Chromosome 5: 1,2,3,1,3 replace: Chromosomes 5 and 6 are used to replace chromosomes with lower fitness values in the current population to form a new generation of population.
[0099] Termination conditions: If the maximum number of iterations is reached or a chromosome that meets the fitness threshold is found, the genetic algorithm stops.
[0100] The original problem studied by this invention is a path planning problem, which has multi-dimensional constraints such as orders, drivers, and vehicles. At the same time, due to the existence of time-varying networks, if the problem is solved directly, it will take a lot of resources to calculate the path time each time a feasible solution is searched. After the problem is transformed, when solving the knapsack problem, the time-varying network information has been included in the "item conflict constraint" in the preprocessing, and there is no need to perform additional calculations on the path time in the time-varying network, so the amount of calculation can be effectively reduced in the main process solution.
[0101] The present invention specifically designs a genetic algorithm to solve the above problem. Each encoded position index represents the order numbers sorted in chronological order, and each encoded number is the vehicle number assigned to the order. At the same time, a crossover mutation operator is designed to perform neighborhood search. The present invention innovatively transforms the problem, that is, it adopts spatiotemporal clustering combined with local path planning to merge the way-bye orders, transforms the large-scale path planning problem into a multi-knapsack problem with item incompatible attribute constraints, and then specifically designs a genetic algorithm to solve the transformed problem. This method integrates the order-related constraints and time-varying network characteristics into the item incompatible attribute constraints, effectively reducing the number of variables and constraints in the model, reducing the complexity of solving the original problem, and can generate large-scale travel order connection plans in a relatively short time.
[0102] Embodiment 2 Based on the same concept, the present invention also proposes a device for automatically generating a large-scale travel order connection plan considering a time-varying network, comprising: Data reading module: used to read order information and available vehicle information. Order information includes departure orders and return orders, including relevant stations, time, destination address or departure address of high-speed rail or airplane, and order type. Available vehicle information includes the number of vehicles, the maximum number of passengers of each vehicle, and the departure and final return locations of the driver; Parameter configuration module: used to configure parameters, including the group-order time and detour ratio for passenger experience, as well as the maximum working hours, rest time and maximum load factor of drivers and vehicles; Order processing module: used to cluster orders with the possibility of carpooling, obtain small-scale order sub-problems, perform local path planning for each sub-problem, merge on-the-way orders, and obtain virtual orders that cannot be carpooled with other orders; Order assignment module: used to sort orders in chronological order, calculate the relationship between orders, estimate the arrival time of each node considering the time-varying network, model the problem as a multi-knapsack problem with item conflicts, design a genetic algorithm to solve it, sort the orders assigned to each vehicle in chronological order, and obtain the docking plan for each vehicle / driver.
[0103] Embodiment 3 This embodiment also provides an electronic device, referring to Figure 3 , comprises a memory 404 and a processor 402, wherein the memory 404 stores a computer program, and the processor 402 is configured to run the computer program to execute the steps in any of the above method embodiments.
[0104] Specifically, the processor 402 may include a central processing unit (CPU), or an application specific integrated circuit (ASIC), or may be configured to implement one or more integrated circuits of the embodiment of the present invention.
[0105] Among them, the memory 404 may include a large capacity memory 404 for data or instructions. For example, but not limitation, the memory 404 may include a hard disk drive (HDD), a floppy disk drive, a solid state drive (SSD), a flash memory, an optical disk, a magneto-optical disk, a tape, or a universal serial bus (USB) drive, or a combination of two or more of these. In appropriate cases, the memory 404 may include a removable or non-removable (or fixed) medium. In appropriate cases, the memory 404 may be inside or outside the data processing device. In a specific embodiment, the memory 404 is a non-volatile memory. In a specific embodiment, the memory 404 includes a read-only memory (ROM) and a random access memory (RAM). Where appropriate, the ROM may be a mask-programmed ROM, a programmable ROM (Programmable Read-Only Memory, PROM for short), an erasable PROM (Erasable Programmable Read-Only Memory, EPROM for short), an electrically erasable PROM (Electrically Erasable Programmable Read-Only Memory, EEPROM for short), an electrically alterable ROM (Electrically Alterable Read-Only Memory, EAROM for short) or a flash memory (FLASH) or a combination of two or more of these. In appropriate circumstances, the RAM may be a static random access memory (SRAM) or a dynamic random access memory (DRAM), wherein the DRAM may be a fast page mode dynamic random access memory 404 (FPMDRAM), an extended data output dynamic random access memory (EDODRAM), a synchronous dynamic random access memory (SDRAM), etc.
[0106] The memory 404 may be used to store or cache various data files required for processing and / or communication, as well as possible computer program instructions executed by the processor 402 .
[0107] The processor 402 reads and executes the computer program instructions stored in the memory 404 to implement any one of the methods for automatically generating a large-scale travel order connection plan considering a time-varying network in the above-mentioned embodiments.
[0108] Optionally, the electronic device may further include a transmission device 406 and an input / output device 408 , wherein the transmission device 406 is connected to the processor 402 , and the input / output device 408 is connected to the processor 402 .
[0109] The transmission device 406 can be used to receive or send data via a network. The specific examples of the above-mentioned network may include a wired or wireless network provided by a communication provider of the electronic device. In one example, the transmission device includes a network adapter (Network Interface Controller, referred to as NIC), which can be connected to other network devices through a base station so as to communicate with the Internet. In one example, the transmission device 406 can be a radio frequency (Radio Frequency, referred to as RF) module, which is used to communicate with the Internet wirelessly.
[0110] Input / output devices 408 are used to input or output information.
[0111] Embodiment 4 This embodiment also provides a readable storage medium, in which a computer program is stored. The computer program includes a program code for controlling a process to execute the process. The process includes a method for automatically generating a large-scale travel order connection plan considering a time-varying network according to the first embodiment.
[0112] It should be noted that the specific examples in this embodiment can refer to the examples described in the above embodiments and optional implementation modes, and this embodiment will not be described in detail here.
[0113] In general, various embodiments may be implemented in hardware or dedicated circuits, software, logic, or any combination thereof. Some aspects of the invention may be implemented in hardware, while other aspects may be implemented in firmware or software executed by a controller, microprocessor, or other computing device, but the invention is not limited thereto. Although various aspects of the invention may be shown and described as block diagrams, flow charts, or using some other graphical representation, it should be understood that, as non-limiting examples, the boxes, devices, systems, techniques, or methods described herein may be implemented in hardware, software, firmware, dedicated circuits or logic, general-purpose hardware or controllers or other computing devices, or some combination thereof.
[0114] Embodiments of the present invention may be implemented by computer software that is executable by a data processor of a mobile device, such as in a processor entity, or by hardware, or by a combination of software and hardware. Computer software or programs (also referred to as program products) including software routines, applets and / or macros may be stored in any device-readable data storage medium, and they include program instructions for performing specific tasks. A computer program product may include one or more computer executable components configured to perform an embodiment when the program is run. One or more computer executable components may be at least one software code or a portion thereof. In addition, at this point, it should be noted that, for example, Figure 1 Any block of the logic flow in the program may represent program steps, or interconnected logic circuits, blocks and functions, or a combination of program steps and logic circuits, blocks and functions. The software may be stored on physical media such as memory chips or storage blocks implemented within the processor, magnetic media such as hard disk or floppy disks, and optical media such as, for example, DVDs and their data variants, CDs, etc. Physical media are non-transitory media.
[0115] Those skilled in the art should understand that the technical features of the above embodiments may be arbitrarily combined. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0116] The above embodiments only express several implementation methods of the present invention, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present invention. It should be pointed out that, for those of ordinary skill in the art, several modifications and improvements can be made without departing from the concept of the present invention, and these all belong to the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the attached claims.
Claims
1. A method for automatically generating a large-scale travel order connection plan considering a time-varying network, characterized in that: The following steps are involved: S00, read basic information, including travel order information and available vehicle information, and perform parameter configuration; S10: Based on the configured parameters and the read basic information, the orders are spatiotemporally clustered, local route planning is performed, and the orders along the way are merged; S20. Use a genetic algorithm to assign orders and generate a connection plan for each vehicle / driver.
2. A method for automatically generating a large-scale travel order connection plan considering a time-varying network as claimed in claim 1, characterized in that: In step S00, the travel order information includes: Departure order information: high-speed rail and airplane arrival station, time, and destination address; Return order information: the passenger's departure address, as well as the station and time of the return high-speed rail or flight departure; Order type: carpooling order or private car order.
3. The method for automatically generating a large-scale travel order connection plan considering a time-varying network as claimed in claim 1, characterized in that: In step S00, the available vehicle information includes: Number of vehicles, and the maximum number of passengers that each vehicle can carry; The location where the driver departs and eventually returns.
4. The method for automatically generating a large-scale travel order connection plan considering a time-varying network as claimed in claim 1, characterized in that: In step S00, the parameter configuration includes: Grouping time: used to reduce passengers’ waiting time at the station; Detour ratio: used to control the passenger's riding distance; Driver's maximum working hours: the single-day working hours of each driver; Driver rest: Each driver needs to take a mandatory rest for t minutes after driving continuously for T hours; Maximum vehicle load factor: reserve some seats for the vehicle.
5. The method for automatically generating a large-scale travel order connection plan considering a time-varying network as claimed in claim 1, characterized in that: In step S10, the specific steps of order spatiotemporal clustering include: Define the order as a virtual point, and the time and space distance between the pick-up and drop-off points between orders as the virtual distance; For orders with the same pick-up point and arrival / departure time within the constraint threshold, the virtual distance is defined as a smaller value, otherwise it is defined as a larger value; A series of small-scale order sub-problems are obtained through clustering algorithm.
6. The method for automatically generating a large-scale travel order connection plan considering a time-varying network as claimed in claim 1, characterized in that: In step S10, the specific steps of local path planning include: Perform local path planning for each small-scale order sub-problem to determine the en-route orders that can be shared; Combine drop-off orders into a new order.
7. A method for automatically generating a large-scale travel order connection plan considering a time-varying network according to any one of claims 1 to 6, characterized in that: In step S20, the specific steps of using the genetic algorithm to assign orders include: Sort the orders in chronological order; Calculate the time conflict relationship between two orders; Use genetic algorithms to assign orders to ensure that there is no time conflict between orders on each vehicle; The orders assigned to each vehicle are sorted in chronological order, and a connection plan for each vehicle / driver is generated.
8. A device for automatically generating a large-scale travel order connection plan considering a time-varying network, characterized in that: include: Data reading module: used to read order information and available vehicle information. Order information includes departure orders and return orders, including relevant stations, time, destination address or departure address of high-speed rail or airplane, and order type. Available vehicle information includes the number of vehicles, the maximum number of passengers of each vehicle, and the departure and final return locations of the driver; Parameter configuration module: used to configure parameters, including the group-order time and detour ratio for passenger experience, as well as the maximum working hours, rest time and maximum load factor of drivers and vehicles; Order processing module: used to cluster orders with the possibility of carpooling, obtain small-scale order sub-problems, perform local path planning for each sub-problem, merge on-the-way orders, and obtain virtual orders that cannot be carpooled with other orders; Order assignment module: used to sort orders in chronological order, calculate the relationship between orders, estimate the arrival time of each node considering the time-varying network, model the problem as a multi-knapsack problem with item conflicts, design a genetic algorithm to solve it, sort the orders assigned to each vehicle in chronological order, and obtain the docking plan for each vehicle / driver.
9. An electronic device comprising a memory and a processor, characterized in that: A computer program is stored in the memory, and the processor is configured to run the computer program to execute the method for automatically generating a large-scale travel order connection plan considering a time-varying network as described in any one of claims 1 to 7.
10. A readable storage medium, characterized in that: The readable storage medium stores a computer program, which includes a program code for controlling a process to execute a process, and the process includes a method for automatically generating a large-scale travel order connection plan considering a time-varying network according to any one of claims 1 to 7.