[GraphHopper] Shortest route failed (ferry issue?)
Peter
graphhopper at gmx.de
Sat Aug 22 17:01:51 UTC 2015
Hi Martin,
thanks again for the report, really important to get this fixed! I've
created an issue as something seems wrong:
https://github.com/graphhopper/graphhopper/issues/501
Let us move the discussion there.
Regards,
Peter
On 16.08.2015 16:18, Martin Sauvage wrote:
> Hello Peter,
>
> I'm pretty sure there is a problem with this specific ferry link
> (named "Bac Indret") even with the latest version of GH. I tried on
> other ferry link and GH works fine.
>
> If you test this:
> https://graphhopper.com/maps/?point=47.19415%2C-1.676384&point=47.19747%2C-1.671832&locale=fr-FR&layer=Lyrk
>
> You will see only bikes take the ferry while foot and car do not use it.
>
> OSM tags for this ferry seem to be fine (use duration and opening hour
> tags also)
>
> In addition, using directions thru OSM web site, MapQuest or OSRM
> provides correct route while GH meets some issue (route is not found)
>
> http://www.openstreetmap.org/directions?engine=mapquest_foot&route=47.19498%2C-1.67554%3B47.19774%2C-1.67202
>
> Regards,
> Martin
>
>
>
>
>
>
> 2015-07-13 10:32 GMT+02:00 Peter <graphhopper at gmx.de
> <mailto:graphhopper at gmx.de>>:
>
> Hi Martin,
>
> hmmh, if the speed is somehow calculated to be 0 then the access
> should be set to false making the ferry no longer available. And
> if the speed is not 0 then the exception should not be thrown.
>
> Additionally in this case I see that the unknownSpeed *should* be
> selected but it should be 5km/h (living_street):
> https://github.com/graphhopper/graphhopper/blob/master/core/src/main/java/com/graphhopper/routing/util/AbstractFlagEncoder.java#L512
>
> https://github.com/graphhopper/graphhopper/blob/master/core/src/main/java/com/graphhopper/routing/util/CarFlagEncoder.java#L283
>
> Maybe you can debug this a bit and tell if the speed of the edge
> is 0 or not and why.
>
> Also when switching branches make sure you remove the target
> folders and/or rebuild in your IDE.
>
> Regards,
> Peter
>
>
> On 10.07.2015 18:35, Martin Sauvage wrote:
>> Hi,
>>
>> I tried on master and I still got the same illegal state
>> exception, so apparently ZhiQiang fix doesn't solve the problem
>> (is it a ferry link only issue?).
>> Any idea?
>>
>> Thanks,
>> Martin
>>
>>
>>
>> 2015-07-10 10:50 GMT+02:00 Peter <graphhopper at gmx.de
>> <mailto:graphhopper at gmx.de>>:
>>
>> Hi Martin, Hi ZhiQiang,
>>
>> this could be related to the bug ZhiQiang mentioned but this
>> was already fixed:
>> https://github.com/graphhopper/graphhopper/issues/367
>>
>> This can only occur for shortest path routing:
>> https://github.com/graphhopper/graphhopper/issues/242
>>
>> Martin, do you use master or a 0.4 branch?
>>
>> Regards,
>> Peter
>>
>> On 09.07.2015 19:46, John Zhao wrote:
>>> Hi Martin,
>>>
>>> I have face the same problem.
>>> At last I found it caused by maxspeed=3 in the osm data.
>>> carFlagEncoder use 5 as factor of speed encoding.
>>> every number below 5 will be convert to 0.
>>>
>>> Then you will have some edges in the graph with speed=0.
>>>
>>> *Best Regards,*
>>> *ZhiQiang ZHAO*
>>>
>>> On Thu, Jul 9, 2015 at 5:20 AM, Martin Sauvage
>>> <martin.sauvage at gmail.com <mailto:martin.sauvage at gmail.com>>
>>> wrote:
>>>
>>> Hello,
>>>
>>> I'm facing an issue when routing with shortest path
>>> between these 2 GPS points:
>>> 47.194150,-1.676384
>>> 47.197470,-1.671832
>>>
>>> Caused by: java.lang.IllegalStateException: Speed cannot
>>> be 0 for unblocked edge, use access properties to mark
>>> edge blocked! Should only occur for shortest path
>>> calculation. See #242.
>>>
>>> I suspect the shortest route tries to take the ferry
>>> (Bac Indret) with no defined speed while the fastest
>>> route provides:
>>> https://graphhopper.com/maps/?point=47.19415%2C-1.676384&point=47.19747%2C-1.671832&locale=fr-FR&layer=Lyrk
>>>
>>> Is it a GH bug or an OSM data issue? Is there any way to
>>> fix this crash (do not take ferry with shortest route) ?
>>>
>>> Thanks,
>>> Martin
>>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/graphhopper/attachments/20150822/691b21f1/attachment.html>
More information about the GraphHopper
mailing list