GraphHopper: blazingly fast routes with OpenStreetMap

Playing with OpenStreetMap resources lately I came to the point where I wanted to calculate routes between points based on the OSM data. Now there is GraphHopper to the rescue! It’s opensource and awesome!

“GraphHopper offers memory efficient algorithms in Java for routing on graphs. E.g. Dijkstra and A* but also optimized road routing algorithms like Contraction Hierarchies. It stands under the Apache License and is build on a large test suite.”

GraphHopper
Source 1: http://graphhopper.com

5 thoughts on “GraphHopper: blazingly fast routes with OpenStreetMap

  1. Slightly off-topic for this post, but I’ve been playing with Miataru and the API. I notice that GetLocation returns the last location, but when I call GetLocationHistory, I am seeing that the results are returned from the beginning of the history. Is there a way to tell it to return X results from the end, e.g. last 5 locations?

    I looked at the source, and it seems like the call for the last X values in the LRANGE call to Redis should be returning from -X to -1, e.g. -5 to the last record (-1), but instead it is returning the first 5. Any way to get the last 5?

    1. Hi Scott

      thanks for raising that, in the iOS client I am just using “all” elements and parsing the rest out. So I’ve taken a look at the actual node.js server side and you were right. There was a problem with the return order. Specification says it’s newest first but the server returned the oldest first. I’ve bugfixed it some minutes ago. It’s up on https://service.miataru.com service and in the github repository.

      Thanks for using miataru!

      1. Perfect! Thanks for making the change so quickly.

        And thank you for providing the service. Is there a better place to report these little things? I hate to clog up your blog :)

          1. Thanks. I’ve been through most of the sour, but never stumbled across that.

            Thanks again.

Comments are closed.