djaychela / kingfisher

ORR 2021/22 passenger travel data projected onto the centre-line track-model

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

kingfisher

Using the Office of Road and Rail 2021/22 passenger travel data projected onto a shortest-path network using the centre-line track-model this project looks to create visualisation for passenger journey numbers for the active rail stations across the British rail network.

Aggregated Passenger Journeys Colour Scale Passenger Journeys

Station Flow

Individual station flows for the 2,567 stations on the mainline British rail network here. This is in a two column format.

Data

All data used on the basis that it under open or permissive license

  1. The base map of mainland Britain is derived from the WorldPop base maps under CC 4.0 by deed retrieved 2023-09-07.
  2. The centre-line track-model is hosted by OpenRailData under the Open Government License by Network Rail retrieved 2023-07-11.
  3. The Origin Destination Matrix data was published by the Office of Road and Rail on the Rail Development Group Rail Data Market place, details here under the Open Government License. With a variant retrieved from AutomaticKnowledge dated 2023-12-06.
  4. The Network Rail CORPUS dataset is an open data feed which is released under a OGL retrieved 2023-11-29.
  5. The National Public Transport Access Network NaPTAN under OGL, and is updated each time the scripts are run.
  6. OpenStreetMap data is then used to validate and also to identify 10 stations locations which is licensed under CC-BY-SA 2.0 through the OverPassAPI Turbo service, and is updated each time the scripts are run.

Implementation Detail

This is likely to only be of interest if you were interested in recreating the repository yourself

Running the Code

The repository has been updated with beta version of the code tested under Linux Mint 21.2 Victoria and python 3.11. This is then a set of details about some of the murky workings of how this hangs together.

Installation and Execution

To execute the code on a Linux Debian or similar environment with a working python3, run the run.sh script:

   $ ./run.sh

This takes quite a long time. On my old kit quite few hours to complete all the processing. It then carries out a number of steps which are meant to:

  • create the directory structure,
  • install required python dependencies in in a local venv virtual enviroment,
  • download additional data,
  • create a cache file work/odm-path.gpkg containing intermediate data layers
  • create 2,567 GeoPKG files for each station on the mainland network in the output directory
  • create a journeys-all.gpkg file with an aggregated total for all network segments in the model,
  • create 2,567 PNG image files for each station in a heirachy of directories in the image directory
  • create a two-column station.md markdown file with a link to each image file

Acknowledgment

The travel data was kindly provided by Alasdair Rae with the centre-line track-model by Peter Hicks through #OpenRailData.

License

The images in the image directory are under the CC BY 4.0 license The repository code and scripts are under the Apache 2.0 license

Thanks

Thanks is then given to WorldPop, Network Rail, the Office of Road and Rail, the Rail Delivery Group, the UK Department for Transport, the maintainers of the OverPassAPI, and all the contributors to OpenStreetMap for kindly providing their data for use in this project.

About

ORR 2021/22 passenger travel data projected onto the centre-line track-model

License:Apache License 2.0


Languages

Language:Python 96.9%Language:Shell 3.1%