Imported Upstream version 1.4.1
[routino] / doc / TAGGING.txt
1                            Routino : Tagging Rules
2                            =======================
3
4
5    The different tags and attributes in the OSM format XML that are used
6    by Routino are described below.
7
8    An important change for version 1.4 of Routino is that the tags in the
9    input file are first processed according to a set of rules defined in a
10    configuration file. This means that the information presented here is
11    in two parts; firstly the tags that are recognised by Routino after
12    pre-processing and secondly the transformations in the default
13    configuration file.
14
15
16 Tags Recognised After Processing
17 --------------------------------
18
19    This section describes the tags that are recognised by Routino after
20    the tag transformations have been applied. This is therefore a much
21    reduced set of tags compared to the original OSM data and also includes
22    tags which are specific to Routino.
23
24    In all cases of tag processing values of true, yes, 1 are recognised as
25    being affirmative and any other value is ignored.
26
27
28 Node Tags And Attributes
29 ------------------------
30
31    None of the node tags are used but the node attributes id, latitude and
32    longitude of the node. The id atribute is required to associate the
33    node with the ways and the position attributes are required to locate
34    the node.
35
36
37 Way Tags And Attributes
38 -----------------------
39
40    The tags from the ways in the data are the ones that provide most of
41    the information for routing. The id attribute is used only so that the
42    many segments associated with a way can be share a set of tags taken
43    from the way.
44
45 The highway Tag
46 - - - - - - - -
47
48    The most important tag that is used from a way is the highway tag. This
49    defines the type of highway that the way represents. Any way that does
50    not have a highway tag is discarded.
51
52    There are more highway types defined than are used by the router. The
53    subset that the router uses are:
54      * motorway
55      * trunk
56      * primary
57      * secondary
58      * tertiary
59      * unclassified
60      * residential
61      * service
62      * track
63      * cycleway
64      * path (1)
65      * steps (2)
66
67    Note 1: This changed in version 1.3 of Routino - the bridleway and
68    footway types were included within the path highway type.
69    Note 2: This changed in version 1.3 of Routino - the steps type was
70    separated from the footway type.
71
72 Transport Specific Tags
73 - - - - - - - - - - - -
74
75    One tag is recognised for each of the different modes of transport:
76    foot, horse, bicycle, wheelchair, moped, motorbike, motorcar, goods,
77    hgv and psv. These indicate whether the specific type of transport is
78    allowed on the highway or not.
79
80 The name Tag
81 - - - - - -
82
83    The name tag is used to provide the label for the highway when printing
84    the results.
85
86 The ref Tag
87 - - - - - -
88
89    The ref tag is used to provide the label for the highway when printing
90    the results.
91
92 The junction Tag
93 - - - - - - - -
94
95    The junction tag is used to check if a highway is (part of) a
96    roundabout. This tag is used for information to label the highway if no
97    other name is provided.
98
99 The multilane Tag
100 - - - - - - - - -
101
102    The multilane tag is used to identify whether a highway has multiple
103    lanes for traffic and this sets one of the highway properties. There is
104    not normally a multilane tag but one needs to be added by the tag
105    processing transformations. Values of true, yes, 1 are recognised.
106
107 The paved Tag
108 - - - - - - -
109
110    The paved tag is used to identify whether a highway is paved or not,
111    this is one of the available highway properties. A paved tag may exist
112    in the original data but normally the surface tag needs to be
113    transformed into the paved tag.
114
115 The bridge Tag
116 - - - - - - -
117
118    The bridge tag is used to identify whether a highway is a bridge and
119    therefore set one of the available properties.
120
121 The tunnel Tag
122 - - - - - - -
123
124    The tunnel tag is used to identify whether a highway is a tunnel and
125    therefore set one of the available properties.
126
127 The oneway Tag
128 - - - - - - -
129
130    The oneway tag is used to specify that traffic is only allowed to
131    travel in one direction.
132
133 The maxspeed Tag
134 - - - - - - - -
135
136    The maxspeed tag is used to specify the maximum speed limit on the
137    highway; this is always measured in km/hr in OpenStreetMap data. If the
138    tag value contains "mph" then it is assumed to be a value in those
139    units and converted to km/hr.
140
141 The maxweight Tag
142 - - - - - - - - -
143
144    The maxweight tag is used to specify the maximum weight of any traffic
145    on the way. In other words this must be set to the heaviest weight
146    allowed on the way (for example a bridge) in tonnes. If the tag value
147    contains "kg" then it is assumed that the value is in these units and
148    converted to tonnes.
149
150 The maxheight Tag
151 - - - - - - - - -
152
153    The maxheight tag is used to specify the maximum height of any traffic
154    on the way. In other words this must be set to the lowest height of
155    anything above the way (like a bridge) in metres. If the tag value
156    contains a measurement in feet or feet and inches then attempts are
157    made to convert this to metres.
158
159 The maxwidth Tag
160 - - - - - - - -
161
162    The maxwidth tag is used to specify the maximum width of any traffic on
163    the way. This must be set to the minimum width of the contraints at the
164    wayside in metres. If the tag value contains a measurement in feet or
165    feet and inches then attempts are made to convert this to metres.
166
167 The maxlength Tag
168 - - - - - - - - -
169
170    The maxlength tag is used to specify the maximum length of any traffic
171    on the way (usually from a traffic sign) in metres. If the tag value
172    contains a measurement in feet or feet and inches then attempts are
173    made to convert this to metres.
174
175
176 Relation Tags And Attributes
177 ----------------------------
178
179    Currently no relation tags or attributes are used.
180
181
182 Tag Transformations
183 -------------------
184
185    This section describes the set of tag transformations that are
186    contained in the default configuration file. The configuration file
187    tagging rules are applied in sequence and this section of the document
188    is arranged in the same order.
189
190
191 Node Tag Transformations
192 ------------------------
193
194    No transformations are applicable since no node tags are recognised.
195
196
197 Way Tag Transformations
198 -----------------------
199
200 Highway Defaults
201 - - - - - - - -
202
203    The first part of the tag transformations is to decide on defaults for
204    each type of highway. This uses the highway tag in the OSM file and
205    maps it into one of the highway tags that are recognised by Routino,
206    defining the default allowed transport types and adding a number of
207    properties.
208
209    The first part of the transformation is to convert the highway tag into
210    one that is recognised by Routino.
211
212    Original tag  Transformed tag
213    ------------  ---------------
214    bridleway     path
215    byway         track
216    footway       path
217    living_street residential
218    minor         unclassified
219    pedestrian    path
220    road          unclassified
221    services      service
222    unsurfaced    track
223    unpaved       track
224    walkway       path
225
226    The type of highway also determines the defaults for the types of
227    transport allowed on the highway. The default assumptions are as shown
228    in the table below.
229
230    Highway      foot horse  wheelchair bicycle moped motorbike motorcar goods hgv psv
231    -------      ---- -----  ---------- ------- ----- --------- -------- ----- --- ---
232    motorway     no   no     no         no      no    yes       yes      yes   yes yes
233    trunk        no   no     no         yes     yes   yes       yes      yes   yes yes
234    primary      yes  yes    yes        yes     yes   yes       yes      yes   yes yes
235    secondary    yes  yes    yes        yes     yes   yes       yes      yes   yes yes
236    tertiary     yes  yes    yes        yes     yes   yes       yes      yes   yes yes
237    unclassified yes  yes    yes        yes     yes   yes       yes      yes   yes yes
238    residential  yes  yes    yes        yes     yes   yes       yes      yes   yes yes
239    service      yes  yes    yes        yes     yes   yes       yes      yes   yes yes
240    track        yes  yes    yes        yes     no    no        no       no    no  no
241    cycleway     yes  no     yes        yes     no    no        no       no    no  no
242    path         yes  yes(1) yes        yes(1)  no    no        no       no    no  no
243    steps        yes  no     yes        no      no    no        no       no    no  no
244
245    Note 1: A path allows bicycle or horse access by default only if
246    actually labelled as a highway of type "bridleway" or certain values of
247    the designation tag (described below).
248
249    Finally for the highway tag a number of properties are added depending
250    on the highway type.
251
252    Highway      Properties
253    -------      ----------
254    motorway     paved, oneway, multilane
255    trunk        paved
256    primary      paved
257    secondary    paved
258    tertiary     paved
259    unclassified paved
260    residential  paved
261    service      paved
262    track        paved (1)
263    cycleway     paved
264    path         paved (2)
265    steps
266
267    Note 1: A track is paved only if it is tagged as tracktype=grade1.
268    Note 2: A path is paved only if it was originally tagged as
269    highway=walkway or highway=pedestrian.
270
271 Generic Access Permissions
272 - - - - - - - - - - - - -
273
274    The access tag is used to specify the default access restrictions on
275    the way. If the tag value is "no" or "private" then all transport types
276    are denied access (later tag transformation rules may add specific
277    transport types back again).
278
279 Other Access Permissions
280 - - - - - - - - - - - -
281
282    A tag named vehicle means any of the bicycle, moped, motorbike,
283    motorcar, goods, hgv and psv transport types. A tag named motor_vehicle
284    is transformed to mean any vehicle except a bicycle.
285
286    The designation tag is used as an alternative method of identifying the
287    legal right of way on a path (in the UK at least). The tag
288    transformations convert these tags into a set of allowed transport
289    types as shown below.
290
291    Designation tag      Equivalent access permissions
292    ---------------      -----------------------------
293    bridleway or         foot=yes, wheelchair=yes, horse=yes,
294      public_bridleway     bicycle=yes
295    restricted_byway     foot=yes, wheelchair=yes, horse=yes,
296                           bicycle=yes
297    byway                foot=yes, wheelchair=yes, horse=yes,
298                           bicycle=yes, moped=yes, motorbike=yes,
299                           motorcar=yes
300    footpath or          foot=yes, wheelchair=yes
301      public_footpath
302
303 Specific Access Permissions
304 - - - - - - - - - - - - - -
305
306    The final part of the access permissions is to use the specific
307    transport type tags.
308
309    One tag is recognised for each of the different modes of transport:
310    foot, horse, bicycle, wheelchair, moped, motorbike, motorcar, goods,
311    hgv and psv. These indicate whether the specific type of transport is
312    allowed on the highway or not.
313
314 Highway Properties
315 - - - - - - - - -
316
317    If there is a surface tag then the highway is assumed to be unpaved
318    unless the tag value matches one of the following: paved, asphalt or
319    concrete.
320
321    Support for the obsolete paved tag is also provided and the highway is
322    paved if this is set to a true value.
323
324    The lanes tag is used to identify whether a highway has multiple lanes
325    for traffic or not (the number of lanes is not important in this case,
326    only whether it is more than one) this sets one of the highway
327    properties.
328
329    The bridge and tunnel tags are copied directly from the input to the
330    output.
331
332 Highway Restrictions
333 - - - - - - - - - -
334
335    The oneway, maxspeed, maxweight, maxheight, maxwidth and maxlength are
336    copied directly from the input to the output without modification.
337
338 Highway Names and References
339 - - - - - - - - - - - - - -
340
341    The name and ref tags are copied directly from the input to the output.
342
343
344 Relation Tag Transformations
345 ----------------------------
346
347    No transformations are applicable since no relation tags are recognised.
348
349
350 --------
351
352 Copyright 2008-2010 Andrew M. Bishop.