pgRouting / osm2pgrouting

Import tool for OpenStreetMap data to pgRouting database
https://pgrouting.org
GNU General Public License v2.0
286 stars 113 forks source link

mapconfig examples for pedestrian and bicycles make not much sense #271

Open Langlaeufer opened 4 years ago

Langlaeufer commented 4 years ago

The examples for pedestrian, bicycles make not much sense.

for_pedestrian example does not include most street type - so the network is not complete at all. barrier as with maxspeed higher than for ways?

for_bicycle: tracktype=grade2...5 is never analysed, because the priority 1.x is higher than priority 1.0 of highway= track what should the entry junction=roundabout is good for?

for_cars: what should the priorities be good for? It is all tag_name=highway, so no priority is needed, because we can only have one highway tag per way. or is it here to use later as factor for the costs?

Langlaeufer commented 4 years ago

An proposal for bicycle

<?xml version="1" encoding="UTF-8"?>
<configuration>
  <tag_name name="highway" id="1">
    <!-- not for cycling <tag_value name="motorway" id="101" maxspeed="130" priority="1" /> -->
    <!-- not for cycling <tag_value name="motorway_link" id="102" maxspeed="100" priority="1" /> -->
    <tag_value name="trunk" id="103" maxspeed="30" priority="1" />
    <tag_value name="trunk_link" id="104" maxspeed="30" priority="1" />
    <tag_value name="primary" id="105" maxspeed="30" priority="1" />
    <tag_value name="primary_link" id="106" maxspeed="30" priority="1" />
    <tag_value name="secondary" id="107" maxspeed="30" priority="1" />
    <tag_value name="secondary_link" id="108" maxspeed="30" priority="1" />
    <tag_value name="tertiary" id="109" maxspeed="30" priority="1" />
    <tag_value name="tertiary_link" id="110" maxspeed="30" priority="1" />
    <tag_value name="unclassified" id="111" maxspeed="30" priority="1" />
    <tag_value name="residential" id="112" maxspeed="30" priority="1" />
    <tag_value name="living_street" id="113" maxspeed="10" priority="1" />
    <tag_value name="service" id="114" maxspeed="30" priority="1" />
    <tag_value name="road" id="116" maxspeed="30" priority="1" />
    <tag_value name="track" id="200"  maxspeed="20" priority="3" /> <!-- only if no tracktype -->
    <tag_value name="path" id="120" maxspeed="25" priority="1" />
    <tag_value name="footway" id="121" maxspeed="15" priority="1" />
    <tag_value name="cycleway" id="122" maxspeed="25" priority="1" />
    <!-- not for cycling <tag_value name="bridleway" id="123" maxspeed="10" priority="1" /> -->
    <!-- not for cycling <tag_value name="steps" id="124 maxspeed=1" priority="1" /> -->
  </tag_name>
  <tag_name name="tracktype" id="2"> <!-- if tracktype use it instead of track -->
    <tag_value name="grade1" id="201" maxspeed="30" priority="2" />
    <tag_value name="grade2" id="202" maxspeed="25" priority="2" />
    <tag_value name="grade3" id="203" maxspeed="20" priority="2" />
    <tag_value name="grade4" id="204" maxspeed="15" priority="2" />
    <tag_value name="grade5" id="205" maxspeed="10" priority="2" />
  </tag_name>
</configuration>
<!-- you may delete the maxspeed tags in the osm file before importing it -->
<!-- use --addnodes --tags to import all the other osm tags you need for defining access and speed -->
dkastl commented 4 years ago

Thank you for looking into all this in detail!

As far as I remember, the sample configurations were added many years ago, as part of some contributions of a routing web service for cyclists, which I forgot the name.

So whether it already lacked some configuration that time, or things have changed in the meanwhile, any improvement is highly appreciated. If you have a profiles better suited for cycling and pedestrians, feel free to suggest them as a pull request. That way you also become a contributor of the project.