Skip to content

Avoid access=destination for bike and foot as well - #1272

Closed
boldtrn wants to merge 2 commits into
graphhopper:masterfrom
boldtrn:issue_733_bike
Closed

boldtrn wants to merge 2 commits into
graphhopper:masterfrom
boldtrn:issue_733_bike

Conversation

@boldtrn

@boldtrn boldtrn commented Jan 19, 2018

Copy link
Copy Markdown
Member

This PR should fix #733. It adds support for access=destination tags.

I unfortunately needed to not only change the priority but also the speed. Some cases might have been solved by the priority only, but all 3 cases by @ftrebien, reported here, were not properly solved by only changing the Priority.

If you look at the examples, the generated detour is sometimes huge, e.g. 500m instead of 80m.

BTW: The changed test in GraphHopperIT is actually a nice improvement. It misses an unnecessary continue instruction. I debugged it and it seems like there was a small road with access=destination (it's not there in the current OSM data anymore). The small road with access=destination had the same name like the current road and the same flags. Now that we change the flags for roads with access=destination, the instruction get's ignored here.

else
weightToPrioMap.put(110d, priorityFromRelation);

if (isWayAccessDestination(way))

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We could merge this and the above isWayAccessDestination. But then we would change the Priority outside of the handlePriority method, which I don't like that much. I can change it if you would prefer that?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to me.

@karussell

karussell commented Jan 22, 2018 •

Copy link
Copy Markdown
Member

If you look at the examples, the generated detour is sometimes huge, e.g. 500m instead of 80m.

I'm not sure if anybody sane would do such a detour with a bike, if the area is just "destination only". Ugly. Maybe we should handle them as "pushing sections"?

@boldtrn

boldtrn commented Jan 23, 2018

Copy link
Copy Markdown
Member Author

I'm not sure if anybody sane would do such a detour with a bike, if the area is just "destination only".

In theory "destination only" should be handled by a routing engine as exactly that. Only route over a road with destination only, if this is the only road that leads to the destination, otherwise use a different road. There might be examples where driving through an "destination only" area could result in a fine or in inconvenience for users following the route.

But, I looked at the tags in overpass and saw that there are many incorrectly tagged roads in Germany. Instead of motor_vehicle=destination, they contain just access=destination. This is often true for roads that might be very well suited for cycling.

Now I am not sure anymore if we should enforce the destination tag, as pushing section, avoid it, or don't do anything (current behavior). If we start avoiding it or use it as a pushing section, this could raise awarness of this problem in OSM and maybe slowly lead to improved data quality. Maybe your proposal to use it as pushing section might be a good solution, maybe enforcing an instruction, "get off the bike, access destination".

If you look at the examples in #733 on streetview: example1 (should probably be tagged with access=customer) example2 (should maybe be tagged as private?), example3 (should maybe be tagged access=private); I would not want to drive through any of them with a bicycle. But I am also not sure if they are tagged correctly. @ftrebien, are you sure that the examples are tagged correctly or could they be tagged differently, like access=private|customer?

@karussell

Copy link
Copy Markdown
Member

This is often true for roads that might be very well suited for cycling.

Yes, exactly. Similar to the "default"-problem of barriers and fords

@ftrebien

ftrebien commented Jan 23, 2018 •

Copy link
Copy Markdown

@boldtrn Hm maybe example 3 is probably incorrectly tagged, so I apologize, but I should note the router shouldn't suggest that route anyway if the correct value was indeed the current one.

Examples 2 and 1 are indeed bicycle/foot/motor_vehicle=destination because everyone can access the area if they are going there for the service (shopping at the mall or using government services). Those could be mapped as bicycle=dismount, but that by itself would not represent the idea that the cyclist should not simply go through the property. If the cyclist must get out of the bike and push, and the cyclist also cannot go through the property if it is not the destination, then the only possible mappings today are bicycle=destination or bicycle=dismount + access=destination (if the restriction on passing through applies to all other modes too).

access=customers was born in combination with amenities, so its usage with the highway tag is still somewhat lower than access=destination. Before it was born, destination was used for that purpose. For strictness, though, I think customers would be a better value indeed. I don't know of any tools that support access=customers for routing or even for rendering (OSM Carto does not and, looking at their issue tracker, it seems like nobody has asked them to support it yet). But GraphHopper could be the first.

I've checked the edit history of the English and the German wiki. The description next to destination was changed to suggest using motor_vehicle instead of access whenever possible on two occasions and kept ever since: 6 months ago in the German wiki, and 2 years ago in the English wiki. These make explicit what has already been written about the global meaning of access since 2011 in the English wiki and in the German wiki (in fact 4 months earlier than the English wiki). It is quite possible that some (let's hope not most) of ways were incorrectly tagged before those dates and haven't been fixed since.

@boldtrn

boldtrn commented Jan 24, 2018 •

Copy link
Copy Markdown
Member Author

Examples 2 and 1 are indeed bicycle/foot/motor_vehicle=destination because everyone can access the area if they are going there for the service (shopping at the mall or using government services).

If you go there for a service, this means you are a customer :).

access=customers was born in combination with amenities, so its usage with the highway tag is still somewhat lower than access=destination.

Yes but both examples are driveways or parking of an amenity so I think this is correct?

It is quite possible that some (let's hope not most) of ways were incorrectly tagged before those dates and haven't been fixed since.

Unfortunately not. There are many tagging issues in Germany. This could have a massive negative impact on bicycle routing.

I think it might be a good idea to convert access=destination to pushing sections, this could improve the tagging in OSM. At first this would lead to problems though, until most cycleways are fixed.

Also I would be ok to apply the the speed reduction + avoidance for ways that are tagged with bicycle=destination. There are more ways than I would have expected with this tagging scheme, so it would improve the routing. (same for foot=destination) (Most seem to be incorrectly tagged private ways, but would be still good to avoid them).

@ftrebien

ftrebien commented Jan 24, 2018 •

Copy link
Copy Markdown

@boldtm You are right, but that still makes such data incorrect. Recent discussions on the subject, for example this discussion on private streets, assume that those tags are being used correctly. So, well, it depends on whether GraphHopper hopes to help encourage mappers to improve map data or simply continue to use the tag values incorrectly (as most routers do too). Perhaps another approach for this standstill would be to slowly decrease the speed on access/bicycle=destination so that small detours are not affected initially.

@ftrebien

Copy link
Copy Markdown

@boldtrn On whether destination or customers would be more correct, there is disagreement on the need for the new customers value.

@boldtrn

boldtrn commented Jan 26, 2018

Copy link
Copy Markdown
Member Author

You are right, but that still makes such data incorrect.

Yes using access=destination where motor_vehicle=destination is signed, is tagged incorrect.

So, well, it depends on whether GraphHopper hopes to help encourage mappers to improve map data or simply continue to use the tag values incorrectly

Yes, I should have explained, "convert access=destination to pushing sections" means slowing down these streets. GraphHopper then assumes that you have to push your bike on these ways, which is slower than riding your bike, and also results in an instruction "get off your bike".

@karussell karussell added this to the 0.11 milestone Apr 9, 2018

/**
* Checks if a road is access destricted. For example, if we have a case with
* access=destination and [encoder_vehicle]=yes, this method returns false

@karussell karussell Apr 10, 2018 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this really true? Would it be possible to add destination to the intendedValues?

But let's clarify if this issue is really worth the effort. Using pushing sections for bike in these cases is ok, but for foot "destination" does not make much sense. And then only bike encoders should be changed.

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mhm, not sure if destination is a intended value? In general we want to avoid roads with access=destination?

I think the example was about a road that has for example access=destination and bicycle=yes, so bicycle would be the more specific rule and therefore more important. So we would see this road as a regular road for bicycles, but as access restricted for cars.

but for foot "destination" does not make much sense

You mean because of incorrectly tagged roads? I think there are not many roads that actually use foot=destination.

@karussell

Copy link
Copy Markdown
Member

I'm not sure if this makes sense for foot. Is there a sign explicitly for foot? If not let's do this just for bike.

@boldtrn

boldtrn commented Jul 18, 2018

Copy link
Copy Markdown
Member Author

I'm not sure if this makes sense for foot. Is there a sign explicitly for foot? If not let's do this just for bike.

I also think that the relevance for foot is not that high. In theory there could be situations where foot=destination. I checked a sample on overpass and compared it with mapillary. I don't see why there would be foot=destination on this footpath.

@karussell karussell removed this from the 0.11 milestone Aug 31, 2018
@karussell

Copy link
Copy Markdown
Member

I think we should not merge this. See #1831.

@boldtrn

boldtrn commented Jan 16, 2020 •

Copy link
Copy Markdown
Member Author

Yes, I agree with you. I think there are too many tagging issues (where access=destination instead of motor_vehicle=destination). Should we close here?

@karussell karussell closed this Mar 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add support for restriction value 'destination' for car

3 participants