-
-
Notifications
You must be signed in to change notification settings - Fork 8
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
import routes and trips #26
Comments
Hi @stefanocudini, could you please explain a little more about why you would like route shapes imported and how they would improve search results? |
Hi @missinglink The gtfs routes are geometric objects having the same structure as the streets.. having a name and a description. I think it could be useful for an user to be able to search for the name of a bus route in a certain area |
Moreover importing gtfs trips would give the possibility through pelias to search for public transport by times, but ok this may be a little beyond what is expected of a geocoder |
It's an interesting suggestion, however I think it might be difficult to implement this feature well within a geocoder. Records in Pelias are stored as points, streets are simplified to their midpoint. This makes things much easier for consumers as they only have to deal with point geometries. If someone were to search for a transit route, such as 'U2' (Berlin Ubahn) then it's not clear what should be returned in the results. We could return a list of the train stations but we'd have no way of scoring them, so it would be an unordered list. The other option would be to return the geometry of the route. I think this might be out-of-scope for a geocoder and would be better implemented in a routing engine. A hybrid solution would also work well, where the routes are indexed in Pelias with their centroid and a foreign key is stored using the new addendum feature of Pelias which would allow you to make a second request to the routing engine for extended information such as the shape, list of stops and departure times. |
see: pelias/api#1255 |
Hi @stefanocudini ... I added transit routes in a previous geosearch / transit app (https://ride.trimet.org -- search for something like "2-Division"). For the geosearch point result, I calculated a bounding box around the route, and used the centroid of said bbox (not the best point, but...). Over the years, I'm not sure anyone ever really used the route search results. I originally intended to highlight the route upon search, but never got around to it; and with no one really asking, that idea was kinda shelved. FWIW, calculating the route geometry from GTFS, or even what stops belong to a route, is somewhat complex. I feel it's too complex a process to do in the Pelias loader (e.g., I wouldn't do it there). Rather, if in the future I add TriMet routes to my instance of Pelias, I'll generate a .csv file of routes and point(s) using http://gtfsdb.com, and load things into Pelias via https://github.com/pelias/csv-importer |
Now is possible integrate shapes of routes from gtfs files?
could it make sense to add this function and also import the gtfs shapes into Pelias?
The text was updated successfully, but these errors were encountered: