Questions tagged [gtfs]

The General Transit Feed Specification (GTFS) defines a common format for public transportation schedules and associated geographic information.

The General Transit Feed Specification (GTFS) defines a common format for public transportation schedules and associated geographic information. GTFS "feeds" allow public transit agencies to publish their transit data and developers to write applications that consume that data in an interoperable way. GTFS-realtime is an extension to GTFS that allows public transportation agencies to provide realtime updates about their fleet to application developers.

273 questions
3
votes
7 answers

mySQL - Load GTFS Data

I was wondering if anyone has had any success loading GTFS data to a mySQL database. I've looked all over the place for a good tutorial but I can't find anything that has been helpful.
Mikerizzo
  • 587
  • 1
  • 4
  • 22
3
votes
3 answers

Determine correct GTFS stop order without using stop_sequence?

I am using a GTFS feed for an app I am working on. I am attempting to list all of the stops for a chosen route. Currently, I am attempting to order the list by stop_sequence, but this is not working properly since some trips do not go to every stop…
btse
  • 7,811
  • 3
  • 25
  • 30
3
votes
2 answers

GTFS/NextBus/Google Maps - transit distance traveled

I am trying to get the distance traveled on a transit route -- particularly San Francisco MUNI, but the standards NextBus, GTFS, and Google Maps API appear to be universal. I'm comfortable using any of these APIs, I'm just not sure how to go about…
carillonator
  • 4,715
  • 3
  • 29
  • 39
3
votes
1 answer

Android consuming GTFS-Realtime (NO API)

This is not an optimal solution, but I'm working on an Android app that must consume GTFS-Realtime data as an API is not available. The datasets will be small, the max # of vehicles being tracked at one time will be 8-10, or I would consider…
CampbellGolf
  • 812
  • 12
  • 27
2
votes
1 answer

Does an Android ContentProvider exist for storing and providing Google Transit Feed data?

I am writing an Android app for my local transit authority. They publish their data in the the Google Transit Feed Specification (GTFS). I'd need to download this feed and save it to the device and allow my application to access the contents. Since…
ipetrik
  • 1,749
  • 18
  • 28
2
votes
2 answers

R intersecting multiple (2+) overlapping polygons

I am having some issues with st_intersection. I am trying to intersect polygons from bus stop buffers in preparation for areal interpolation. Here are the data: Here is the data: https://realtime.commuterpage.com/rtt/public/utility/gtfs.aspx Here is…
2
votes
1 answer

Using R to convert GTFS spatial data from character to numeric

I am following a vignette for gtfstools (https://cran.r-project.org/web/packages/gtfstools/vignettes/gtfstools.html) but am getting stuck with the data format. Basically, I am linking to a gtfs dataset, which is a zip folder with .txt files inside…
2
votes
2 answers

Converting protobuf feed to pandas dataframe

I'm trying to covert a protobuf feed to pandas dataframe for one of my hobby projects. I tried several different techniques to accomplish this but nothing seems to really solve my issue. I use following code to retrieve GTFS-RT TripUpdates…
user07345
  • 25
  • 1
  • 7
2
votes
2 answers

Download files in R with URLs that do not end with the file extensions

Does anyone have a trick up there sleeve for downloading GTFS using R when the URL doesn't end with ".zip"? For instance, this works: download.file(url = "http://www.transperth.wa.gov.au/TimetablePDFs/GoogleTransit/Production/google_transit.zip",…
Anthony
  • 23
  • 2
2
votes
0 answers

get transit time with GTFS on Python

I need to create/get an algorithm to find the shortest route between two stops using GTFS files in Python. I've already found the partridge, peartree and networkx libraries. However, I need more explanations or documentations about converting a GTFS…
Pi-R
  • 644
  • 3
  • 10
2
votes
2 answers

How do I improve the speed of this parser using python?

I am currently parsing historic delay data from a public transport network in Sweden. I have ~5700 files (one from every 15 seconds) from the 27th of January containing momentary delay data for vehicles on active trips in the network. It's,…
eriknson
  • 43
  • 4
2
votes
1 answer

GTFS-realtime feed is incorrectly reported to be missing a header

I am trying to parse a gtfs-realtime transit feed in Android. I have made a barebones Android app, that uses the Java GtfsRealtime binding library based on the sample code shown here:…
HiddenNetwork
  • 97
  • 1
  • 8
2
votes
2 answers

Parse GTFS realtime without protobuf with python

I am trying to parse GTFS realtime trip_update data that is a plain text file format and not in a pb (protobuf) format. (here is the feed url) https://extranet.trainose.gr/epivatikos/transit/trip_updates However, the only examples that I find deal…
PKey
  • 3,715
  • 1
  • 14
  • 39
2
votes
1 answer

GTFS to graph conversion?

I aim to "translate" GTFS files (non realtime) into directed graphs. Is there any API / tool that can do that easily ? I would like to create a graph per route in my GTFS, and then store it into a file. So far I made a few tests using Python and…
Arkeen
  • 554
  • 8
  • 20
2
votes
1 answer

Why are extension attributes inaccessible in python protobuf objects?

I am attempting to read and analyze GTFS-realtime data from the NYC subway in Python. So far, I have successfully used both gtfs-realtime.proto and nyct-subway.proto to generate the proper Python classes and parsed the protobuf data into Python…