Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Transferred from GitLab] Implement a function to extract bus stops for a given route #4

Closed
daphshez opened this issue Jul 12, 2016 · 3 comments
Assignees

Comments

@daphshez
Copy link
Collaborator

daphshez commented Jul 12, 2016

Need to implement a function which gets a bus route + departure stop and returns a list of stops for that route.

Originally posted by @johananl

@johananl johananl self-assigned this Jul 14, 2016
@johananl
Copy link

Should this function query the DB or CSV files?
Also, do we have a running DB with sample data already?

@daphshez
Copy link
Collaborator Author

see this issue for the status of the GTFS DB. I believe the short version is that the database is ready but the load script still needs updating.

Whether DB or CSV should be used depend on what you need this for.

It's not a problem to add write a function that finds it using the GTFS class, and especially if route stories were generated.
But reading the entire GTFS to query a single route will be quite slow.

So maybe you better explain the use case...

@daphshez
Copy link
Collaborator Author

I implemented an interactive script that exports the stops for a line:

https://github.com/hasadna/open-bus/blob/master/gtfs/parser/line_stops_finder.py

It's interactive because it gives you all the routes that match a given line number, and asks you to choose which one you want.

It works with the GTFS file rather than DB. It also requires route stories.

I think that covers this task for now (maybe we would want to re-implement in the future using DB), so I am closing it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants