General Transit Feed Specification (GTFS) ist ein ursprünglich von Google entwickeltes digitales Austauschformat für Fahrpläne des öffentlichen Personenverkehrs und dazugehörigen geografischen Informationen, wie z.B. Standorte von Haltestellen. Die Daten werden durch Transportunternehmen zur Verfügung gestellt und als gesammelte Datenbank auf der Open-Data Plattform öV-Schweiz im GTFS-Format publiziert. Genutzt werden die Daten zur Entwicklung von Applikationen im Zusammenhang mit dem öffentlichen Verkehr, wie z.B. Fahrplanabfragen.
Im Gegensatz zu GTFS Realtime (GTFS-RT) liefert GTFS Static, wie der Name schon sagt, nur statische Daten und keine Echtzeitdaten.
Mit dieser Static-Datei wird der gesamte öffentliche Verkehr eines Landes in einem einzigen Feed dargestellt.
Fachliche Beschreibung
GTFS Static wird anhand einer Reihe von Text-Files im ZIP-Format bereitgestellt. Jedes File gibt Informationen zu einem bestimmten Aspekt der Transit-Informationen wie beispielsweise Haltestellen (stops.txt), Routen (routes.txt), Fahrten (trips.txt), Transportunternehmen (agency.txt) und weiteren fahrplanrelevanten Daten. Einige Angaben sind notwendig, um valide GTFS-Daten bereitzustellen, andere sind optional und liefern nützliche Zusatzinformationen (wie z.B. Änderungen des Fahrplans an spezifischen Feiertagen = calendar_dates.txt).
Die folgende Grafik zeigt das Zusammenspiel der verschiedenen Informationen, wobei zurzeit nicht alle für den öV-Schweiz erfasst und im GTFS Format verfügbar sind:
Gehe zu Datensatz: https://opentransportdata.swiss/de/group/timetables-gtfs
Wichtige Konzepte
- GTFS Static: Publikation von statischen Transit-Informationen im GTFS-Format.
- GTFS Realtime: Publikation von Echtzeit-Transit-Informationen als Anreicherung der statischen GTFS-Daten, in der Form von Protocol Buffers
Technische Aspekte
Struktur der Daten
Jedes File besteht aus kommagetrennten Text- und Zahlenreihen mit Feldern, welche zusammengesetzt die gesuchten Informationen liefern. Eine ausführliche Beschreibung der einzelnen Felder in den verschiedenen Files werden im Detail auf der folgenden Webseite erläutert: https://developers.google.com/transit/gtfs/reference/
Für den GTFS Export des öV-Schweiz werden zurzeit die folgenden Files bereitgestellt:
- agency.txt
- calendar.txt
- calendar_dates.txt
- feed_info.txt
- routes.txt
- stop_times.txt
- stops.txt
- transfers.txt
- trips.txt
Nicht zur Verfügung gestellt werden: fare_attributes.txt, fare_rules.txt und frequencies.txt
agency.txt
1 2 3 4 5 6 7 8 |
agency_id,agency_name,agency_url,agency_timezone,agency_lang,agency_phone "11","Schweizerische Bundesbahnen SBB","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300 " "801","PostAuto Schweiz","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300 " "840","Busbetrieb Aarau","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300 " "31","BDWM Transport (bd)","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300 " "899","BDWM Transport (wm Auto)","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300 " "886","Regionale Verkehrsbetriebe Baden-Wettingen","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300 " "839","Zugerland Verkehrsbetriebe","http://www.sbb.ch/","Europe/Berlin","DE","0900 300 300" |
calendar.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
service_id,monday,tuesday,wednesday,thursday,friday,saturday,sunday,start_date,end_date "TA+b000b","1","1","1","1","1","0","0","20161211","20171209" "TA+b0001","1","1","1","1","1","1","1","20161211","20171209" "TA+b0016","0","0","0","0","1","1","0","20161211","20171209" "TA+b0dmg","0","0","0","0","0","0","1","20161211","20171209" "TA+b12cr","1","1","1","1","0","0","0","20161211","20171209" "TA+b0008","1","1","1","1","1","0","0","20161211","20171209" "TA+b0027","1","1","1","1","1","1","0","20161211","20171209" "TA+b0dnc","0","0","0","0","0","1","1","20161211","20171209" "TA+b001r","1","1","1","1","1","0","1","20161211","20171209" "TA+b001j","0","0","0","0","0","1","0","20161211","20171209" "TA+b001t","0","0","0","0","0","0","1","20161211","20171209" "TA+b04oi","1","1","1","1","1","0","0","20161211","20171209" "TA+b0ch2","0","0","0","1","0","0","0","20161211","20171209" |
calendar_dates.txt
1 2 3 4 5 6 7 8 9 10 11 12 |
service_id,date,exception_type "TA+b0003","20161226","2" "TA+b0003","20170102","2" "TA+b0003","20170414","2" "TA+b0003","20170417","2" "TA+b0003","20170501","2" "TA+b0003","20170525","2" "TA+b0003","20170605","2" "TA+b0003","20170801","2" "TA+b0007","20161226","2" "TA+b0007","20170102","2" "TA+b0007","20170414","2 |
feed_info.txt
1 2 |
feed_publisher_name,feed_publisher_url,feed_lang,feed_start_date,feed_end_date,feed_version "SBB","http://www.sbb.ch/","DE","20161211","20171209","20170518" |
routes.txt
1 2 3 4 5 6 7 8 9 |
route_id,agency_id,route_short_name,route_long_name,route_desc,route_type "91-10-A-j22-1","37","10","","T","900" "91-10-B-j22-1","78","S10","","S","109" "91-10-C-j22-1","11","S10","","S","109" "91-10-E-j22-1","65","S10","","S","109" "91-10-F-j22-1","11","RE10","","RE","106" "91-10-G-j22-1","11","SN10","","SN","109" "91-10-j22-1","3849","10","","T","900" "91-10-Y-j22-1","82","IR","","IR","103" |
Achtung:
- Einige Routen in GTFS haben eine Erweiterung “-Y”. Der Grund liegt darin, dass sie eine künstlich angelegte Liniennummer haben. Nur so kann “route_short_name” gültig sein. Diese künstlichen Linien sollten den Benutzern nicht angezeigt werden. Für Züge wird “trip_short_name” die Zugnummer beinhalten.
Die Verkehrsmitteltexte, die zur Anwendung kommen (die Variable route_desc enthält Informationen der Spalte “Abbreviation”):
Abbreviation | DE | FR | IT | EN | Ref_TransportMode | route_type |
ASC | Aufzug | Ascenseur | Ascensore | Lift / Elevator | A | 1700 |
B | Bus | Autobus | Autobus | Bus | B | 700 |
BN | Nachtbus | Bus de nuit | Autobus notturno | Night Bus | B | 705 |
BP | PanoramaBus | Bus panoramique | PanoramaBus | Panorama Bus | B | 710 |
BUS | Bus | Autobus | Autobus | Bus | B | 700 |
CAR | Fernbus national | Bus longue distance national | Autobus nazionale a lunga percorrenza | National long-distance bus | B | 202 |
CAX | Fernbus international | Bus grandes lignes international | Autobus a lunga percorrenza internazionale | International long-distance bus | B | 201 |
EB | Eilbus | Bus express | Autobus espresso | Semi fast bus | B | 702 |
EXB | Expressbus | Expressbus | Expressbus | Express bus | B | 702 |
ICB | InterCity-Bus | Bus InterCity | Autobus InterCity | InterCity Bus | B | 202 |
KB | Kleinbus | Minibus | Furgoncino | Minibus | B | 700 |
NB | Nacht-Bus | Bus de nuit | Bus notturno | Night Bus | B | 705 |
NFB | Niederflur-Bus | Bus à plancher surbaissé | Bus a pianale ribassato | Low-floor bus | B | 700 |
NFO | Niederflur-Trolleybus | Trolleybus à plancher surbaissé | Filobus a pianale ribassato | Low-floor trolley bus | B | 700 |
RUB | Rufbus | Bus sur appel | Bus a chiamata | On-demand Bus | B | 715 |
TX | Taxi | Taxi | Tassì | Taxi | B | 1500 |
SL | Sesselbahn | Télésiège | Seggiovia | Chairlift | E | 1300 |
CC | Zahnradbahn | Chemin de fer à crémaillère | Ferrovia a cremagliera | Rack-railroad / Cog Railway | H | 1400 |
GB | Gondelbahn | Télécabine | Ovovia | Gondola lift | L | 1300 |
LB | Luftseilbahn | Téléphérique | Funivia | Cableway / Aerial Ropeway | L | 1300 |
PB | Pendelbahn | Téléphérique à mouvement de va-et-vient | Funivia a movimento va e vieni | Aerial Tramway | L | 1300 |
M | Metro | Métro | Metropolitana | Underground / Metro | M | 401 |
FUN | Standseilbahn | Funiculaire | Funicolare | Funicular | N | 1400 |
BAT | Schiff | Bateau | Battello | Ship / Boat | S | 1000 |
BAV | Dampfschiff | Bateau à vapeur | Battello a vapore | Steam ship / boat | S | 1000 |
FAE | Fähre | Traversier / Ferry | Nave traghetto | Ferry | S | 1000 |
KAT | Katamaran | Catamaran | Catamarano | Katamaran | S | 1000 |
NFT | Niederflur-Tram | Tram à plancher surbaissé | Tram a pianale ribassato | Low-floor Tramway | T | 900 |
T | Tram | Tram | Tram | Tram | T | 900 |
TN | Nachttram | Tram de nuit | Tram notturno | Night Tram | T | 900 |
AIR | Flugzeug | Avion | Velivolo | Airplane | U | 1100 |
UUU | Unbekannte Art | Espèce inconnue | Specie sconosciuta | Unknown mode | U | 1700 |
AG | Agenturzug | Train de l’agence | Treno d’agenzia | Agency Train | Z | 117 |
ARC | Arco | ARCO | ARCO | Arco | Z | 102 |
ARZ | Autoreisezug | Train d’autos accompagnées | Treno auto accompagnate | Car-carrying Train | Z | 104 |
AT | Autotunnelzug | Train-autos Tunnel | Treno per il trasporto di auto in galleria | Auto Tunnel Train | Z | 104 |
ATR | Altaria | Altaria | Altaria | Altaria | Z | 102 |
ATZ | Autotunnelzug | Train-autos Tunnel | Treno per il trasporto di auto in galleria | Auto Tunnel Train | Z | 104 |
AVE | Alta Velocidad ES | Alta Velocidad ES | Alta Velocidad ES | Alta Velocidad ES | Z | 101 |
BEX | Bernina Express | Bernina Express | Bernina Express | Bernina Express | Z | 107 |
CAT | City Airport Train | City Airport Train | Treno città-aeroporto | City Airport Train | Z | 111 |
CNL | CityNightLine | CityNightLine | CityNightLine | CityNightLine | Z | 105 |
D | Schnellzug | Train Express | Treno espresso | Fast Train | Z | 103 |
E | Eilzug | Train accéléré | Treno espresso | Semi fast / non-stop Train | Z | 103 |
EC | EuroCity | EuroCity | EuroCity | EuroCity | Z | 102 |
EM | Euromed | Euromed | Euromed | Euromed | Z | 102 |
EN | EuroNight | EuroNight | EuroNight | EuroNight | Z | 105 |
ES | Eurostar Italia | Eurostar Italia | Eurostar Italia | Eurostar Italia | Z | 101 |
EST | Eurostar | Eurostar | Eurostar | Eurostar | Z | 101 |
EXT | Extrazug | Train spécial | Treno speciale | Special Event Train | Z | 117 |
GEX | Glacier Express | Glacier Express | Glacier Express | Glacier Express | Z | 107 |
IC | InterCity | InterCity | InterCity | InterCity | Z | 102 |
ICE | InterCityExpress | InterCity-Express | InterCityExpress | InterCityExpress | Z | 102 |
ICN | IC-Neigezug | Train pendulaire IC | Treno basculante IC | IC Tilting Train | Z | 102 |
IN | InterCityNacht | Nuit InterCity | InterCityNight | InterCityNight | Z | 102 |
IR | InterRegio | InterRegio | InterRegio | InterRegio | Z | 103 |
IRE | Interregio-Express | InterregioExpress | Interregio-Express | Interregio-Express | Z | 103 |
IT | Italo | Italo | Italo | Italo | Z | 102 |
JAT | Gefängniszug | Train-prison | Treno della prigione | Jail / Prison Train | Z | 111 |
MAT | LeermaterialZug (Reisezugswagen) | Train de matériel vide (voiture de voyageurs) | Treno vuoto (carrozze passeggeri) | Empty material train (passenger carriage) | Z | 111 |
MP | LeermaterialZug Personenbeförd | Train de matériel vide Transport de personnes | Treno materiale vuoto Trasporto passeggeri | Empty material train with passenger transport | Z | 111 |
NJ | NightJet | NightJet | Nightjet | NightJet | Z | 105 |
NZ | Nacht-Zug | Train de nuit | Treno notturno | Night Train | Z | 105 |
P | Zug ohne Gewähr | Train non garanti | Treno senza garanzia | Train without Guarantee | Z | 100 |
PE | PanoramaExpress | PanoramaExpress | PanoramaExpress | PanoramaExpress | Z | 107 |
R | Regio | Train régional | Regio | Regio | Z | 106 |
RB | Regionalbahn | Réseau régional | Ferrovia regionale | Regional train | Z | 106 |
RE | RegioExpress | RegioExpress | RegioExpress | RegioExpress | Z | 106 |
RJ | Railjet | Railjet | Railjet | Railjet | Z | 102 |
RJX | railjet xpress | Railjet Xpress | Railjet Xpress | Railjet Xpress | Z | 102 |
S | S-Bahn | RER | Rete celere regionale | Urban Train | Z | 109 |
SN | Nacht-S-Bahn | RER de nuit | S-Bahn (rete celere regionale) notturna | Night-urban Train | Z | 109 |
STB | Stadtbahn | Chemin de fer urbain | Ferrovia urbana | City Railway | Z | 109 |
TAL | Talgo | Talgo | Talgo | Talgo | Z | 101 |
TER | Train Express Regional | Train Express régional | Treno espresso regionale | Train Express Regional | Z | 106 |
TE2 | TER200 | TER 200 | TER200 | TER200 | Z | 106 |
TGV | Train à grande vitesse | Train à grande vitesse | Train à grande vitesse | Train à grande vitesse | Z | 101 |
THA | Thalys | Thalys | Thalys | Thalys | Z | 101 |
TLK | Twoje Linie Kolejowe | Deuxième Ligne Kolejowe | Linea Twoje Kolejowe | Twoje Line Kolejowe | Z | 102 |
UEX | UrlaubsExpress | UrlaubsExpress | HolidayExpress | UrlaubsExpress (Holiday) | Z | 104 |
VAE | Voralpen-Express | Voralpen-Express | Voralpen-Express | Voralpen-Express | Z | 103 |
WB | Westbahn | Westbahn | Westbahn | Westbahn | Z | 100 |
X | InterConnex | InterConnex | InterConnex | InterConnex | Z | 100 |
X2 | X2000 Neigezug | X2000 Train pendulaire | Treno inclinabile X2000 | X2000 Tilting Train | Z | 100 |
ZUG | Zugskategorie unbekannt | Catégorie de train inconnue | Categoria del treno sconosciuta | Train Category Unknown | Z | 100 |
stop_times.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
trip_id,arrival_time,departure_time,stop_id,stop_sequence,pickup_type,drop_off_type "1.TA.1-9-j17-1.1.H","05:25:00","05:25:00","8502034:0:2","1","0","0" "1.TA.1-9-j17-1.1.H","05:28:00","05:29:00","8502033:0:2","2","0","0" "1.TA.1-9-j17-1.1.H","05:33:00","05:33:00","8502032:0:1","3","0","0" "1.TA.1-9-j17-1.1.H","05:36:00","05:36:00","8502031:0:1","4","0","0" "1.TA.1-9-j17-1.1.H","05:42:00","05:42:00","8502030:0:2","5","0","0" "1.TA.1-9-j17-1.1.H","05:50:00","05:50:00","8502119:0:7","6","0","0" "2.TA.1-9-j17-1.2.H","05:53:00","05:53:00","8502034:0:1","1","0","0" "2.TA.1-9-j17-1.2.H","05:57:00","05:58:00","8502033:0:2","2","0","0" "2.TA.1-9-j17-1.2.H","06:02:00","06:02:00","8502032:0:1","3","0","0" "2.TA.1-9-j17-1.2.H","06:04:00","06:04:00","8502031:0:1","4","0","0" "2.TA.1-9-j17-1.2.H","06:09:00","06:11:00","8502030:0:2","5","0","0" "2.TA.1-9-j17-1.2.H","06:20:00","06:20:00","8502119:0:7","6","0","0" "3.TA.1-9-j17-1.3.H","24:38:00","24:38:00","8502119:0:7","1","0","0" "3.TA.1-9-j17-1.3.H","24:46:00","24:46:00","8502030:0:1","2","0","0" "3.TA.1-9-j17-1.3.H","24:49:00","24:49:00","8502031:0:1","3","0","0" "3.TA.1-9-j17-1.3.H","24:52:00","24:52:00","8502032:0:1","4","0","0" "3.TA.1-9-j17-1.3.H","24:57:00","24:57:00","8502033:0:1","5","0","0" "3.TA.1-9-j17-1.3.H","25:01:00","25:01:00","8502034:0:1","6","0","0" |
stops.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
stop_id,stop_name,stop_lat,stop_lon,location_type,parent_station "1101064","Malpensa Aeroporto, terminal 1","45.6272144319203","8.7111160249179","","" "8000339","Weissenhorn Eschach","48.3010036099201","10.135089480891","","" "8000709:0:2","Neckarsulm Mitte","49.1934688770383","9.22294014126908","","" "8000778","Asselheim (D)","49.5762169849528","8.16159859923981","","" "8000781","Grünstadt-Nord","49.5733510011593","8.17078836459763","","" "8000988","Witzighausen","48.3174402469306","10.097800413442","","" "8002015","Nördlingen","48.85084676195","10.4978651252803","","8002015P" "8002015:0:4","Nördlingen","48.85090587299","10.4978651252803","","8002015P" "8002015P","Nördlingen","48.85084676195","10.4978651252803","1","" "8002023","Ebermergen","48.7562093140126","10.7109634770088","","" "8002023:0:1","Ebermergen","48.7562685367003","10.7109634770088","","" "8002038","Möttingen","48.8068073922247","10.5978386332639","","8002038P" "8002038:0:1","Möttingen","48.8069257181851","10.5978386332639","","8002038P" "8002038:0:2","Möttingen","48.8068665552398","10.5978386332639","","8002038P" "8002038P","Möttingen","48.8068073922247","10.5978386332639","1","" "8002039","Hoppingen","48.8038195691943","10.6532018042319","","" |
Die Steige müssen in GTFS als einzelne Halte modelliert werden. Ein Wechsel des Steigs ist dann ein Wechsel des Stops aus Sicht GTFS.
Das Beispiel “8500010” (Basel SBB):
Alle Halte von Basel haben einen gemeinsamen “Parent” “8500010P”. Die einzelnen Gleise sind mit “:” abgetrennt. Ein “Gleis” kann auch ein Gleis+Sektoren sein (Bsp: “8500010:0:7CD”). Es gibt auch sehr komische Ergänzungen, wie “Bern Bfpl” also “8507000:0:Bfpl”, wenn die RBS ihn für Bahnersatzbusse verwendet.
trips.txt
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 |
route_id,service_id,trip_id,trip_headsign,trip_short_name,direction_id "1-9-j17-1","TA+b0001","2.TA.1-9-j17-1.2.H","Lenzburg","21916","0" "1-90-j17-1","TA+b0001","4.TA.1-90-j17-1.2.R","Wallbach, Gemeindehaus","90074","1" "1-90-j17-1","TA+b0001","10.TA.1-90-j17-1.2.R","Wallbach, Gemeindehaus","90022","1" "1-90-j17-1","TA+b0001","43.TA.1-90-j17-1.13.R","Schupfart, Dorf","90071","1" "1-90-j17-1","TA+b0001","44.TA.1-90-j17-1.13.R","Schupfart, Dorf","90013","1" "1-90-j17-1","TA+b0001","50.TA.1-90-j17-1.13.R","Schupfart, Dorf","90067","1 "8002015P","Nördlingen","48.85084676195","10.4978651252803","1","" "8002023","Ebermergen","48.7562093140126","10.7109634770088","","" "8002023:0:1","Ebermergen","48.7562685367003","10.7109634770088","","" "8002038","Möttingen","48.8068073922247","10.5978386332639","","8002038P" "8002038:0:1","Möttingen","48.8069257181851","10.5978386332639","","8002038P" "8002038:0:2","Möttingen","48.8068665552398","10.5978386332639","","8002038P" "8002038P","Möttingen","48.8068073922247","10.5978386332639","1","" "8002039","Hoppingen","48.8038195691943","10.6532018042319","","" "1-350-j16-1","TA","49.TA.1-350-j16-1.2.R","1-350-j16-1.2.R","Zürich, Triemli","1" |
Achtung:
- Für Züge beinhaltet “trip_short_name” die Zugnummer.
- Ein “trip” gemäss GTFS repräsentiert in Transmodel den Begriff einer “DatedVehicleJourney” (in OJP eine “DatedJourney”). In Transmodel und OJP ist ein Trip eine Reise des Kunden, wie sie vom Trip Planner zurückgegeben wird. Sie besteht aus verschiedenen Teilfahrten, Umsteigen und anderen Wegen, die mit verschiedenen Modi zurückgelegt werden müssen. In HRDF entspricht das GTFS-“trip” der Fahrt und in NeTEx der ServiceJourney.
transfers.txt
Das File transfers.txt bildet die Metabahnhöfe mit ihren entsprechenden Umsteigezeiten ab. Ein Metabahnhof besteht bspw. aus dem Bahnhof und den umliegenden Bus- oder Tramhaltestellen. Die Umsteigeart und -zeiten zu den entsprechenden Haltestellen können in dieser Datei spezifiziert werden.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 |
from_stop_id,to_stop_id,transfer_type,min_transfer_time "8500125:0:2","8581833","2","120" "8500125:0:1","8504114","2","120" "8500125:0:1","8581833","2","120" "8500123:0:13","8576779","2","60" "8500122:0:2","8572021","2","60" "8500122:0:2","8582973","2","300" "8500122:0:1","8572021","2","60" "8500122:0:1","8582973","2","300" "8500121:0:2","8581130","2","60" "8500121:0:2","8582149","2","120" "8500120:0:1","8582081","2","180" "8500120:0:1","8579767","2","60" "8500120:0:1","8582562","2","120" |
Stabilität von Identifiern zwischen Versionen des GTFS-Static-Files
Jede Woche wird das GTFS Static zweimal neu erzeugt. Daher kann es sein, dass die “service_id” und die “trip_id” nicht identisch sind.
Wann gibt es neue GTFS-Static-Files?
Jeweils am Montag und Donnerstag zwischen 9 und 10 Uhr wird das neue HRDF (Basis für GTFS-S) publiziert.
Gleichentags um 15 Uhr wird jeweils der dazu passende GTFS-RT Feed aktiviert. (Seit 26.09.2024 wird im Header per FeedVersion auf die jeweils passende GTFS-Static-Version verwiesen, siehe Dokumentation GTFS-RT)
Publikation HRDF | Publikation GTFS-S | Aktivierung GTFS-RT |
Freitag | Montag zwischen 9 und 10 Uhr | Montag 15 Uhr |
Mittwoch | Donnerstag zwischen 9 und 10 Uhr | Donnerstag 15 Uhr |
Interne Konsistenz eines GTFS-Static-Files
Wir bemühen uns, immer korrekte GTFS-Static-Files zu produzieren. Google schlägt vor, die interne Konsistenz mit dem FeedValidator zu testen. Leider kann die aktuelle Version mit der Grösse unserer Datei nicht umgehen. Ein anderes mögliches Werkzeug ist gtfstidy, das unter anderem eine Validierung vornehmen kann mit dem Parameter “-v”
Fragen & Antworten
Was bedeuten die ersten und letzten beiden Abschnitte der trip_id? Z. B. {405}.TA.26-752-j17-1.{3}.{R} | Die trip_id besteht aus den folgenden Teilen: “<fortlaufende Nummer in der trips.txt>.<service_id>.<route_id>.<Fahrwegsnummer>.<Fahrtrichtung>”
route_id = <Betriebszweig>-<Liniennummer>-<Projektkurzbezeichnung>-<Linienversionsnummer> |
Wie setzt sich die Trip ID zusammen? | Die Trip ID setzt sich aus unterschiedlichen Nummern/Feldern zusammen und hat nichts mit den HRDF-Daten zu tun.
Die Zuordnung ist nicht ganz 1:1, da die Fahrt ID (= Fahrtnummer) nicht unique sein muss innerhalb eines HRDF-Datensatzes. Aber unter Zuhilfenahme von Haltestellen und Haltezeiten, wie der Datennutzer das gemacht hat, lässt sich die passende Fahrt wie folgt finden: In der trips.txt steht der trip_short_name: route_id,service_id,trip_id,trip_headsign,trip_short_name,direction_id “26-94-j18-1″,”TA+b20xg”,”310.TA.26-94-j18-1.3.R”,”Zürich Oerlikon, Bahnhof”,”13628″,”1″ Dieser entspricht der Fahrtnummer (externe Zugnummer) in der *Z-Zeile der FPLAN-Datei: Da die Fahrtnummer wie erwähnt nicht unique sein muss innerhalb eines HRDF-Feeds, sollte man zusätzlich die Haltezeiten und stop_ids der Fahrt aus der stop_times.txt zur Zuordnung mit heranziehen: trip_id,arrival_time,departure_time,stop_id,stop_sequence,pickup_type,drop_off_type “310.TA.26-94-j18-1.3.R”,”13:37:00″,”13:37:00″,”8587651″,”1″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:38:00″,”13:38:00″,”8587652″,”2″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:39:00″,”13:39:00″,”8591263″,”3″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:41:00″,”13:41:00″,”8591347″,”4″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:42:00″,”13:42:00″,”8591047″,”5″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:43:00″,”13:43:00″,”8591113″,”6″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:44:00″,”13:44:00″,”8591330″,”7″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:45:00″,”13:45:00″,”8591319″,”8″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:46:00″,”13:46:00″,”8591175″,”9″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:46:00″,”13:46:00″,”8591273″,”10″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:48:00″,”13:48:00″,”8591382″,”11″,”0″,”0″ “310.TA.26-94-j18-1.3.R”,”13:49:00″,“13:49:00″,”8580449”,”12″,”0″,”0″ Es passt immer der einen Tag jüngere HRDF-Feed (z. B. 25.09.2024) zum GTFS-Feed (z. B. 26.09.2024) |
Weiterführende Angaben
- Weiterführende Angaben zu GTFS Static finden Sie auf der GTFS-Entwicklerseite von Google: https://developers.google.com/transit/gtfs/
- Online-Meetup vom 13.11.2023: Wie GTFS-Datenfeeds zur Verbesserung des öffentlichen Verkehrs nachhaltig beitragen