Public transport

From OpenStreetMap Wiki
(Redirected from Public Transport)
Jump to: navigation, search
Available languages — Public transport
· Afrikaans · Alemannisch · aragonés · asturianu · azərbaycanca · Bahasa Indonesia · Bahasa Melayu · Bân-lâm-gú · Basa Jawa · Basa Sunda · Baso Minangkabau · bosanski · brezhoneg · català · čeština · corsu · dansk · Deutsch · eesti · English · español · Esperanto · estremeñu · euskara · français · Frysk · Gaeilge · Gàidhlig · galego · Hausa · hrvatski · Igbo · interlingua · Interlingue · isiXhosa · isiZulu · íslenska · italiano · Kiswahili · Kreyòl ayisyen · kréyòl gwadloupéyen · Kurdî · latviešu · Lëtzebuergesch · lietuvių · magyar · Malagasy · Malti · Nederlands · Nedersaksies · norsk bokmål · norsk nynorsk · occitan · Oromoo · oʻzbekcha/ўзбекча · Plattdüütsch · polski · português · română · shqip · slovenčina · slovenščina · Soomaaliga · suomi · svenska · Tagalog · Tiếng Việt · Türkçe · Vahcuengh · vèneto · Wolof · Yorùbá · Zazaki · српски / srpski · беларуская · български · қазақша · македонски · монгол · русский · тоҷикӣ · українська · Ελληνικά · Հայերեն · ქართული · नेपाली · मराठी · हिन्दी · भोजपुरी · অসমীয়া · বাংলা · ਪੰਜਾਬੀ · ગુજરાતી · ଓଡ଼ିଆ · தமிழ் · తెలుగు · ಕನ್ನಡ · മലയാളം · සිංහල · བོད་ཡིག · ไทย · မြန်မာဘာသာ · ລາວ · ភាសាខ្មែរ · ⵜⴰⵎⴰⵣⵉⵖⵜ ⵜⴰⵏⴰⵡⴰⵢⵜ‎ · አማርኛ · 한국어 · 日本語 · 中文(简体)‎ · 中文(繁體)‎ · 吴语 · 粵語 · ייִדיש · עברית · اردو · العربية · پښتو · سنڌي · فارسی · ދިވެހިބަސް
Logo. Feature : Public transport
One example for Feature : Public transport
Description
Railways, buses, trams, etc.
Tags

An overview of current public_transport=* (or mass transit) related tagging.

Introduction

Why do we map public transport in OpenStreetMap?

The main role of street maps has generally been to help people navigate when walking, or when using private motor vehicles on the public highway system. Public transport provides an alternative which is often faster, more environmentally sustainable, and sometimes even more convenient.

Unlike with walking and driving, where it's enough for maps to simply describe the street and footpath layout, allowing people to decide their own route and schedule, with public transport, we need to describe the infrastructure (e.g., the train tracks) as well as the services which operate on them (e.g., bus lines, express trains and local trains).

Whilst OpenStreetMap is probably not the place for full timetable information, adding information about public transport infrastructure and services to the map means that we can provide basic routing services. Very few other maps currently do this (although Google Transit is also making improvements in this area).

Discussion of public transport on OSM takes place on the talk-transit mailing list.

Different tagging schemas

As time passed, several tagging schemas were developed and were/are in use.

  • The Old Public Transport Schema, sometimes called Public Transport Version 1 (PTv1) is still (mid 2017) widely in use.
  • The Oxomoa Schema is a schema which has large similarities to Public Transport Version 2. It has not succeded. You might sometimes find route relations which were created around 2010 and have not been modified since that time. It is documented on User:Oxomoa/Public transport schema.
  • The New Public Transport Schema has been called Public Transport Version 2 (PTv2) since 2014 and is the latest schema. The original wording of its proposal can be found at Proposed features/Public Transport.

Types of public transport

Public transport comes in various different forms and types. Each type is usually distinguished by the technology and infrastructure it uses. For example, railways use trains running on metal rails, buses use the main road network, and airplanes use the sky …

