Query public transport connections for set of trip requests (from origin to a destination at given departure time).
This python library uses OpenTripPlanner to query single or multiple trips (origin, destination, departure time) for their detailed PT routes.
It was succesfully applied to query 3 million trips from 6 different cities in one of our research projects.
fig.1 Sample query in Amsterdam
fig. 2 Input
fig.3 Output
- .csv file with requests georequests.csv
- .dbf file with OSM network (available e.g. here)
- .zip with GTFS file for the area and date that we query (available e.g. from transit.land)
- both OSM and GTFS file shall be stored in
data
folder
- .csv with trip details (time, transfers, modes, wait and walk times, etc.) georequests_PT.csv
- single trips and visualization in this tutorial notebook
- running the OTP server notebook
- bulk queries (up to millions of requests):
python main.py
(c) Rafał Kucharski, SmartPTLab, TU Delft