Route GuidesRoutes City GuidesCities Map Log in

Curious about the RoutePlanning feature

1 Apr 2019
Find a better bike route. Try our map & route-planner »

Become a supporter

Hello, I'm working on an application that needs to provide runners with routes of specified length. The routeing for cycle.travel is really good, and I would love to see what steps were taken to accomplish it. 

What open source software was used, how was it augmented?

How large is the uncompressed network that was generated from the OSM data, and how was that built?

How did you approach creating the routes?

I've done some querying but I can't seem to find any blog posts or other information about solving this problem, it would also be very helpful to maybe get be pointed to some resources.  

Thank you. 

Comments

Wed 3 Apr 2019, 11:05

cycle.travel's routing is ultimately based on OSRM. It's an extensive fork of OSRM 4.9, with changes including new 'plugins' for circular routes, memory-efficient elevation support, two routing graphs (any/paved), and turn handling rewritten to be bike-centric rather than car-centric. The routing graphs for Europe and North America altogether take up about 50GB of RAM (including elevation data) - though as always with OSRM, generating them in the first place takes more.

The route quality is largely a result of the custom profile, which parses OSM tags for each way and makes a quality assessment based on that. OSRM's Lua profile approach is very powerful, and cycle.travel augments this with some additional preprocessing.

Most of OSRM's development since 5.0 has been geared more towards car navigation and memory usage has grown. Valhalla and Graphhopper are also worth looking at, and in particular you may find that Graphhopper is more memory-efficient for your purposes. (OSRM's implementation of Contraction Hierarchies takes up a lot of memory in order to support turn restrictions, which obviously aren't an issue for foot navigation.)

Consulting and custom routing development is part of what I do to keep a roof over my head (and enable me to keep working on cycle.travel!), so feel free to drop me a line at [email protected].