Modify

Opened 7 weeks ago

Last modified 3 weeks ago

#23904 assigned task

Write new routing plugin

Reported by: taylor.smock Owned by: taylor.smock
Priority: normal Milestone:
Component: Plugin Version:
Keywords: routing Cc:

Description (last modified by taylor.smock)

Problem:
Mappers attempting to debug why a routing engine does stupid things or takes poor routes.

Solution:
Show mappers a route with route instructions as they edit live.

Goals:

  1. Use production routing engines
  2. Show routing instructions in JOSM for given modes (pedestrian, biking, vehicle, and possibly public transport)
  3. [Stretch goal] If routing engine supports it, show weights for ways in given mode; this should allow debugging why a different route was not chosen.

MVP will use one of the specified routing engines and show routing instructions in JOSM.
I am currently investigating using valhalla for the initial routing engine. This will most likely require Java 22 for FFI support without JVM flags. Alternatively, I can use JNI or a derivative thereof. As an additional alternative, if the routing engine exposes a web interface or a command line interface, we can use those for routing support.

Possible implementation details:
Valhalla (MIT):

  • Provides a C++ library (libvalhalla)
  • Provides a web interface
  • Provides a CLI

OSRM (BSD 2-clause):

  • Provides a C++ library
  • Provides a web interface

OSMAnd (GPLv3):

  • Java library and bindings already written (thanks to Android)
  • Has some kind of web interface (see comment:2)

Organic Maps (Apache 2):

  • Java library and bindings already written (thanks to Android)

Most likely, I will have to write the current edit layer to pbf in order to load it into a routing engine. There may be additional steps, such as converting the pbf to the engine specific format.


This plugin should completely replace the routing plugin which uses custom Java code for routing.

Attachments (0)

Change History (3)

comment:1 by taylor.smock, 7 weeks ago

Description: modified (diff)

comment:3 by taylor.smock, 3 weeks ago

Description: modified (diff)

I probably can't send the website arbitrary OSM data (AKA whatever the editor has changed); at a minimum, I'd have to spin up an instance on-device.

I could use it as a "status as of whenever OsmAnd updated their backend routing db".

Thanks for the information.

Modify Ticket

Change Properties
Set your email in Preferences
Action
as assigned The owner will remain taylor.smock.
as The resolution will be set. Next status will be 'closed'.
to The owner will be changed from taylor.smock to the specified user. Next status will be 'new'.
Next status will be 'needinfo'. The owner will be changed from taylor.smock to taylor.smock.
as duplicate The resolution will be set to duplicate. Next status will be 'closed'. The specified ticket will be cross-referenced with this ticket.

Add Comment


E-mail address and name can be saved in the Preferences .
 
Note: See TracTickets for help on using tickets.