[OSRM-talk] how exactly is "duration" in route service calculated?

Günther S guenther_slx at yahoo.de
Mon Nov 27 20:17:07 UTC 2017


Ah, great!Thanks Daniel for the detailed answer! 
G

 

    Daniel Patterson <daniel at mapbox.com> schrieb am 20:30 Montag, 27.November 2017:
 

 Hi Gunther,
  You've got the start/end points opposite for those two queries - the routes aren't the same (and thus, are very different in duration..  If you swap the start/end points on the OSRM route, you'll get 6.7 minutes as the result, and the path matches what Google is returning.

  Make sure you zoom in in the UI and make sure the coordinates have snapped to the same location for both routing engines if you're doing a comparison.
  To answer the rest of your question, OSRM uses:
    1) Tag information available in OpenStreetMap to decide on road speeds.    2) The OSRM demo server *also* has Mapbox traffic data loaded on top
  If you run your own OSRM server, you will just get (1).
  You can read through the script that decides on OSM-based speeds here:  https://github.com/Project-OSRM/osrm-backend/blob/master/profiles/car.lua  This script looks at tags on OSM ways and decides on a basic speed for every road.
daniel
On Mon, Nov 27, 2017 at 9:41 AM, Günther S <guenther_slx at yahoo.de> wrote:

Hi there,
I would like to know how the "duration" is calculated exactly.What is the data basis for this calculation?- predefined speed per segment (where to get that speed)?- is real traffic information somehow considered?
For instance:this request returns 1037.9sec = 17.3 minhttp://router.project-osrm. org/route/v1/driving/5. 39952890748535,52. 1960411446193;5.4446426827156, 52.1682341727178?overview= false


on the other hand, google calculates 7min for the fastest route:https://www.google.at/maps/ dir/52.1682341727178+5. 4446426827156/52.1960411,5. 3995289/@52.1889039,5.387444, 14z/data=!3m1!4b1!4m7!4m6!1m3! 2m2!1d5.4446427!2d52.1682342! 1m0!3e0?hl=en

thanks,Guenther
______________________________ _________________
OSRM-talk mailing list
OSRM-talk at openstreetmap.org
https://lists.openstreetmap. org/listinfo/osrm-talk



_______________________________________________
OSRM-talk mailing list
OSRM-talk at openstreetmap.org
https://lists.openstreetmap.org/listinfo/osrm-talk


   
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/osrm-talk/attachments/20171127/1cf59530/attachment.html>


More information about the OSRM-talk mailing list