mapourtransit / gtfs-maker

From OSM to GTFS
GNU Affero General Public License v3.0
10 stars 1 forks source link

Incorrect frequency definition #15

Closed mstn closed 9 years ago

mstn commented 9 years ago

From feedback by Travic.

For example, Line 13 is defined to have a frequency of 60 Minutes. However, in frequencies.txt, you define the starting time of the frequency period to be 00:01:00. You have to keep in mind that absolute values defined in stop_times are ignored if a frequency is set for this trip. From the GTFS spec:

When trips are defined in frequencies.txt, the trip planner ignores
the absolute values of the arrival_time and departure_time fields
for those trips in stop_times.txt. Instead, the stop_times table
defines the sequence of stops and the time difference between each stop.

This means that, despite the fact that the first trip of Line 13 starts at 7:45 in the morning, you are actually defining Line 13 to start at 00:01:00, which means a trip of Line 13 starts at 00:01:00, 01:01:00, 02:01:00, 03:01:00 and so on. You have to set the start_time in frequencies.txt to the exact time the first trip of this line starts and the end_time to the exact time the last trip of this line starts (for example, if the last trip for Line 13 starts at 22:45, then you have to set end_time to 22:45 (or any other value smaller than 22:45 + 60 minutes (the frequency)).

elf-pavlik commented 9 years ago

Please continue in Matera specific repo: https://github.com/unmonastery/matera-gtfs/issues/7