Some types may blur the boundaries a little. For example, trams are a form of 'light rail' (using lighter-than-normal train vehicles) which typically run on metal rails embedded into public roads (although may also have sections of dedicated track). There might also exist differences in signalling and the priority at intersections (in some cities trams are prioritised by traffic signals.

In some cases a public transport line can change its type. The following pictures show the Badner Bahn from Vienna (Austria) to Baden (near Vienna, Austria), also known as "Lokalbahn" (literally "local train")

The distinctions can be even more subtle. Buses and coaches, for example, both use motor vehicles on the public road network, however coaches tend to be bigger and more comfortable, and used for longer distances (with fewer stops).

Whilst it may be tempting to try and come up with definitions for these different types, ultimately, maps are most useful if they match with people's expectations. So, when choosing which type a particular public transport service falls into, it's generally best to go with whatever the users of that service general understanding of it would be.

Buses

Main article: Buses

Buses, coaches, guided-buses and trolleybuses all operate mainly on the highway (for trams see the Trams section below).

Simple bus stops have been tagged with just highway=bus_stop for a long time. Some of them have been mapped a a node on the side of the road where the people wait. Others have been mapped as a node on the road itself where the vehicle stops.

PTv2 makes it possible to use a more detailed tagging. Following is mapped per direction of the road:

If there is no real platform and you will only find a simple sign for the passengers … If there is a real, dedicated platform for waiting passengers (usually a different paving, a Kassel kerb or a tactile paving) …
Place a node Node on the road where the bus stops. The node should have following tags: Place a node Node on the road where the bus stops. The node should have following tags:

The node also gets highway=bus_stop.

Add a node Node at the location of the bus stop sign. It gets following tags: The platform is mapped as a unclosed way Way or an area Area. It gets following tags:

Note: Because the newer public_transport=* tags are currently not rendered on the main page, the bus stops have to be additionally tagged with highway=bus_stop (see bug report).

It is not necessary to map both the platform and the stop position. One of the two is enough. Mappers in some countries map both (e.g., Germany) while other countries only map platforms (e.g., Flanders).

Because a bus stop now consists out of multiple objects, some people use a relation with type=public_transport and public_transport=stop_area to connect them.

Wires used by trolley buses can be mapped by adding trolley_wire=yes to the highway. The highway=bus_guideway tag should be used for sections of guided busway.

Every transit service (e.g., No. 38) is usually represented as one route master relation containing two variant route relations, one for each direction.

Railways

Main article: Railways

Railway services (mainline, metro, light rail, tram, subway, etc.) all generally operate on metal rails. The main railway infrastructure is defined using railway=*.

The stops of railways (except trams and tram-like light rails) are mapped as a node (some people also use areas) with railway=station or railway=halt. This tag is only used once per station/halt.

Mapping of stop positions and platforms is done similar to busses:

railway=subway_entrance can be used to define entrances to metro stations. Stations of subways are tagged with railway=station, subway=yes and station=subway. The two latter tags are used to indicate that a station is a subway station.

See the wiki pages Tag:railway=station, Tag:railway=halt, Tag:public_transport=stop_position and Tag:public_transport=platform for further informations about the usage of these tags.

Trams

Main article: Trams

Trams are a form of light rail which share their path with the road for some part of their route.

Trams use the railway=tram tag. Avoid using the same way for a tram as being used for the road (highway=*). Otherwise it is not obvious if additional tags are properties of the road or of the tram. For example, maxspeed=30 might mean that the speed limit of the road is 30 kph but it could also mean that the speed limit of the tram is 30 kph if the way is tagged with both highway=* and railway=tram.

See Tag:railway=tram for more details about mapping trams.

railway=station/halt is not used for tram stops, use railway=tram_stop instead. The usage of other tags is similar to railways:

Aircraft

Main article: Aeroways

Flying (in aircraft) has become one of the most prevalent means of long-distance public transport travel. Currently, flight paths aren't included on our map (they're much less physical than roads and rails). However, this mode of transport does use an extensive range of physical on-the-ground infrastructure, including airport terminals, taxiways, runways, and connecting transport services, and all of these features can be added to OSM.

