Closed elliottwilliams closed 7 years ago
You're very welcome!
I just tried dropping SFMTA's data set in. I had to add one change to strip leading whitespace from tokens (they represent empty strings as " "
), but otherwise it works great:
Their stop_times.txt
is 47.6MB. Timetable takes almost 700MB to index this.
...but it's still got sub-millisecond lookups :)
BART works! Here's an overview of the changes I made to Timetable to get it here:
New features:
post_init
member functions to all GTFS classes. These are called fromfield_mapper
once a GTFS object is parsed, and are used to define substitutions. For example, BART don't have stop codes, but have reasonable stop IDs, sogtfs::stop::post_init()
falls back to usingid
ascode
if no code exists.calendar.txt
. This required adding logic to determine the weekday inDateTime
.Bug fixes:
Visit
in a result would get a reference to the samestop_time
reference.DateTime::resolve()
. I'm not entirely sure why this matters but it fixed off-by-one-hour errors for BART's data.I've tested visits_between with Citybus haven't seen any regressions yet.