Data processing, modelling, analysis and visualisation for a Vietnam Transport Risk Analysis.
Documentation is available at ReadTheDocs
A report based on the analysis is available at:
Oh, J.E., Espinet Alegre, X., Pant, R., Koks, E.E., Russell, T., Schoenmakers, R. and Hall, J.W. (2020) Addressing Climate Change in Transport: Volume 2: Pathway to Resilient Transport. World Bank, Washington DC. DOI: 10.1596/32412
Python version 3.6 is required to run the scripts in this project. We suggest using miniconda to set up an environment and manage library dependencies.
Create a conda environment from the environment.yml
definition:
conda env create -f environment.yml
conda install python-igraph
See http://igraph.org/python/ for instructions on Windows installation of python-igraph
.
Activate the environment:
conda activate vietnam-transport
Set up the vtra
package (this project) for development use:
python setup.py develop
The economic model uses GAMS (General Algebraic Modeling System) via its python API. GAMS provide installation and licensing instructions.
The location of data and output files are configured by a config.json
file. Copy
config.template.json
and edit the file path details to locate the files on your system.
Note that on Windows, you will need to use double backslashes (\\
) in the file paths, for
example:
"data": "C:\\Users\\Username\\projects\\vtra\\data"
Make sure not to commit data inadvertently if working with jupyter notebooks. Suggest using nbstripout to automatically strip output.
Install git hooks to filter notebooks when committing to git:
cd /path/to/vietnam-transport
nbstripout --install
This project has been developed by Oxford Infrastructure Analytics as part of a project funded by the World Bank.
All code is copyright Oxford Infrastructure Analytics, licensed MIT (see the LICENSE
file for
details) and is available on GitHub at
oi-analytics/vietnam-transport.