Route planning method and device
By obtaining new passenger travel requests in the online bus system and determining the candidate site sequence, the problem that the traditional public transportation route planning system cannot flexibly respond to traffic changes is solved, and efficient calculation and optimal matching of online bus route planning is achieved.
Patent Information
- Application Number
- CN202411857330.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-16
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2044-12-16
AI Technical Summary
The traditional fixed route planning system for public transportation cannot flexibly respond to changes in traffic conditions, resulting in inefficient public transportation and long waiting time for passengers. Dynamic public transportation route planning is complex and difficult to meet the needs of real-time dynamic public transportation route planning.
By obtaining new passenger travel requests, the matching online bus and its original site sequence is determined, and the candidate site sequence is determined based on the distance and relative position relationship between the travel site and the original site, and the target planned route is finally determined.
The calculation amount of new route planning for online buses has been reduced, the speed of determining the target planned route has been accelerated, the optimal driver-passenger matching has been achieved, and the flexibility and efficiency of public transportation has been improved.
Smart Images

Figure CN119809070A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of route planning, and in particular to a route planning method and device. Background Art
[0002] With the increasing congestion of urban traffic, the traditional fixed route planning system for public transportation can no longer meet the growing travel demand and cannot flexibly respond to changes in traffic conditions, resulting in low efficiency of public transportation and long waiting times for passengers. To solve the above problems, dynamic public transportation has emerged. The route planning of dynamic public transportation belongs to the vehicle routing problem (VRP). The calculation scale increases with the factorial complexity of the number of passengers according to n. Each time a new passenger is added, the calculation needs to be recalculated. The calculation complexity is high and it is difficult to meet the needs of real-time dynamic public transportation route planning. Summary of the invention
[0003] In view of this, an embodiment of the present invention provides a route planning method and device to determine a new station sequence according to the distance and relative position relationship between the travel stations of new passengers and some of the original stations, and insert the travel stations of the newly added passengers into the original driving route of the online-hailing bus as close as possible. On the basis of meeting the needs of real-time dynamic planning of the driving route of the online-hailing bus, the calculation amount of the new driving route planning of the online-hailing bus is reduced.
[0004] In a first aspect, an embodiment of the present invention provides a route planning method, the method comprising:
[0005] Acquire a new passenger travel request, where the new passenger travel request includes a travel stop;
[0006] Determining at least one online-booked bus that matches the new passenger's travel request;
[0007] Determine the original station sequence corresponding to each of the online-hailing buses, where the original station sequence is a sequence consisting of original stations that the online-hailing bus has not passed through;
[0008] Based on the distances between at least some of the original sites and the travel sites, respectively determining relevant sites in each of the original site sequences corresponding to the travel sites;
[0009] Determining at least one first candidate site sequence according to the relative position relationship between each of the travel sites and the corresponding related sites;
[0010] A target planning route is determined based on at least one of the first candidate site sequences.
[0011] In a second aspect, an embodiment of the present invention provides a route planning device, the device comprising:
[0012] An acquisition module, used for acquiring a new passenger travel request, wherein the new passenger travel request includes a travel stop;
[0013] A first determination module is used to determine at least one online-booked bus that matches the travel request of the new passenger;
[0014] A second determination module is used to determine the original station sequence corresponding to each of the online-hailing buses, wherein the original station sequence is a sequence composed of the original stations that the online-hailing bus has not passed;
[0015] A third determination module, configured to determine, based on distances between at least some of the original sites and the travel sites, the relevant sites in each of the original site sequences corresponding to the travel sites;
[0016] A fourth determination module, configured to determine at least one first candidate site sequence according to a relative position relationship between each of the travel sites and the corresponding related sites;
[0017] A fifth determination module is used to determine a target planning route according to at least one of the first candidate site sequences.
[0018] According to a third aspect, an electronic device is provided, comprising a memory and a processor, wherein the memory is used to store one or more computer program instructions, wherein the one or more computer program instructions are executed by the processor to implement the method described in the first aspect above.
[0019] According to a fourth aspect, a computer-readable storage medium is provided, wherein a computer program is stored in the computer-readable storage medium, and when the computer program is executed by a processor, the method described in the first aspect is implemented.
[0020] In a fifth aspect, a computer program product is provided, comprising a computer program / instruction, wherein when the computer program / instruction is executed by a processor, the method described in the first aspect is implemented.
[0021] An embodiment of the present invention includes obtaining a travel request from a new passenger, wherein the travel request from the new passenger includes a travel stop, determining at least one online-hailing bus that matches the travel request from the new passenger, determining an original stop sequence corresponding to each of the online-hailing buses, wherein the original stop sequence is a sequence composed of original stops that the online-hailing bus has not passed through, and determining the relevant stops corresponding to the travel stops in each of the original stop sequences based on the distance between at least some of the original stops and the travel stops, and determining at least one first candidate stop sequence based on the relative position relationship between each of the travel stops and the corresponding relevant stops, and determining a target planned route based on at least one of the first candidate stop sequences. In this embodiment, a new stop sequence is determined based on the distance and relative position relationship between the travel stop of the new passenger and some of the original stops, and the travel stop of the newly added passenger can be inserted into the original travel route of the online-hailing bus as close as possible. On the basis of meeting the needs of real-time dynamic planning of the travel route of the online-hailing bus, the calculation amount of the new travel route planning of the online-hailing bus is reduced, and the determination speed of the target planned route is accelerated. At the same time, the target planned route is determined based on the stop sequences of multiple online-hailing buses, and the optimal driver-passenger matching can also be achieved. BRIEF DESCRIPTION OF THE DRAWINGS
[0022] The above and other objects, features and advantages of the present invention will become more apparent through the following description of the embodiments of the present invention with reference to the accompanying drawings, in which:
[0023] Figure 1 A system block diagram of an online bus booking service system according to an embodiment of the present invention;
[0024] Figure 2 is a flow chart of a route planning method according to an embodiment of the present invention;
[0025] Figure 3 A flowchart of a method for determining an online bus booking according to an embodiment of the present invention;
[0026] Figure 4 A schematic diagram of the relative positions of an online-booked bus and a boarding station according to an embodiment of the present invention;
[0027] Figure 5 A schematic diagram of inserting the original site sequence into the relevant site of an embodiment of the present invention;
[0028] Figure 6 A flowchart of a method for determining a target planning route according to an embodiment of the present invention;
[0029] Figure 7 is a flow chart of a route planning method according to an embodiment of the present invention;
[0030] Figure 8 is a schematic diagram of a route planning device according to an embodiment of the present invention;
[0031] Fig. 9FIG. 4 is a schematic diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0032] The present application is described below based on embodiments, but the present application is not limited to these embodiments. In the detailed description of the present application below, some specific details are described in detail. It is possible for those skilled in the art to fully understand the present application without the description of these details. In order to avoid confusing the essence of the present application, known methods, processes, flows, components and circuits are not described in detail.
[0033] In addition, persons of ordinary skill in the art will appreciate that the drawings provided herein are for illustration purposes and are not necessarily drawn to scale.
[0034] Unless the context clearly requires otherwise, the words "include", "comprising" and similar words throughout the application should be interpreted as including rather than exclusive or exhaustive; that is, the meaning is "including but not limited to".
[0035] In the description of this application, it should be understood that the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of this application, unless otherwise specified, the meaning of "plurality" is two or more.
[0036] The solutions described in this specification and in the examples, if they involve the processing of personal information, will be processed on the premise of having a legal basis (such as obtaining the consent of the subject of personal information, or being necessary for the performance of a contract, etc.), and will only be processed within the scope of regulations or agreements. If a user refuses to process personal information other than the necessary information for basic functions, it will not affect the user's use of basic functions.
[0037] Figure 1 FIG. 1 is a system block diagram of the online bus booking service system according to an embodiment of the present invention. Figure 1 As shown, the online bus booking service system of this embodiment includes a server 1, a passenger terminal 2, and a driver terminal 3. The server 1, the passenger terminal 2, and the driver terminal 3 are connected to each other through a network 4 to achieve information and data interaction. It should be understood that although Figure 1 Only a certain number of servers 1, passenger terminals 2 and driver terminals 3 are shown, but this does not mean that their respective numbers are limited. The system may include multiple servers 1, passenger terminals 2 and driver terminals 3.
[0038] Server 1 should be understood as a device that provides data processing, database, and communication facilities. For example, server 1 may refer to a single physical server with related communication data storage and database facilities, or may refer to a collection of networked or clustered processors, related networks, and storage devices, and operate software and one or more database systems and application software that support the services provided by the server. Server 1 can be a monolithic server or a distributed server across multiple computers or computer data centers, or it can be various types of cloud servers. In some embodiments, each server may include hardware, software, or an embedded logic component or a combination of two or more such components for performing appropriate functions supported or implemented by the server.
[0039] The passenger terminal 2 and the driver terminal 3 are communication terminals capable of running computer programs. These communication terminals may be terminal devices such as mobile phones, tablet computers, PDAs, wearable devices, and vehicle-mounted terminals integrated with vehicles. Both the passenger terminal 2 and the driver terminal 3 have a communication module, which is capable of wired or wireless communication. In some embodiments, the passenger terminal 2 and the driver terminal 3 include at least one remote communication module, such as a communication circuit for WLAN, GPRS, 2G / 3G / 4G / 5G remote communication. The passenger terminal 2 and the driver terminal 3 also have a display device and an input device, and the display device may be a liquid crystal display, an LED display, or a projection device. The input device may include, for example, a touch screen, a button, a pressure sensor, etc. The passenger terminal 2 and the driver terminal 3 receive instructions from passengers through the input device, and interact with passengers or drivers through the display device.
[0040] The passenger client 21 can be run on the passenger terminal 2. The driver client 31 can be run on the driver terminal 3. At the same time, the server 1 runs the server application 11. The server 1, the passenger terminal 2 and the driver terminal 3 can communicate through the network 4. In some application scenarios, the passenger can issue a passenger travel request by operating the passenger client 21. The server 1 receives the passenger travel request and matches a suitable driver terminal 3 based on, for example, the location information reported by the driver terminal 3 and the location information of the passenger travel request, and then sends the passenger travel request to one or more matching driver terminals 3. Then, a ride order can be generated.
[0041] The online bus of this embodiment is different from the existing online car-hailing business. The existing online car-hailing business usually does not set up fixed stations, but the online car-hailing cruises in a certain area of the city. The server 1 matches the corresponding passenger travel request according to the location of the online car-hailing, and forms a ride order to send the boarding location selected by the passenger to the driver end. The driver end picks up and drops off passengers at the boarding and alighting sites selected by the passenger according to the requirements of the ride task. In the process of carrying out this business, the boarding point and the alighting point are selected by the passenger through the passenger client, and can be any location that the online car-hailing service can reach. Such a service provides the same flexible and personalized service as a taxi, and passengers can enjoy door-to-door travel services. However, this type of online car-hailing service is the same as a taxi, and the price is relatively high. In order to reduce the price, a carpooling service has emerged, that is, multiple passengers who do not know each other send carpooling service requests to the server, and the server will match these carpooling service requests, and form a carpooling service task with multiple carpooling service requests along the way to assign it to a specific driver end of an online car-hailing service. The driver end picks up and drops off multiple passengers to different locations in sequence according to the carpooling service task. Carpooling services have significantly reduced service prices and improved vehicle utilization efficiency. However, the selection and determination of pick-up and drop-off points in carpooling services are the same as those in online car-hailing services, and are still selected by passengers. Online car-hailing platforms only recommend several locations with a high number of pick-ups or drop-offs in the area when passengers choose the pick-up location to assist passengers in making their choices.
[0042] Then, there is still a demand to further reduce travel prices, as well as a demand to enjoy more flexible and convenient travel services than existing public transportation at a lower price. Based on the above needs, online bus services have emerged. Online buses have the concept of fixed stations and integrate the logic of existing carpooling services. However, it is different from the existing bus business. The existing bus business is based on different bus routes, and each route is operated based on a completely unchanged driving route. On the one hand, the online bus business forms a ride order based on the user's passenger travel request, inheriting the mechanism of online car-hailing and carpooling businesses initiated online based on user requests. On the other hand, the online bus business limits the boarding and alighting locations to fixed stations as much as possible. The advantage of setting fixed stations is that there is a greater probability of picking up and dropping off multiple passengers at a time at fixed stations, which improves efficiency. At the same time, when fixed stations are set up, passengers can initiate passenger travel requests directly at fixed stations by scanning codes in addition to initiating requests online. At the same time, the online bus service still has a high degree of flexibility, and the server can match ride orders based on the location of the passenger terminal that initiates the request with a logic similar to carpooling. Moreover, online-hailing buses do not run on fixed routes throughout the day and at all times, but instead run around areas covered by multiple different stations in urban areas, retaining the flexibility of online-hailing cars and taxis. Moreover, in certain modes, the routes of online-hailing buses can change dynamically during driving, which is highly intelligent and can meet the travel needs of passengers with extremely high efficiency.
[0043] exist Figure 1 In the online bus booking business system shown, in a typical example, the passenger terminal 2 can initiate a passenger travel request to the server 1 through the passenger client 21, and the passenger travel request can contain the boarding station and the alighting station (both fixed stations) selected by the passenger. The server 1 can match and send the corresponding ride task according to the driver terminal 3 of the online bus running around the boarding station to the vicinity of the alighting station, and form a ride order. The driver terminal 3 guides the online bus to the boarding station through the driver client 31, and sends the passenger to the alighting station along the predetermined driving route through multiple fixed stations. In this process, the driver terminal 3 of the online bus is still in the order-taking state, and can continuously match new passenger travel requests, and pick up passengers at the corresponding boarding station and send them to the alighting station. The server 1 can plan the route of the online bus in real time according to the actual distribution of the received passenger travel requests, so that the online bus runs between different stations to pick up passengers according to the planned route.
[0044] This embodiment is used to achieve that when the server 1 receives a new passenger travel request, it matches at least one suitable online-hailing bus for the new passenger, then replans the route of the online-hailing bus, recalls multiple re-planned routes and performs optimal driver-passenger matching, thereby determining the target planned route.
[0045] Figure 2 FIG. 1 is a flow chart of a route planning method according to an embodiment of the present invention. Figure 2 As shown, the route planning method includes the following steps:
[0046] Step S201, obtaining a new passenger travel request.
[0047] Among them, new passenger travel requests refer to new passenger travel requests that appear when the online bus starts operating. New passenger travel requests contain all information used to ensure the smooth operation of passenger travel services, such as the passenger's location, departure place, destination, travel time, itinerary preferences, etc. This information meets relevant security and privacy requirements.
[0048] In a possible implementation, the new passenger travel request at least includes travel sites, and the travel sites include sites that the passenger passes through during the trip, such as boarding sites, alighting sites, and / or passing sites. Passing sites refer to sites that the passenger must pass through in the desired travel route. Passing sites play an important role in route planning. To simplify the content, the following will be explained by taking the example that the travel sites only include boarding sites and alighting sites. However, it should be understood that the travel sites can also include important sites such as passing sites. When these important nodes are included, the processing process is similar to that of the alighting site, which will not be described in detail here.
[0049] In a possible implementation, the boarding station and the alighting station are stations selected by the passenger based on the passenger client 21. That is, when the passenger operates the passenger client 21, the passenger client 21 displays recommended stations, and the passenger selects the boarding station and the alighting station from the recommended stations. Then, the passenger client 21 sends a new passenger travel request containing the travel stations to the server.
[0050] Optionally, when the passenger operates the passenger client 21 to input the desired boarding point, the server 1 or the passenger terminal 2 determines the corresponding recommended boarding station based on the desired boarding point, so that the passenger client 21 displays the recommended boarding station, and the passenger selects the boarding station from the recommended boarding stations. The method for determining the alighting station is the same as the boarding station.
[0051] Optionally, when the passenger operates the passenger client 21 to input the desired boarding point, the server 1 or the passenger terminal 2 directly uses the desired boarding point as the boarding station, and the method for determining the alighting station is the same as the boarding station.
[0052] Step S202, determining at least one online-booked bus that matches the travel request of the new passenger.
[0053] Figure 3 The present invention is a flowchart of a method for determining an online-booked bus according to an embodiment of the present invention. Figure 4Schematic diagram of the relative position of the online booking bus and the boarding station according to an embodiment of the present invention. Figure 4 right Figure 3 The method shown is explained below. Figure 3 As shown, the online bus booking method includes the following steps:
[0054] Step S301, determining the vehicle position and travel direction of the online-booked bus.
[0055] The vehicle position is the location of the online-hailing bus, and the current driving direction of the online-hailing bus can be as follows: Figure 4 The direction shown is when traveling from the location of the online-hailing bus to the next original stop, or it can also be the direction when the online-hailing bus travels to the original stop closest to the boarding stop.
[0056] Step S302, determining the relative position relationship between the vehicle position and the boarding location.
[0057] The relative position relationship may include the distance and / or direction between the vehicle position and the boarding station.
[0058] Step S303: Determine at least one online-booked bus that matches the travel request of the new passenger based on the driving direction and the relative position relationship.
[0059] In one possible implementation, the angle α between the travel direction of any online-hailing bus and the direction from the boarding station to the vehicle location is determined, and it is judged whether the angle α is within a preset angle threshold. If it is within the preset angle threshold, it is determined that the online-hailing bus matches the travel request of the new passenger.
[0060] In one possible implementation, the distance L between any online-hailing bus and the boarding station is determined, and it is determined whether the distance L is within a first preset length threshold. If it is within the first preset length threshold, it is determined that the online-hailing bus matches the travel request of the new passenger.
[0061] In one possible implementation, the original station closest to the boarding station among the original stations corresponding to any online-hailing bus is determined, and the distance D between the boarding station and the original station closest to it is determined, and it is judged whether the distance D is within a second preset length threshold. If it is within the second preset length threshold, it is determined that the online-hailing bus matches the travel request of the new passenger.
[0062] In a possible implementation, online car-hailing matching judgment can also be performed based on multiple items of the angle α, the distance L, and the distance D.
[0063] It is worth noting that for each travel station, there is at least one corresponding related station in the original station sequence.
[0064] Step S203, determining the original station sequence corresponding to each of the online-hailing buses, wherein the original station sequence is a sequence consisting of original stations that the online-hailing bus has not passed through.
[0065] Specifically, a sequence consisting of original stations that have not been visited in the established driving route corresponding to each online-hailing bus is determined.
[0066] Step S204: determining relevant sites corresponding to the travel sites in each of the original site sequences based on the distances between at least some of the original sites and the travel sites.
[0067] In one possible implementation, based on the distance between at least part of the original site and the boarding site, the first related site corresponding to the boarding site in each of the original site sequences is determined. At the same time, based on the distance between at least part of the original site and the alighting site, the second related site corresponding to the alighting site in each of the original site sequences is determined.
[0068] Specifically, the distance between at least part of the original station and the boarding station is determined, and then the original station whose distance meets the first distance threshold is determined as the relevant station corresponding to the boarding station, that is, the first relevant station. The distance between at least part of the original station and the alighting station is determined, and then the original station whose distance meets the second distance threshold is determined as the relevant station corresponding to the alighting station, that is, the second relevant station. The first distance threshold and the second distance threshold may be the same or different.
[0069] Step S205: determining at least one first candidate site sequence according to the relative position relationship between each of the travel sites and the corresponding related sites.
[0070] The relative position relationship includes the travel station being located at the preceding position of the relevant station and the travel station being located at the following position of the relevant station. Specifically, the boarding station can be located at the preceding position of the first relevant station or at the following position of the first relevant station, and the alighting station can be located at the preceding position of the second relevant station or at the following position of the second relevant station. The location selection of the boarding station and the location selection of the alighting station can be cross-matched to obtain the first candidate station sequence corresponding to different arrangement methods.
[0071] Specifically, at least one first candidate site sequence is determined according to the relative position relationship between the boarding site and the first related site, and the relative position relationship between the alighting site and the second related site.
[0072] Figure 5 Schematic diagram of inserting the original site sequence into the relevant site of the embodiment of the present invention. Figure 5As shown, there are four ways to insert relevant sites into the original site sequence. The first is to insert the boarding site a into the leading position of the first relevant site A, and insert the alighting site b into the leading position of the second relevant site B. The second is to insert the boarding site a into the trailing position of the first relevant site A, and insert the alighting site b into the leading position of the second relevant site B. The third is to insert the boarding site a into the leading position of the first relevant site A, and insert the alighting site b into the trailing position of the second relevant site B. The fourth is to insert the boarding site a into the trailing position of the first relevant site A, and insert the alighting site b into the trailing position of the second relevant site B.
[0073] It is worth noting that Figure 5 The premise for inserting the related sites shown in the original site sequence is that there is only one first related site and second related site in the original site sequence. It should be understood that although Figure 5 Only one first related site and one second related site are shown, but this does not mean that the respective numbers are limited. In this embodiment, there may be multiple first related sites and multiple second related sites in the original site sequence.
[0074] In a possible implementation, the travel site and all the original sites in the original site sequence may be combined into a new site combination to be sorted, and then the sites in the site combination to be sorted may be sorted using a nearest neighbor algorithm to determine the corresponding first candidate site sequence.
[0075] Optionally, a new combination of sites to be sorted is formed based on each of the original site sequences, the boarding sites and the alighting sites, and the boarding sites are taken as starting points. A nearest neighbor algorithm is used to determine a first candidate site sequence corresponding to each of the site combinations to be sorted.
[0076] Optionally, a new combination of sites to be sorted is formed based on each of the original site sequences, the boarding sites and the alighting sites, the vehicle position of each of the online-hailing buses is determined, and the first candidate site sequence corresponding to each of the site combinations to be sorted is determined using the nearest neighbor algorithm with the vehicle position as the starting point.
[0077] Optionally, a greedy algorithm and a nearest neighbor algorithm may be used to determine the first candidate site sequence corresponding to each combination of sites to be sorted.
[0078] Step S206: determining a target planned route according to at least one of the first candidate site sequences.
[0079] Figure 6 Flow chart of the target planning route determination method of the embodiment of the present invention. Figure 6 As shown, the target planning route determination method includes the following steps:
[0080] Step S601: determine the travel cost corresponding to each of the first candidate site sequences.
[0081] The travel cost includes at least one of the route start-end distance, route length, travel time and passenger waiting time.
[0082] Specifically, the method for determining the distance between the beginning and the end of the route is: determine the geographical location of each original site in the first candidate site sequence, and determine the distance between the beginning and the end of the route according to the geographical location of the first original site and the geographical location of the last original site in the first candidate site sequence. The distance between the beginning and the end of the route can be the straight-line distance or Manhattan distance between the first original site and the last original site.
[0083] The method for determining the route length is: determining the corresponding route length according to the geographical location of each original site in the first candidate site sequence, that is, determining the distance between each two adjacent sites in the first candidate site sequence in turn, and then summing them up to obtain the total length of the route.
[0084] The method for determining the travel time is: determining the travel time according to the length of the route and the average travel speed of the online-hailing bus.
[0085] The method for determining the passenger waiting time is as follows: determining the distance between the geographical location of the online-hailing bus and the boarding station, and determining the passenger waiting time based on the distance and the average travel speed of the online-hailing bus. Specifically, multiple stations between the geographical location of the online-hailing bus and the boarding station are determined, the distance between each two adjacent stations is determined, and then the sum is obtained to obtain the route length from the online-hailing bus to the boarding point, and then the passenger waiting time is determined based on the route length and the average travel speed.
[0086] Step S602: determining a target site sequence from the first candidate site sequence according to the travel cost.
[0087] Specifically, the first candidate site sequence with the lowest travel cost may be determined as the target site sequence.
[0088] In a possible implementation, the first candidate site sequence may be screened multiple times according to different travel costs, so as to determine the target site sequence and reduce the amount of data processing.
[0089] Specifically, each new passenger travel request can match multiple online-booked buses, and each new passenger travel request corresponds to multiple travel sites, such as boarding sites, alighting sites, passing sites, and other important sites. There can also be multiple related sites corresponding to travel sites in the original site sequence corresponding to each online-booked bus, such as multiple related sites corresponding to boarding sites, and multiple related sites corresponding to alighting sites in the original site sequence. There are two relative positional relationships between each related site and the corresponding travel site. The positions of each related site are combined to generate multiple first candidate site sequences. Therefore, the number of first candidate site sequences may be large, so they can be screened in layers to reduce the amount of data processing.
[0090] For example, the second candidate site sequence can be determined from the first candidate site sequence based on the start-end distances of the routes corresponding to each of the first candidate site sequences, and then the target site sequence can be determined from the second candidate site sequence based on the route length, the travel time and the passenger waiting time.
[0091] Since the amount of calculation of the route start-end distance is relatively small, the route start-end distance can be used for the first round of screening, and then the target site sequence is determined from the second candidate site sequence screened based on other travel costs.
[0092] In addition, you can also choose other travel costs for the first round of screening, which are not listed here exhaustively.
[0093] Step S603: determining a target planned route corresponding to the target site sequence.
[0094] Specifically, the target planning route is determined according to the sequence of sites in the target site sequence and the geographical locations of the sites.
[0095] Figure 2 The method shown is a route planning method for a single new passenger travel request. In actual situations, the online bus-hailing service system will receive a large number of new passenger travel requests. If multiple new passenger travel requests match different online bus-hailing buses, they can be processed separately. If multiple new passenger travel requests match the same online bus, multiple rounds of processing will be performed in sequence. The processing order can be chronological order or the order of the first related site in the original site sequence, etc.
[0096] The method of an embodiment of the present invention includes obtaining a travel request of a new passenger, wherein the travel request of the new passenger includes a travel stop, determining at least one online-hailing bus matching the travel request of the new passenger, determining an original stop sequence corresponding to each of the online-hailing buses, wherein the original stop sequence is a sequence composed of original stops that the online-hailing bus has not passed through, and determining the relevant stops corresponding to the travel stops in each of the original stop sequences based on the distance between at least some of the original stops and the travel stops, and determining at least one first candidate stop sequence based on the relative position relationship between each of the travel stops and the corresponding relevant stops, and determining a target planned route based on at least one of the first candidate stop sequences. In this embodiment, a new stop sequence is determined based on the distance and relative position relationship between the travel stop of the new passenger and some of the original stops, and the travel stop of the newly added passenger can be inserted into the original travel route of the online-hailing bus as close as possible. On the basis of meeting the needs of real-time dynamic planning of the travel route of the online-hailing bus, the calculation amount of the new travel route planning of the online-hailing bus is reduced, and the determination speed of the target planned route is accelerated. At the same time, the target planned route is determined based on the stop sequences of multiple online-hailing buses, and the optimal driver-passenger matching can also be achieved.
[0097] Figure 7 FIG. 1 is a flow chart of a route planning method according to an embodiment of the present invention. Figure 7 As shown, the route planning method includes the following steps:
[0098] Step S701, obtaining a new passenger travel request.
[0099] The new passenger travel request includes travel stops, and the travel stops include at least a boarding stop and an alighting stop.
[0100] Step S702, determining at least one online-booked bus that matches the travel request of the new passenger.
[0101] Step S703, determining the original station sequence corresponding to each of the online-hailing buses, wherein the original station sequence is a sequence consisting of original stations that the online-hailing bus has not passed through.
[0102] Step S704: determining a first related site corresponding to the boarding site in each of the original site sequences based on the distances between at least part of the original sites and the boarding site.
[0103] Step S705: determining a second related site corresponding to the alighting site in each of the original site sequences based on the distances between at least part of the original sites and the alighting site.
[0104] Step S706: Determine at least one first candidate site sequence according to the relative position relationship between the boarding site and the first related site, and the relative position relationship between the alighting site and the second related site.
[0105] Among them, the relative position relationship between the boarding station and the first related station includes the boarding station being located at the front position of the corresponding related station and the boarding station being located at the rear position of the corresponding related station, and the relative position relationship between the alighting station and the second related station includes the alighting station being located at the front position of the corresponding related station and the alighting station being located at the rear position of the corresponding related station.
[0106] Step S707: construct a new combination of sites to be sorted according to the original site sequences, the boarding sites and the alighting sites.
[0107] Step S708: Taking the boarding station as a starting point, a nearest neighbor algorithm is used to determine a first candidate station sequence corresponding to each combination of stations to be sorted.
[0108] Step S709, determining the vehicle position of each of the online-booked buses.
[0109] Step S710, taking the vehicle position as a starting point, using a nearest neighbor algorithm to determine a first candidate site sequence corresponding to each of the to-be-sorted site combinations.
[0110] Step S711: determining a second candidate site sequence from the first candidate site sequences according to the route start-end distances corresponding to each of the first candidate site sequences.
[0111] Step S712: determining the target site sequence from the second candidate site sequence according to the route length, the travel time and the passenger waiting time.
[0112] Step S713, determining the target planned route corresponding to the target site sequence.
[0113] The specific implementation process of the above steps S701 to S713 is as described in the above embodiment and will not be repeated here.
[0114] This embodiment determines a new station sequence based on the distance and relative position relationship between the new passenger's travel station and some of the original stations. The travel station of the newly added passenger can be inserted into the original driving route of the online-hailing bus as close as possible. On the basis of meeting the needs of real-time dynamic planning of the online-hailing bus driving route, the calculation amount of the new driving route planning of the online-hailing bus is reduced, and the determination speed of the target planned route is accelerated. At the same time, the target planned route is determined based on the station sequences of multiple online-hailing buses, and the optimal driver-passenger matching can be achieved.
[0115] Figure 8 FIG. 1 is a schematic diagram of a route planning device according to an embodiment of the present invention. Figure 8 As shown, the route planning device includes:
[0116] The acquisition module 801 is used to acquire a new passenger travel request, where the new passenger travel request includes a travel stop.
[0117] The first determination module 802 is used to determine at least one online-booked bus that matches the travel request of the new passenger.
[0118] The second determination module 803 is used to determine the original station sequence corresponding to each of the online-hailing buses, and the original station sequence is a sequence composed of the original stations that the online-hailing bus has not passed.
[0119] The third determination module 804 is configured to determine, based on at least some of the distances between the original stations and the travel stations, the relevant stations in each of the original station sequences corresponding to the travel stations.
[0120] The fourth determination module 805 is used to determine at least one first candidate site sequence according to the relative position relationship between each of the travel sites and the corresponding related sites.
[0121] The fifth determination module 806 is used to determine a target planned route according to at least one of the first candidate site sequences.
[0122] The device of the embodiment of the present invention is used to execute: obtaining a travel request of a new passenger, wherein the travel request of the new passenger includes a travel stop, determining at least one online-hailing bus matching the travel request of the new passenger, determining an original stop sequence corresponding to each of the online-hailing buses, wherein the original stop sequence is a sequence composed of original stops that the online-hailing bus has not passed through, determining the relevant stops corresponding to the travel stops in each of the original stop sequences based on the distance between at least some of the original stops and the travel stop, determining at least one first candidate stop sequence according to the relative position relationship between each of the travel stops and the corresponding relevant stops, and determining a target planned route according to at least one of the first candidate stop sequences. The device of this embodiment determines a new stop sequence according to the distance and relative position relationship between the travel stop of the new passenger and some of the original stops, and can insert the travel stop of the newly added passenger into the original travel route of the online-hailing bus as close as possible. On the basis of meeting the needs of real-time dynamic planning of the travel route of the online-hailing bus, the calculation amount of the new travel route planning of the online-hailing bus is reduced, and the determination speed of the target planned route is accelerated. At the same time, the target planned route is determined based on the stop sequences of multiple online-hailing buses, and the optimal driver-passenger matching can be achieved.
[0123] Fig. 9 FIG. 1 is a schematic diagram of an electronic device according to an embodiment of the present invention. Fig. 9 As shown, Fig. 9The electronic device shown is a route planning device, which includes a general computer hardware structure, which includes at least a processor 901 and a memory 902. The processor 901 and the memory 902 are connected via a bus 903. The memory 902 is suitable for storing instructions or programs executable by the processor 901. The processor 901 can be an independent microprocessor or a collection of one or more microprocessors. Thus, the processor 901 executes the instructions stored in the memory 902, thereby executing the method flow of the embodiment of the present invention as described above to realize the processing of data and the control of other devices. The bus 903 connects the above-mentioned multiple components together, and at the same time connects the above-mentioned components to the display controller 904 and the display device and the input / output (I / O) device 905. The input / output (I / O) device 905 can be a mouse, a keyboard, a modem, a network interface, a touch input device, a somatosensory input device, a printer, and other devices known in the art. Typically, the input / output device 905 is connected to the system via an input / output (I / O) controller 906.
[0124] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, devices (equipment) or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present application may adopt a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0125] The present application is described with reference to flowcharts of methods, apparatuses (devices) and computer program products according to embodiments of the present application. It should be understood that each process in the flowchart can be implemented by computer program instructions.
[0126] These computer program instructions may be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device that implements the process Figure 1 A function specified in a process or multiple processes.
[0127] These computer program instructions may also be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce the instructions for implementing the process Figure 1 A device that specifies functions in a process or multiple processes.
[0128] An embodiment of the present invention includes obtaining a travel request from a new passenger, wherein the travel request from the new passenger includes a travel stop, determining at least one online-hailing bus that matches the travel request from the new passenger, determining an original stop sequence corresponding to each of the online-hailing buses, wherein the original stop sequence is a sequence composed of original stops that the online-hailing bus has not passed through, and determining the relevant stops corresponding to the travel stops in each of the original stop sequences based on the distance between at least some of the original stops and the travel stops, and determining at least one first candidate stop sequence based on the relative position relationship between each of the travel stops and the corresponding relevant stops, and determining a target planned route based on at least one of the first candidate stop sequences. In this embodiment, a new stop sequence is determined based on the distance and relative position relationship between the travel stop of the new passenger and some of the original stops, and the travel stop of the newly added passenger can be inserted into the original travel route of the online-hailing bus as close as possible. On the basis of meeting the needs of real-time dynamic planning of the travel route of the online-hailing bus, the calculation amount of the new travel route planning of the online-hailing bus is reduced, and the determination speed of the target planned route is accelerated. At the same time, the target planned route is determined based on the stop sequences of multiple online-hailing buses, and the optimal driver-passenger matching can also be achieved.
[0129] Another embodiment of the present invention relates to a non-volatile storage medium for storing a computer-readable program, wherein the computer-readable program is used for a computer to execute part or all of the above method embodiments.
[0130] Another embodiment of the present invention relates to a computer program product, comprising a computer program / instruction, wherein the computer program / instruction implements part or all of the above method embodiments when executed by a processor.
[0131] That is, those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by specifying relevant hardware through a program, and the program is stored in a storage medium, including several instructions for a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.
[0132] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.
Claims
1. A route planning method, characterized in that: The method comprises: Acquire a new passenger travel request, where the new passenger travel request includes a travel stop; Determining at least one online-booked bus that matches the new passenger's travel request; Determine the original station sequence corresponding to each of the online-hailing buses, where the original station sequence is a sequence consisting of original stations that the online-hailing bus has not passed through; Based on the distances between at least some of the original sites and the travel sites, respectively determining relevant sites in each of the original site sequences corresponding to the travel sites; Determining at least one first candidate site sequence according to the relative position relationship between each of the travel sites and the corresponding related sites; A target planning route is determined based on at least one of the first candidate site sequences.
2. The method according to claim 1, characterized in that The travel site at least includes a boarding site; The determining of at least one online-booked bus that matches the new passenger's travel request comprises: Determine the vehicle location and travel direction of the online-booked bus; Determining the relative position relationship between the vehicle position and the boarding location; At least one online-booked bus matching the new passenger's travel request is determined based on the driving direction and the relative position relationship.
3. The method according to claim 1, characterized in that The travel sites include at least a boarding site and an alighting site; The determining, based on the distances between at least some of the original sites and the travel sites, the relevant sites in each of the original site sequences corresponding to the travel sites, respectively, includes: Determine, based on the distance between at least some of the original sites and the boarding site, a first related site in each of the original site sequences corresponding to the boarding site; Based on the distance between at least part of the original sites and the alighting site, a second related site corresponding to the alighting site in each of the original site sequences is determined.
4. The method according to claim 3, characterized in that The relative position relationship includes that the travel station is located at a preceding position of the relevant station and that the travel station is located at a succeeding position of the relevant station.
5. The method according to claim 4, characterized in that The determining of at least one first candidate site sequence according to the relative position relationship between each of the travel sites and the corresponding related sites includes: At least one first candidate site sequence is determined based on the relative position relationship between the boarding site and the first related site, and the relative position relationship between the alighting site and the second related site.
6. The method according to claim 1, characterized in that The determining of a target planning route according to at least one of the first candidate site sequences comprises: Determine the travel cost corresponding to each of the first candidate site sequences, the travel cost comprising at least one of the route start-end distance, route length, travel time, and passenger waiting time; Determining a target site sequence from the first candidate site sequence according to the travel cost; Determine a target planning route corresponding to the target site sequence.
7. The method according to claim 6, characterized in that The determining of the travel costs corresponding to each of the first candidate site sequences includes: Determining the geographical location of each original site in each of the first candidate site sequences; Determining the start-end distance of the route according to the geographical location of the first original site and the geographical location of the last original site in the first candidate site sequence; Determine the corresponding route length according to the geographical location of each original site in each of the first candidate site sequences; Determining the travel time according to the route length and the average travel speed of the online-hailing bus; Determine the distance between the geographical location of the online-booked bus and the boarding station; The passenger waiting time is determined based on the distance and the average travel speed of the online-hailing bus.
8. The method according to claim 6, characterized in that The step of determining a target site sequence from the first candidate site sequence according to the travel cost includes: Determining a second candidate site sequence from the first candidate site sequence according to the route start-end distances corresponding to each of the first candidate site sequences; The target site sequence is determined from the second candidate site sequence according to the route length, the travel time and the passenger waiting time.
9. The method according to claim 3, characterized in that: The method further comprises: According to each of the original station sequences, the boarding stations and the alighting stations, a new station combination to be sorted is formed; Determining the vehicle position of each of the online-booked buses; Taking the vehicle position and the boarding station as starting points respectively, a nearest neighbor algorithm is used to determine a first candidate station sequence corresponding to each combination of stations to be sorted.
10. A route planning device, characterized in that: The device comprises: An acquisition module, used for acquiring a new passenger travel request, wherein the new passenger travel request includes a travel stop; A first determination module is used to determine at least one online-booked bus that matches the travel request of the new passenger; A second determination module is used to determine the original station sequence corresponding to each of the online-hailing buses, wherein the original station sequence is a sequence composed of the original stations that the online-hailing bus has not passed; A third determination module, configured to determine, based on distances between at least some of the original sites and the travel sites, the relevant sites in each of the original site sequences corresponding to the travel sites; A fourth determination module, configured to determine at least one first candidate site sequence according to a relative position relationship between each of the travel sites and the corresponding related sites; A fifth determination module is used to determine a target planning route based on at least one of the first candidate site sequences.
11. An electronic device comprising a memory and a processor, characterized in that: The memory is used to store one or more computer program instructions, wherein the one or more computer program instructions are executed by the processor to implement the method according to any one of claims 1 to 9.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 9 is implemented.
13. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the method according to any one of claims 1 to 9 is implemented.
Citation Information
Patent Citations
Passenger transport bus route planning method and device
CN107506864A
Subway shuttle bus route planning method based on route candidate set
CN107798440A
Route planning method and device and server
CN110991817A
Multi-station passenger transport line generation method and device, medium and electronic equipment
CN111738895A
Unmanned bus route planning method in multi-passenger mode
CN112781610A