While the map currently largely goes down to a level of detail of showing airport buildings and runways, in the future we may show the location of the individual aircraft 'gates' and the internal layout of airports.

Ferries

Main article: Ferries

The route of a ferry service can be defined using ways tagged with route=ferry. For sections of route across open water such as the sea, lakes and wide rivers a new linear way tagged as route=ferry should be created. For rivers using waterway=river add route=ferry to this way. If the ferry service ends along the length of an existing river then the river's way should be snipped into two at the point where the ferry service terminates. It is not clear how one tags a ferry that crosses a river that is constructed from a single way as both ends of the ferry would be at the same point. It is possible that adding route=ferry to a node on the river may be appropriate, similar to a crossing point on a road.

Places where people and vehicles can access ferry services should use public_transport=platform with ferry=yes and public_transport=stop_position. The earlier-used amenity=ferry_terminal is still in use. The complete route for a ferry can be described using a relation route using route=ferry.

Cable cars

Main article: Aerialway

Cable-cars, drag-lifts and chair-lifts can be modeled using aerialway=*. These can be considered as a form of public transport in that they are shared, operated for fixed times of day at predictable intervals. Some cable cars may operate to a clock-face timetable.

Aerialway stations are often tagged as aerialway=station. You can add public_transport=station, public_transport=stop_position and aerialway=yes.

Service routes

Main article: Relation:route

In addition to modelling the infrastructure on which vehicles operate and the places where people embark and disembark from transit services, it is also useful to model the public transport services themselves. In particular, this makes it possible to provide public transport routing services.

A route is a relation Relation that describes the physical path taken by the vehicles through the infrastructure by a transit service which is known to the public with a particular reference or name. The relation contains

  • first a list of all stations in the order: stop_position 1, platform 1, stop_position 2, platform 2, … Stop positions get the role stop, platforms the role platform. It is necessary to add the stops/platforms if they are mapped but it is not necessary to add them if they are missing just to be able to add them to the relation.
  • The list of stops and platforms is followed by a ordered list of the ways which are used by the vehicle from the starting station to the terminal station. Each direction of the route must have its own relation, forks are not permitted. If there are multiple different routes from the starting station to the terminal station, each variant must have its own relation.
