Specific embodiment
Theme described herein is discussed referring now to each embodiment.It should be understood that discussing that these embodiments are only
In order to enable those skilled in the art can better understand that and realize theme described herein, be not to claims
Middle illustrated protection scope, applicability or exemplary limitation.It can be in the feelings for the protection scope for not departing from claims
Under condition, the function and arrangement of the element discussed are changed.Each embodiment can according to need, omit, replace or
Add various processes or component.
Public transport network figure can indicate the connected graph of public traffic network.In public transport network figure, it can be indicated by node
The website of public transport bus or subway.It can be attached by line between node, this line is properly termed as side.It side can be with table
Show the public bus network run between website.Side can also have weight, when weight can indicate the distance between website or operation
It is long.Since public bus network all has directionality, while can be the directive line of tool.
With the development of public transport, public bus network is increasingly complicated, this, which may cause public transport network figure also, becomes increasingly
It is complicated.For example, different public bus networks may have common site, in this way, between these routes can by common site into
Row transfer, such case can be referred to as with station transfer.It, may in order to represent this transfer situation in public transport network figure
It will increase the complexity of figure.
In the first implementation, in public transport network figure, a node can be used to indicate the public affairs of different routes
Co-sited point, then these routes may share the side of common site.In this case, it is possible to can not be in public transport network figure
Embody the otherness of different routes.For example, for bus rapid transit and common public transport, although by two identical stations
Point, but its operation duration between the two websites is different, and shared side is beyond expression this species diversity.Again
For example, the departure interval of different routes may be different, waiting time may also be different, then the case where being changed to for same station, altogether
The side enjoyed also is beyond expression out waiting times of different routes.
In the second implementation, in public transport network figure, different nodes can be used to indicate each route
Website.For being able to carry out the website of route transfer, transfer side can be added between corresponding node.
For ease of description, it is illustrated below by specific example.It should be understood that in following Figure 1A -1C,
For ease of description, a certain number of routes and website are shown, it being understood, however, that, it can be in different scenes
There are the route of different number and websites.
Figure 1A shows a kind of schematic diagram of simple scene.In the scene of Figure 1A, 2 routes, every line are shown
Road has 4 websites.For example, route 1 can have website 1a, 2a, 3a and 4a, route 2 can have website 1b, 2a, 3a and
4b.As it can be seen that route 1 and route 2 can have common site 2a and 3a, i.e. route 1 and route 2 sharing site 2a and 3a.
For the scene of Figure 1A, public transport network figure can be constructed using above two mode.
Figure 1B shows the schematic diagram of an example of the public transport network figure for the scenario building of Figure 1A.
Public transport network Figure 110 shown in Figure 1B, which can be using the first above-mentioned implementation, to be constructed.That is, each public affairs
Co-sited o'clock is indicated using a node.
As shown in Figure 1B, in public transport network Figure 110, website 1a, 2a, 3a and 4a in route 1 can be used node A,
B, C and D indicates that node E, B, C and F can be used to indicate in website 1b, 2a, 3a and 4b in route 2.As it can be seen that 1 He of route
A node B can be used to indicate in the shared website 2a of route 2, and the website 3a that route 1 and route 2 are shared can be used one
Node C is indicated.Correspondingly, route 1 and the route 2 also side between shared node B and C.
Due to the side between route 1 and 2 shared node B of route and C, so public transport network Figure 110 can not describe 1 He of route
The otherness of runing time of the route 2 between node B and C.In addition, at the station that the node B website 2a indicated or node C is indicated
At point 3a, it can be changed between route 1 and route 2.But in public transport network Figure 110, it can not describe in node B
Or transfer time when being changed at node C, i.e. waiting time of route 1 or route 2.
Fig. 1 C shows the schematic diagram of another example of the public transport network figure for the scenario building of Figure 1A.
Public transport network Figure 120 shown in Fig. 1 C, which can be using above-mentioned second of implementation, to be constructed.That is, every line
The website on road is all indicated using different nodes.
As shown in Figure 1 C, in public transport network Figure 120, website 1a, 2a, 3a and 4a in route 1 can be used node A,
B1, C1 and D indicate that node E, B2, C2 and F can be used to indicate in website 1b, 2a, 3a and 4b in route 2.As it can be seen that needle
To route 1 and route 2, the website 2a that route 1 and route 2 are shared can be indicated using node B1 and B2 respectively.In addition, being directed to
Route 1 and route 2 can indicate the website 3a that route 1 and route 2 are shared using node C1 and C2 respectively.
Due to that can be changed between route 1 and route 2 at website 2a or 3a.Therefore, can in node B1 and
Addition transfer side (that is, two between node B1 and B2 directive lines 121 and 122 of tool) between B2, and can be
Addition transfer side (that is, two directive lines 123 and 124 of tool between node C1 and C2) between node C1 and C2, from
And indicate this with station transfer situation.
In this public transport network Figure 120, the weight on the side between node can be conclusivelyed show stands in respective lines
The distance between point or operation duration.In addition, due to indicating common site by different nodes, so between these nodes
The weight on transfer side can describe the transfer time.For example, the weight on transfer side 121 can describe the website 2a indicated in node B1
Place, from the transfer of route 1 to the transfer time of route 2;The weight on transfer side 122 can describe the website 2a indicated in node B1
Place, from the transfer of route 2 to the transfer time of route 1.In the case of it is also similar for changing to side 123 and 124.
Although this implementation solves the problems, such as the first above-mentioned implementation, in this way
The structure of the public transport network figure of building is relative complex.For example, when the same website of many Line sharings, due to the combination side of transfer
There are many formula, so needing to introduce many transfer sides, this, which will lead to public transport network figure, becomes extremely complex, not manageability.Moreover,
Processing workload is also larger when needing to add route or modification route.
In order to illustrate such case, Fig. 1 D shows the schematic diagram of another example of public transport network figure.
In Fig. 1 D, it is assumed that 4 Line sharings, one website.In public transport network figure, can be used 4 node G1, G2,
G3 and G4 indicates the website.Transfer side can be added, between node G1, G2, G3 and G4 so that indicate can between 4 routes
To be changed at shared website.
It should be understood that for ease of description, Fig. 1 D illustrate only node G1, G2, G3 and G4 and they between
Transfer side, and complete public transport network figure is not shown.
As shown in figure iD, for 4 Line sharings, one website the case where, needs using 12 transfer sides.So, it is assumed that
The number of, lines for sharing same website is K, then the quantity for changing to side will be K* (K-1).As it can be seen that as public bus network increasingly increases
More, the number of, lines with same common site may be very more, in this way, public transport network figure can be extremely complex, are not only not easy pipe
Reason, and when needing to change route or addition route, workload is also very big.
In this regard, present description provides a kind of technical solutions for public transport path planning.It in the technical scheme, can be with
Determine that the first website is the common site of N route, wherein N is the positive integer greater than 1.Then, public transport network figure is generated.It should
Public transport network figure may include above-mentioned N route and the first dummy node.First website can be by being located in N route
N number of node indicates.N number of node, which can respectively have between the first dummy node, changes to side, and any two in N number of node
Do not have transfer side between a node.
Specifically, the website of every route can be used different nodes and carry out table in public transport network figure generated
Show.So, for the first website of N Line sharing, N number of node can be used to indicate.Due to can between N route
To be changed to by first stop point, in order to represent such case in public transport network figure, the first dummy node can be added.
It indicates that N number of node of the first website can have between the first dummy node respectively and changes to side, and any two in N number of node
Do not have transfer side between a node.
Obviously, in the technical scheme, by introducing dummy node, the quantity with station transfer side becomes 2N.In this way, not only
Difference and transfer information (such as transfer time) between different routes can be described in public transport network figure, and being capable of letter
Change public transport network figure, consequently facilitating management.In addition, can also greatly reduce work when needing to add route or modification route
It measures.
Later, it can be based on public transport network figure generated, carry out public transport path planning.For example, can be in conjunction with user's
Trip data (such as set out website and arrival website), is based on public transport network figure, determines the shortest path between two websites, make
For the simulation travel route of user.In this way, obtaining the simulation traffic path of a large number of users by analysis, different trips can be determined
The estimation volume of the flow of passengers on route.Thus, it is possible to public transport path further reasonably be planned, for example, when adjustment website, public transport operation
Between or the frequency of dispatching a car, addition route etc..
Fig. 2 is the schematic flow chart according to the method for public transport path planning of one embodiment.
As shown in Fig. 2, in step 202, can determine that the first website is the common site of N route, wherein N is big
In 1 positive integer.
In step 204, public transport network figure can be generated.
Wherein, which may include above-mentioned N route and the first dummy node.First node can be by respectively
N number of node in above-mentioned N route indicates.N number of node can respectively have transfer side between the first dummy node,
And do not have transfer side between any two node in N number of node.
In step 206, it can be based on public transport network figure generated, carry out public transport path planning.
As it can be seen that in the technical scheme, the common site of a plurality of route, Neng Gou are indicated by using different nodes
Otherness between each route is effectively described in public transport network figure.Moreover, because in each node for indicating common site
There is transfer side between dummy node, and indicate do not have direct transfer side between each node of common site, so
It can not only accurately indicate transfer situation of each route between common site, and transfer side can be greatly reduced
Quantity effectively simplifies the structure of public transport network figure.In this way, when needing to add route or modification route, it also can be greatly
Reduce processing workload.
The case where in addition to the transfer of same station, it is likely present the case where different station is changed to.Different station transfer can refer between route
It is needed when transfer through two different websites.For example, slave site 1 walks to website 2, to change to the route by website 2.
In public transport network figure, different station is changed to, can be indicated by adding transfer side between corresponding node.For example, can
To use node 1 to indicate that website 1, node 2 indicate website 2.Transfer side can be added between node 1 and node 2, to indicate
Route via website 1 and the transfer situation between the route via website 2.It will be retouched below for different station transfer situation
It states.
In one embodiment, it can determine and be able to carry out route transfer between the first website and the second website.Second station
Point may belong to second route different from above-mentioned N route, and the second website can be not common website.
In step 204, public transport network figure generated can also include the second route.Second website can be by being located at the
Second node in two routes indicates.It can be in order to indicate different station transfer situation, between the first dummy node and second node
With transfer side.In this way, it is only necessary to introduce two different station transfer sides to indicate the transfer feelings between N route and the second route
Condition.
However, if generating public transport network figure using second of implementation above, then it represents that the first website it is N number of
It requires to add different station transfer side between node and second node, then will introduce the different station of 2N item changes to side.
As it can be seen that the quantity on the different station transfer side in public transport network figure can be greatly reduced by introducing dummy node, from
And simplify the structure of public transport network figure, it is convenient for managing.
In another embodiment, it can determine and be able to carry out route transfer between the first website and third website.Third station
Point can be the common site of the M route different from above-mentioned N route, and M is the positive integer greater than 1.
In step 204, public transport network figure generated can also include M route and the second dummy node.Third station
Point can be indicated that M node can respectively have between the second dummy node by M node being located in M route
There is transfer side, and does not have transfer side between any two node in M node.In order to indicate the first website and third website
Between different station change to situation, can have between the first dummy node and the second dummy node transfer side.In this way, it is only necessary to draw
Enter two different station transfer sides to indicate the transfer situation between above-mentioned N route and above-mentioned M route.
In this case, it if generating public transport network figure using second of implementation above, needs N number of
Different station transfer side is all added between node and M node, the quantity on different station transfer side in this way will be 2*N*M.
As it can be seen that in this embodiment, by introducing dummy node, the different station that can be greatly reduced in public transport network figure is changed
Multiply the quantity on side, to effectively simplify public transport network figure, is convenient for managing.
It is understood that can include the weight on each side in public transport network figure generated.For example, can will weigh
It is labeled at corresponding side again.
In order to make it easy to understand, being described below in conjunction with specific example.It should be appreciated that these examples merely to
It helps those skilled in the art to more fully understand the technical solution of this specification, and is not intended to limit its range.
Fig. 3 A is the partial schematic diagram according to the public transport network figure of one embodiment.
In the scene of Fig. 3 A, it is assumed that 4 Line sharing websites 1.In public transport network figure generated, for this 4
Route can indicate website 1 using node H1, H2, H3 and H4 respectively.Furthermore, it is possible to add dummy node H '.
In order to indicate that situation is changed at the same station of website 1, as shown in Figure 3A, node H1, H2, H3, H4 can respectively and virtually
There is transfer side between node H ', and all do not have transfer side between any two node in node H1, H2, H3, H4.It can
See, in the scene of Fig. 3 A, it is only necessary to change to situation to indicate to stand together in 8 transfer sides.
In addition, the weight on transfer side can describe the transfer time.For example, the transfer side from node H1 to dummy node H '
The duration of getting off of route where weight can indicate node H1.Duration of getting off can be according to the actual situation or the factors such as experience and
Preset value, such as 1 minute.Route where the weight on the transfer side from dummy node H ' to node H1 can indicate node H1
Waiting time.
As it can be seen that in this way, not only clearly indicating that with station transfer situation, but also effectively reduce and changed with station
The quantity for multiplying side greatly simplifies public transport network figure.
It should be appreciated that for ease of description, Fig. 3 A illustrates only relevant node and transfer side, and has not showed that
Whole public transport network figure.
In addition, it is to be understood that not showing that the weight on each side in figure 3 a to simplify attached drawing.But in reality
It may include the weight on each side in the public transport network figure on border.For example, can by it is each while weight be labeled in this while it is attached
Closely.
Fig. 3 B is the partial schematic diagram of public transport network figure according to another embodiment.
In the scene of Fig. 3 B, it is assumed that 4 Line sharing websites 1.In public transport network figure generated, for this 4
Route can indicate website 1 using node H1, H2, H3 and H4 respectively.Furthermore, it is possible to add dummy node H '.In order to indicate
Situation is changed at the same station of website 1, and node H1, H2, H3, H4, which can respectively have between dummy node H ', changes to side, and node
All do not have transfer side between any two node in H1, H2, H3, H4.
Moreover, it is assumed that different station transfer can be carried out between website 1 and website 2.Website 2 is non-common site.Website 2 can be with
It is indicated using node I.
In order to indicate that situation is changed at the different station between website 1 and website 2, as shown in Figure 3B, dummy node H ' and node I it
Between can have different station transfer side.As it can be seen that in the scene of Fig. 3 B, it is only necessary to which 2 transfer sides indicate this different station transfer feelings
Condition.
In addition, the weight on different station transfer side can describe the time from a website to another website (for example, passing through step
The modes such as row, cycling).For example, the weight on the transfer side from dummy node H ' to node I can indicate that slave site 1 is arrived at a station
Point 2 time, and the weight on the transfer side from node I to dummy node H ' can indicate slave site 2 to website 1 time.
As it can be seen that in this way, not only clearly indicating that and changing to situation with station transfer and different station, but also effectively subtract
The quantity for having lacked transfer side, greatly simplifies public transport network figure.
It should be appreciated that for ease of description, Fig. 3 B illustrates only relevant node and transfer side, and has not showed that
Whole public transport network figure.
In addition, it is to be understood that not showing that the weight on each side in figure 3b to simplify attached drawing.But in reality
It may include the weight on each side in the public transport network figure on border.For example, can by it is each while weight be labeled in this while it is attached
Closely.
Fig. 3 C is the partial schematic diagram of public transport network figure according to another embodiment.
In the scene of Fig. 3 C, it is assumed that 4 Line sharing websites 1.In public transport network figure generated, for this 4
Route can indicate website 1 using node H1, H2, H3 and H4 respectively.Furthermore, it is possible to add dummy node H '.In order to indicate
Situation is changed at the same station of website 1, and node H1, H2, H3, H4, which can respectively have between dummy node H ', changes to side, and node
All do not have transfer side between any two node in H1, H2, H3, H4.
In addition, in the scene of Fig. 3 C, it is assumed that 4 Line sharing websites 3.In public transport network figure generated, for
This 4 routes, can indicate website 3 using node J1, J2, J3 and J4 respectively.Furthermore, it is possible to add dummy node J '.For
Indicating that situation is changed at the same station of website 3, node J1, J2, J3 and J4 can respectively have transfer side between the dummy node J ',
And all do not have transfer side between any two node in node J1, J2, J3 and J4.
Moreover, it is assumed that different station transfer can be carried out between website 1 and website 3.
In order to indicate that situation is changed at the different station between website 1 and website 3, as shown in Figure 3B, dummy node H ' and virtual section
It can have different station transfer side between point J '.As it can be seen that in the scene of Fig. 3 B, it is only necessary to which 2 transfer sides indicate this different station
Change to situation.
In addition, the weight on different station transfer side can describe the time from a website to another website (for example, passing through step
The modes such as row, cycling).For example, the weight on the transfer side from dummy node H ' to dummy node J ' can indicate slave site 1
To the time of website 3, and the weight on the transfer side from dummy node J ' to dummy node H ' can indicate slave site 3 to website 1
Time.
As it can be seen that in this way, not only clearly indicating that and changing to situation with station transfer and different station, but also effectively subtract
The quantity for having lacked transfer side, greatly simplifies public transport network figure.
It should be appreciated that for ease of description, Fig. 3 C illustrates only relevant node and transfer side, and has not showed that
Whole public transport network figure.
In addition, it is to be understood that not showing that the weight on each side in fig. 3 c to simplify attached drawing.But in reality
It may include the weight on each side in the public transport network figure on border.For example, can by it is each while weight be labeled in this while it is attached
Closely.
Fig. 4 is the schematic block diagram according to the device for public transport path planning of one embodiment.
As shown in figure 4, device 400 can include determining that unit 402, generation unit 404 and planning unit 406.
Determination unit 402 can determine that the first website is the common site of N route, wherein N is the positive integer greater than 1.
Public transport network figure can be generated in generation unit 404.Public transport network figure includes N route and the first dummy node, the first website by
N number of node in N route is located to indicate, N number of node respectively has transfer side between the first dummy node, N number of
Do not have transfer side between any two node in node.Planning unit 406 can be based on public transport network figure, carry out public transport road
Diameter planning.
As it can be seen that in the technical scheme, the common site of a plurality of route, Neng Gou are indicated by using different nodes
Otherness between each route is effectively described in public transport network figure.Moreover, because in each node for indicating common site
There is transfer side between dummy node, and indicate do not have direct transfer side between each node of common site, so
It can not only accurately indicate transfer situation of each route between common site, and transfer side can be greatly reduced
Quantity effectively simplifies the structure of public transport network figure.In this way, when needing to add route or modification route, it also can be greatly
Reduce processing workload.
In one embodiment, determination unit 402, which can also determine, is able to carry out line between the first website and the second website
Road transfer, wherein the second website belongs to second route different from N route, and the second website is non-common site.
The public transport network figure that generation unit 404 generates can also include the second route, and the second website is by being located at the second route
In second node indicate that there is between the first dummy node and second node transfer side.
In another embodiment, determination unit 402, which can also determine, is able to carry out line between the first website and third website
Road transfer, wherein third website is the common site of the M route different from N route, and M is the positive integer greater than 1.
Generation unit 404 generate public transport network figure can also include M route and the second dummy node, third website by
M node being located in M route indicate, M node respectively has a transfer side between the second dummy node, M
Do not have transfer side between any two node in node, there is transfer between the first dummy node and the second dummy node
Side.
Each unit of device 400 can execute the corresponding steps in the embodiment of the method for Fig. 2-3C, therefore, in order to describe
It is succinct, details are not described herein again for the concrete operations of each unit of device 400 and function.
Above-mentioned apparatus 400 can use hardware realization, can also use software realization, or can pass through the group of software and hardware
It closes to realize.For example, device 400 when using software realization, (can be compared memory by the processor of equipment where it
Such as nonvolatile memory) in corresponding executable instruction be read into memory operation to be formed.
Fig. 5 is the hardware structure diagram according to the calculating equipment for public transport path planning of one embodiment.Such as Fig. 5 institute
Show, calculating equipment 500 may include at least one processor 502, memory 504, memory 506 and communication interface 508, and extremely
A few processor 502, memory 504, memory 506 and communication interface 508 link together via bus 510.At least one
Processor 502 executes at least one executable instruction for storing or encoding in memory 504 (that is, above-mentioned real in a software form
Existing element).
In one embodiment, the executable instruction stored in memory 504 is executed by least one processor 502
When, so that calculating equipment realizes the above various processes in conjunction with Fig. 2-3C description.
Calculating equipment 500 can be realized using any applicable form in this field, for example, it is including but not limited to desk-top
Computer, laptop computer, smart phone, tablet computer, consumer-elcetronics devices, wearable smart machine etc..
The embodiment of this specification additionally provides a kind of machine readable storage medium.The machine readable storage medium can be deposited
Executable instruction is contained, executable instruction makes machine realize that the method described above with reference to Fig. 2-3C is real when being executable by a machine
Apply the detailed process of example.
For example, machine readable storage medium can include but is not limited to random access memory (Random Access
Memory, RAM), read-only memory (Read-Only Memory, ROM), electrically erasable programmable read-only memory
(Electrically-Erasable Programmable Read-Only Memory, EEPROM), static random access memory
Device (Static Random Access Memory, SRAM), hard disk, flash memory etc..
It should be understood that each embodiment in this specification is all made of progressive mode to describe, each embodiment
Between the same or similar part cross-reference, the highlights of each of the examples are it is different from other embodiments it
Place.For example, for the above-mentioned embodiment about device, about the embodiment for calculating equipment and about machine readable storage medium
Embodiment for, since they are substantially similar to embodiment of the method, so be described relatively simple, related place is referring to method
The part of embodiment illustrates.
This specification specific embodiment is described above.Other embodiments are in the scope of the appended claims
It is interior.In some cases, the movement recorded in detail in the claims or step can be come according to the sequence being different from embodiment
It executes and desired result still may be implemented.In addition, process depicted in the drawing not necessarily require show it is specific suitable
Sequence or consecutive order are just able to achieve desired result.In some embodiments, multitasking and parallel processing be also can
With or may be advantageous.
It should be understood that those skilled in the art, being carried out to the embodiment in this specification each
Kind modification will be apparent, and can will determine herein in the case where not departing from the protection scope of claims
The general principle of justice is applied to other modifications.