NMBS going Open Data

 

Hi! Let me first give you a introduction of the members of the #oSoc15 iRail-team.
We are:

We’re both back-end developers and this summer we’ll make Open Data of the Belgian railway company NMBS.

Our project exists out of two parts: GTFS and GTFS-RT.

In this blogpost I’ll explain briefly what those are and why they are so useful.

GTFS

GTFS stands for General Transit Feed Specification. It’s a reference for transit companies to open their data. It exists out of a few CSV-files and every field in those files has its own meaning.

A quick example: stop_times.txt

This file contains the departure and arrival times of a specific vehicle (train in our case) for a specific trip. For example: train L1234 arrives at 12:15 during its trip from Aalter to Ghent-Sint-Pieters.

Our job is to generate these files for all the trains of the NMBS. This is not an easy job, because we have to scrape the data from their website. Here’s an example of data we use from the Belgian railway website to generate dates when certain trains are driving:

NMBS trainservice data

With this data apps can be build by the community and improve the daily lives of commuters. It’s also this data Google uses for its own routeplanner in Google Maps.

To find more information about GTFS: https://developers.google.com/transit/gtfs/reference

GTFS-RealTime

GTFS is just static data, but in real life delays, accidents… happen. Here’s where GTFS-RT comes in.

GTFS-RT is a feed specification for transit companies to provide realtime updates about their fleet.

Our job is to make a feed of:

  • trip updates: a train is in delay or cancelled
  • service alerts: when something unforeseen happens like an accident
  • vehicle positions: information about trainlocations

The technical side of how this feed works will be for a next blogpost.

To find more information about GTFS-RT: https://developers.google.com/transit/gtfs-realtime/

Thanks

This project is a collaboration between be-mobile and iRail.

Also big thumbs up to our mentor Xavier and #iSoc12 alumna Miet for making it possible to have a full two-person team.

Skip to toolbar