Hi Daniel,

Thank you for answer
I understand well the issue here

Would it be acceptable to specify coordinates storage precision in a next
release ?

Nevertheless, I got that it won't impact a lot my routing results.

All the best

François

2018-02-28 20:37 GMT+01:00 Daniel Patterson <[email protected]>:

> Hi François,
>
>   What you are seeing is rounding error.
>
>   Internally, OSRM only stores the "duration" of each segment, with a
> resolution of 0.1 seconds.  On the map, the speed is calculated by taking
> the length of the segment, and dividing it by the "duration" value.
>
>   We store longitude/latitude to 6 decimal places, so they have
> approximately 10cm precision (https://en.wikipedia.org/
> wiki/Decimal_degrees) depending on your latitude.  This precision means
> that calculating the length of a segment is limited to +/- approx 10cm
> precision as well.
>
>   Both of these precision limits compound for short segments when
> displayed on the map, and sometimes the speed values look weird.
>
>   However, they do not affect route selection very much, because routing
> is done by accumulating time, and short segments generally only add small
> amounts of time to the routing decision.
>
> daniel
>
>
>
> On Wed, Feb 28, 2018 at 10:41 AM, François Lacombe <
> [email protected]> wrote:
>
>> Hi,
>>
>> While investigating for flaws in a custom profile I'm trying to write, I
>> discovered that arbitrary small ways got strange speed regarding the rules
>> I used.
>>
>> Here is an extract from osrm-frontend debug
>> https://imgur.com/a/L8coz
>>
>> All segments on the red line have the same attributes.
>> I don't understand why the small parts in the middle got really slower
>> speed than the longer ones.
>> Do you have any idea?
>>
>> The purple road with 0km/h speed is normal and expected.
>>
>>
>> Thank you for any hint
>>
>> Thanks in advance
>>
>> François
>>
>> _______________________________________________
>> OSRM-talk mailing list
>> [email protected]
>> https://lists.openstreetmap.org/listinfo/osrm-talk
>>
>>
>
> _______________________________________________
> OSRM-talk mailing list
> [email protected]
> https://lists.openstreetmap.org/listinfo/osrm-talk
>
>
_______________________________________________
OSRM-talk mailing list
[email protected]
https://lists.openstreetmap.org/listinfo/osrm-talk

Reply via email to