Key Value Comment Recommendation
type route This is a route relation. mandatory
route train / subway / monorail / tram / bus / trolleybus / aerialway / ferry Type of public transport vehicle mandatory
from name of the station name of the starting station recommended
to name of the station name of the terminal station recommended
via name of the stations intermediate stops if different variants per direction exist. Add the stations which make the difference between two routes. recommended if multiple variants exist per direction
name <reference number>: <from> => <to> human readable description of the route. <reference number> should be the value of ref=*. Examples: Bus 201: Uitikon Waldegg, Bahnhof => Uitikon, Wängi for a bus route or RE 7: Dessau Hbf => Wünstorf-Waldstadt for a train route. If the line has no number in reality, only use the word "bus" for busses or the type of train (e.g., IC, TGV or RE) for trains (e.g., RE Würzburg Hbf => Stuttgart Hbf recommended
ref text refererence number which is valid on the whole line; e.g., "RE 7" oder "S 5". recommended
ref:<abbreviation> text reference number of the line which is assigned by a local authority, differs from ref=* and is not in use on the whole line (e.g line through two states, each state uses a different number for the line). Example: ref:VRN=R 85 recommended
operator text Name of the operator. There is no consensus whether you should use abbreviations or not. Multiple names are separated by semicolons. recommended
network text Name of the network(s) the route belongs to. The names of the German Verkehrsverbünde go into this tag. There is no consensus whether you should use abbreviations or not. Multiple names are separated by semicolons. recommended
colour text colour of the line symbol (English HTML colour name or web colour in hexadecimal form (e.g., #ff00ff) recommended
service text trains only: type of train service. This tag should make distinction between different types of train easier beyond borders in order that users do not have to parse reference numbers.
  • tourism (trains for tourists, often historic vehicles),
  • night (night trains with sleeping cars),
  • car_shuttle (car shuttle trains through tunnels),
  • car (long distance trains with double-deck car carrier),
  • commuter (urban mass transit service, short headways; e.g., S-train),
  • regional (local train),
  • long_distance (long distance trains; e.g., InterCity, EuroCity, InterRegio)
  • high_speed (high speed trains; e.g., ICE, TGV)
recommended for trains
public_transport:version 1 or 2 version of the tagging scheme being used. This makes it easier for data consumers to interpret the data. recommended if the route follows the PTv2 scheme

All the routes belonging to the same service can be put into a master relation with type=route_master, containing all the keys that are valid for all sub-relations, directions and variants.

Master routes

Because the two directions of a route are split up into at least two relations using PTv2, mappers are encouraged to add master route relations. They link the routes of a line with each other. The master route relation has only the tags which are common among all its route relations. It does only contain relations as members, neither nodes nor ways!

Key Value Comment Recommendation
type route_master This is a master route relation. mandatory
route_master train / subway / monorail / tram / bus / trolleybus / aerialway / ferry Type of public transport vehicle mandatory
name <reference number>: <from> <=> <to> human readable description of the route. <reference number> should be the value of ref=*. Examples: Bus 201: Uitikon Waldegg, Bahnhof <=> Uitikon, Wängi for a bus route or RE 7: Dessau Hbf <=> Wünstorf-Waldstadt for a train route. If the line has no number in reality, only use the word "bus" for busses or the type of train (e.g., IC, TGV or RE) for trains (e.g., RE Würzburg Hbf <=> Stuttgart Hbf recommended
ref text reference number which is valid on the whole line; e.g., "RE 7" oder "S 5". recommended
ref:<abbreviation> text reference number of the line which is assigned by a local authority, differs from ref=* and is not in use on the whole line (e.g line through two states, each state uses a different number for the line). Example: ref:VRN=R 85 recommended
operator text Name of the operator. There is no consensus whether you should use abbreviations or not. Multiple names are separated by semicolons. recommended
network text Name of the network(s) the route belongs to. The names of the German Verkehrsverbünde go into this tag. There is no consensus whether you should use abbreviations or not. Multiple names are separated by semicolons. recommended
colour text colour of the line symbol (English HTML colour name or web colour in hexadecimal form (e.g., #ff00ff) recommended
service text trains only: type of train service. This tag should make distinction between different types of train easier beyond borders in order that users do not have to parse reference numbers.
  • tourism (trains for tourists, often historic vehicles),
  • night (night trains with sleeping cars),
  • car_shuttle (car shuttle trains through tunnels),
  • car (long distance trains with double-deck car carrier),
  • commuter (urban mass transit service, short headways; e.g., S-train),
  • regional (local train),
  • long_distance (long distance trains; e.g., InterCity, EuroCity, InterRegio)
  • high_speed (high speed trains; e.g., ICE, TGV)
recommended for trains
public_transport:version 2 version of the tagging scheme being used. This makes it easier for data consumers to interpret the data. recommended if the route follows the PTv2 scheme

Members of this relation are

Role Refers to Comment Recommendation
none all route variant/direction Relations mandatory

Tagging

Main article: Proposed features/Public Transport

Toolbox

Editors

Maps

There are several people creating specialist public transport maps:

Mailing list

The talk-transit mailing list was created specifically for discussion of public transport related stuff.

Quality assurance

See Public transport Quality Assurance.

Other tools

Details on usage of parameters is described on the public_transport page.

Public transport by country

Public transport by country:

Imports

See also: Import/Catalogue

List of transit data imports. Good place to start to see how it's been done elsewhere but be sure to follow Import/Guidelines and Automated Edits code of conduct.

Project Location Summary
Import/VTA Transportation California, USA stops
NaPTAN UK stops
Switzerland/DIDOK Switzerland stations
VRS/Haltestellenimport(de) Cologne, Germany stops
Tenerife Bus Transport Import Tenerife, Canary Islands stops & routes
(undocumented: see [1]) Ottawa, Canada stops

GTFS standard

Data conforming to the GTFS standard could be imported using GO-Sync. It appears to have some useful usable functions and promises to be powerful but is still under (slowed) development.

See also

Further reading