Make them trip patterns bendy instead of spiky
Once you deploy digitransit with your GTFS feeds, you might encounter spiky trip shapes that don’t follow street geometry. Here is how to fix this.
Fellow developer Vlatko from the City of Osijek sent us this screenshot. The bus appears to just bulldoze through buildings, not following any street geometries at all.
What happens here is the following. GTFS has a separate file called
shapes.txt that defines shape geometries for trip patterns. Within
trips.txt, individual trips can reference a
shape_id they adhere to.
shapes.txt is not defined within your GTFS feed (and many feeds do not provide shapes right now), digitransit/OpenTripPlanner will only display the linear distance between individual stop points – regardless of the actual route the trip should take.
How to mitigate this
There are several approaches to retroactively add shapes to your existing GTFS feed. We have tried two variants and can recommend them both:
Conveyal Transit Data Tools
This is a complete software suite you can access through your browser in order to edit, reconfigure or even build your GTFS feed from scratch. Good for getting a first feel for your feeds and analyzing them.
pfaedle is a command line tool by Patrick Brosi that matches GTFS feeds to OpenStreetMap relations very precisely. This might take a bit longer to set up initially and adapt to your needs, but once it runs it should save you time in the long run.