-
Notifications
You must be signed in to change notification settings - Fork 3.4k
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
output the highway tag in instructions #282
Comments
Would the ferry duration tag and the direction tag/relation work for you? Am 31.05.2012 um 23:24 schrieb Rodolphe Quiédeville reply@reply.github.com:
|
It's enough to split on earth/on sea, but it could be better to split primary equivalent/track for bicycle too. |
I'm the developer of the ridethecity.com bike routing website and we've been looking at osrm as a possible alternative to pgRouting, which is what we use now. This issue highlights an important feature for us because it allows us to represent some OSM way tags as icons in the route instructions -- and also to change the color of the route line based on the OSM tag. See for example, http://ridethecity.com/?wide=1#2495133 One approach would be to allow users to specify a list of relevant tags in the configuration and then support an additional API parameter e.g. include_tags=true that would provide the key/value for each way in the route instructions. This is complicated by the fact that way tags might change when the street name and street directions don't. The link above shows an example of this starting at step 4 in which 2nd Avenue begins as a separated bike path, becomes a bike lane for 0.4 miles, and then turns into a separated path again. We break that into 3 separate steps in our instructions because the bicycle facility has changed even though the street name and direction remains the same. Just so you understand some of the ways this might be used, our icons include: bike path, bike lane, bike route, rough surface (e.g. cobblestones, gravel), ferry, walk your bike, caution (for high-speed streets), and stairs -- all features useful to cyclists that we extract from OSM way tags. To make things a bit more complex, we also extract information from some OSM relations, too (mostly regional bike route info). |
hi, i'm the project manager for the city of copenhagen's upcoming bike planner. (alfa at http://www.ibikecph.dk) it's interesting to hear your thoughts on ridethecity. we're working with the osrm team to provide even better support for bike routing in osrm. dennis will be able to answer your question better, but i think one challenge with outputting tags is how it would affect performance. currently when the osm data is parsed, a simplified version is saved to disk, which doesn't include any tags. so it's not straightforward to output tags as part of the route instructions. but i agree that having (a filtered number of) tags available in the route instructions would be nice. also it would be nice when performing the contaction (preprocessing) of data. for example, turn penalties could depend on the type of way you turn from/to. |
Hello! Yes, I agree that this requirement would need to be balanced with its impact on performance. I'm not sure it's even a widespread enough requirement to warrant adding to the core of osrm. |
If it's useful, the way that pgRouting deals with this is by mapping osm tags to integer codes via a configuration file like this one: https://github.com/pgRouting/osm2pgrouting/blob/master/mapconfig.xml That helps condense the additional data required and also allows the application to condense redundant tags as necessary e.g. you might consider highway=cycleway and cycleway=yes as equivalent and have them resolve to the same tag id. |
Will think about that. |
somthing like this is already used for storing strings, like street names |
Here's an update as of v5.5: don't encode arbitrary strings into the way's name, ref, pronunciation or other similar properties. Doing so will completely screw the internal guidance heuristics and will probably lead to unusable / far too noisy announcements (think: multiple continues after each other). Here's the recommended way of doing this: use the this adds OSM Node IDs to the route response. Then either do the lookup
yourself or use https://github.com/mapbox/route-annotator which was built exactly for this use-case. |
76de7eb bump to v0.3.0 a2f36f0 Merge pull request #301 from mapbox/v8-5.1.281.47 e06010e Merge pull request #300 from mapbox/v8-3.14.5.10 61021d9 build xcode-toolchain for darwin [skip ci] a17d47e Update Android compile flags 8adc05a Merge pull request #298 from mapbox/c11-for-tc 91cc1ce adjustments to tippecanoe build 3693450 download tar of 1.15.1 1563d66 update to c++11 for tippecanoe ca2cf2f fix conditional building of libcxx with llvm 4.x e92a050 Add iwyu to llvm packages + conditionally build libc++ (to avoid potential conflicts with apple system) ecbe161 clang++ subpackage: rebundling asan_symbolize from llvm a04d31a llvm: install asan_symbolize script f81ff0f Merge pull request #297 from mapbox/boost_fixes 3c4201f also trigger build for header-only package 394db3d only need to build the header-only package once for all platforms 6f6dd89 avoid the header-only package reporting ldflags 2bef25b fix boost library name for ldflags 8abd030 bump to v0.2.0 434da41 Merge pull request #293 from mapbox/gdb 2c5e104 add texinfo [skip ci] 001e1d0 build gdb with g++ [skip ci] fa89a91 attempt to workaround gdb bug [skip ci] 7a573b0 add gdb [skip ci] 33b8c85 Merge pull request #292 from mapbox/binutils-latest d88af66 Upgrade Android NDK to r13b ce29128 add Android NDK r13b [skip ci] fcaff69 include llvm-ar and llvm-ranlib in clang++ package for full LTO support on linux 5fa738d add disable-werror to binutils build [skip ci] b38b22e add texinfo dep [skip ci] a9c038a add latest binutils 09a1272 add geojson 0.4.0 [skip ci] f787753 add geometry 0.9.0 [skip ci] 649178c add variant 1.1.4 [skip ci] f29bc15 Merge pull request #285 from mapbox/pkgconfig 5c3a26d add pkgconfig 0.29.1 228784d Fix bug in wagyu e9cfd69 Merge pull request #284 from mapbox/wagyu2 0dab0ba Update travis script b580a12 Updated hash as it was not md5 -- something I forgot a5c6b7b Merge pull request #283 from mapbox/wagyu dd05da8 Added wagyu 0.1.0 5407ddc Merge pull request #282 from mapbox/boost-1.62.0 fa6d51a add boost 1.62.0, remove obsolete boost packages d0210bb drop the boost 'all' packages 66d8a26 remove empty before_install 7527555 Merge pull request #281 from mapbox/mason-travis-token af4a2c6 [gtest@1.7.0] Skip linking with pthread on android 2115889 rename TRAVIS_TOKEN to MASON_TRAVIS_TOKEN to avoid conflicting with travis.rb (https://github.com/travis-ci/travis.rb/blob/b75c38bcdb736d1011e0d2a0022344a9870acaf4/README.md#environment-variables) 8117c1c Merge pull request #279 from mapbox/llvm-libstdcxx 3c9029e strip version modifier 9e1edca Add llvm 3.8.1 package that sets BUILD_AND_LINK_LIBCXX=false - refs #278 9724ef5 make building and linking libcxx/libcxxabi optional - refs #278 6c4c5d5 solve #152 8f3a877 Merge pull request #277 from mapbox/central-secure 9350c34 New travis keys f442ddc add secure variables on-demand in trigger command 36d4801 remove global variables 4fff08a Add mesa 13.0.0-egl{,-cxx11abi} e3f2a2c [mason] Add support for nested pkg-config files 3b79550 Add ICU 58.1 (#275) 20a394d make contributing.md tagging more DRY [skip ci] 58ae447 bump to v0.1.1 c5ef33f rename llvm 4.x to 4.0.0 [skip ci] 5d5d26b add llvm 4.x based sub-packages 9708680 only set LIBCXX_ENABLE_STATIC_ABI_LIBRARY for linux [skip ci] 6918fb0 install LLVMgold.so on linux [skip ci] ab20ff7 binutils: using 'all-gold' breaks make install on linux [skip ci] cb8b15f fix binutils install [skip ci] df77b02 properly set LLVM_BINUTILS_INCDIR value [skip ci] 295d4db binutils gold fixes [skip ci] ac85676 enable LLVMgold.so for linux [skip ci] acc4249 add binutils 2.27 16d4452 add lldb and llvm-cov 3.8.1 packages 757b908 remove patching no longer needed [skip ci] 69415b5 better fix for statically linking/linked libc++ with llvm 3.8.1 [skip ci] 43933ed Added mesa-13.0.0-glx (non-CXX11ABI) 2bb81cc Added mesa-13.0.0-glx d70e3ef LLVM_EXTERNALIZE_DEBUGINFO is osx specific ba737bf llvm 3.8.1 linux build fixes 4279f58 Updates for mesa 13.0.0 d544278 Revert typo in mason.sh 03ecb2c Add mesa 13.0.0 (Gallium-OSMesa) 0997905 Add expat 2.2.0 211d8f4 v8 libplatform depends on libbase [skip ci] c9d2371 thin archives are only an linux thing [skip ci] bd4964b ensure v8 static libs are portable [skip ci] f41eb6d mason.cmake: multiple static libs also need to be split c9fcd1a add lldb to llvm 3.8.1 [skip ci] 6d8e16c minor llvm/clang++ improvements 65a5418 fix static_libs 31a424f add v8 5.1.281.47 1afa241 fix v8 include dir [skip ci] b2bdb33 Add note that we need to create a github release [skip ci] 17d9b09 linux fixes 95b4f2e add v8 3.14.5.10 git-subtree-dir: third_party/mason git-subtree-split: cf3561bf78cb146821dba3d95c308fc44db05f46
5.9 has the road class in the intersection object: https://github.com/Project-OSRM/osrm-backend/blob/5.9/docs/http.md#intersection-object the default car profile sets and you can change that in your own profile. Closing this as resolved. |
Hi,
This is a feature request, is it possible to add in route_instructions the highway tag ? It will be useful to show total time by highway type, in web services we can show something like "3 hours on road, and 4 hours on ferry".
Thanks
The text was updated successfully, but these errors were encountered: