Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use cycleway:surface for surface statistics #438

Closed
theraser opened this issue Jul 7, 2021 · 5 comments · Fixed by #460
Closed

Use cycleway:surface for surface statistics #438

theraser opened this issue Jul 7, 2021 · 5 comments · Fixed by #460

Comments

@theraser
Copy link

theraser commented Jul 7, 2021

Since cycleway:surface and footway:surface are getting more and more popular and are already supported by BRouter (see abrensch/brouter#131 for details) it would be nice to use these tags for calculating the surface statistics.

Example: https://brouter.de/brouter-web/#map=17/50.13421/8.69458/standard&lonlats=8.696172,50.135486;8.694914,50.13251

Both footway and cycleway got a surface-tag (see https://www.openstreetmap.org/way/849709593) and if you use a profile which uses these tags it will show up at the data details tab - but it's counted as "Unknown" at the "Analyse route" tab:

This just got me because I wondered why there are so many "Unknown" surfaces at some routes 😃

mjaschen added a commit to mjaschen/brouter-web that referenced this issue Nov 20, 2021
The `surface` tag exists in different variants,
e.g. `surface`, `cycleway:surface` etc.

Previously, the `surface` and `smoothness` tags were only processed for route analysis if they were found in their canonical form in the BRouter server response.

With this commit, the variants are normalized down to the main tag name which has the effect that they're included in the route analysis.

Fixes nrenner#438
@mjaschen
Copy link
Contributor

If anyone is interested in testing the fix – I pushed it to bikerouter.de:

Example: https://bikerouter.de/#map=17/50.13421/8.69459/standard&lonlats=8.696172,50.135486;8.694914,50.13251

@theraser
Copy link
Author

Looks awesome, thanks a lot! Tested a few more bicycle tracks (different tagging styles), all worked as expected.

mjaschen added a commit to mjaschen/brouter-web that referenced this issue Jan 22, 2022
The `surface` tag exists in different variants,
e.g. `surface`, `cycleway:surface` etc.

Previously, the `surface` and `smoothness` tags were only processed for route analysis if they were found in their canonical form in the BRouter server response.

With this commit, the variants are normalized down to the main tag name which has the effect that they're included in the route analysis.

Fixes nrenner#438
@pkubowicz
Copy link

This isn't correctly fixed. OSM Wiki suggests tagging like:

surface=paved
cycleway:surface=asphalt
footway:surface=paving_stones

I think it's bad advice (you won't find a square centimeter with 'paved' in the terrain, all is either asphalt or paving stones, there aren't 3 types of surface). But unfortunately people tag this way, so routing should support it.

Today, BRouter says cycling along such a way is 100% paved (example). But it should say it's 100% asphalt.

The code from 9ca93e4 is unclear in ordering of tags, so I don't know if the order is random, or something else sorts tags.

@rkflx
Copy link
Contributor

rkflx commented Aug 23, 2023

I think it's bad advice

According to surface=paved, "This value gives only a rough description; use a more precise value if possible.". IMO that's good and pragmatic advice.

it should say it's 100% asphalt

It does if you turn on "processUnusedTags" in the "Customize profile" sidebar, or use https://bikerouter.de where this is checked by default.

In the "Data" sidebar, you'll be able to see the difference. Only looking at upstream OSM tags (e.g. here) can be misleading.


Changing the profile to evaluate the tag like this triggers the correct behaviour too, of course:

- assign ispaved = surface=paved|asphalt|concrete|paving_stones|sett
+ assign ispaved = or surface=paved|asphalt|concrete|paving_stones|sett cycleway:surface=asphalt

I'd say not considering cycleway:surface is the actual root issue here, and should be fixed (not only for asphalt, obviously) in either BRouter's profiles or in BRouter's tag aliasing. We want to not only count the tag in our statistics, but use it for routing too, since not every way with cycleway:surface might also have surface set. I'd recommend to open a new issue in the BRouter repo.

@quaelnix
Copy link
Contributor

quaelnix commented Sep 2, 2023

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants