JOSM/Plugins/PT Assistant/Routing helper
Two buttons were added to the relation editor. They are only activated when you open a PT v2 route relation for public transport itineraries.
- One of those buttons allows you to order the stops along the path of the ways in the route relation. If there are modifications, the relation is saved first, stops are reorderd and then the relation is saved again.
Caveat: there is still a bug when ways are traveled along twice (loops, spoons), the stops alongside it, are also added multiple times. So it's best to check whether this happened before closing the relation editor.
PT_Assistant's routing helper
This functionality will make mapping public transport accessible to all.
When you press the button, an overpass query download will occur which fetches all the ways suitable for the mode of transport of the route relation around the stops and around end nodes where the itinerary has gaps.
Then it will proceed to find a gap, and start following the way to the next intersection, heeding one way traffic rules and turn restrictions. When it arrives at an intersection, it will show the different possible options in different colours, which are linked to numbers.
There are 2 modes of operation
- Turn-by-Turn at each intersection.
- Fast-Forward mode looks at other route relations to get from the current way near the gap to the next way beyond the gap. If it finds another route relations which has a continuous sequence of ways in between, this is shown as a coloured option.
The second mode is only shown when such solutions are found. You can switch to it using 0.
Both the numbers on the numeric keypad as the ones above the standard keyboard can be used.
There are also some additional numbers which can be used:
- 9 to backtrack, i.e. remove the way currently marked in white from the route relation
- 7 to skip, i.e. reassess what the next 'goal' way - marked in grey - should be. This can come in handy if you would edit the relation manually in the relation editor, while the routing helper is active.
Ways that are shown in colours will be split as needed. The way in white is not split. If you need it to be split, backtrack first, then split it manually and move forward again. A future addition may be to use 8 to have it propose all its sideways as coloured options and split accordingly.
Gaps are not an issue for the routing helper, that's what it's supposed to remediate. What is important is that the remaining ways in between are in the correct order. Sometimes it's easier to simply remove more ways than strictly necessary. The routing helper will put them back in in a convenient way.
- en Via Peyrauds (16')
- Itinerary in France that should be a closed loop, but most of the ways are out of sequence. I first show how I would have fixed this previously (in a very time consuming way). Then I go ahead and do something very surprising: remove all oneway ways and roundabouts from the itinerary and all the ways that appear twice in it. Then I use the routing helper to close all the gaps again. It's not all going right from the first time. At 11'30" I go on to show how it can reorder the stops so they are in the order the ways are traversed. I also show that this still has a bug, when such stops are next to ways that are traverse more than once.
- en Outer Mudrika Service (OMS) (10')
- In this video I use the route relation for one direction of travel, to complete the opposite direction of travel. I use some tricks (the stops from the 'forward' direction of travel to know where the ways are supposed to be) and this can only be used as a starting point, as the resulting route never exits the motorway to serve stops. More work will be needed, but it's a nice demo of important changes that can be done in less than 10 minutes.
- en East of Paris (1h7')
- A route consisting of only stops. For adding the first and last way, I perform manual downloads around those stops. Then start the routing helper, which proceeds to downloading suitable highways for buses around those stops. Then it's mostly Turn-by-Turn, and it downloads missing data on-the-fly as it trudges along. The bug in the Overpass query that caused slow downloads upon startup, is now resolved.
- At 11'07" the first route now has all its ways added to it.
- At 12'10" work is started on another one that uses some of the same stops