Skip to content

Latest commit

 

History

History
71 lines (41 loc) · 2.23 KB

File metadata and controls

71 lines (41 loc) · 2.23 KB

CWNS and Power Stations Locations with Proximity to Coastline

This repo is used in a data pipeline to take CWNS data and Power Station data and calculate proximity to coastline. This repeats the process for proximity to train and port locations.

This expects the data sources to be downloaded and existing in the same folder.

The main.js file in ee-source can be used in Google Earth Engine to produce an output such as this:

Google Earth Engine

This can can also be used in Google Looker to produce the following:

Google Looker Studio

Distance to coast

Adapted from Find closest point to shapefile coastline in Python.

Data used

Intermodal Freight Facilities Marine Roll-on/Roll-off

Intermodal Freight Facilities Rail TOFC/COFC

Clean Watersheds Needs Survey (CWNS) – 2012 Report and Data

Natural Earth 50m Coastline

WRI Global Power Plant Database

Thermoelectric cooling water data

Prerequisites

You will need an OpenAI API key to get started.

1. Create the config file

Copy config.sample.ini to config.ini and customize.

2. Set up your python environment

python -m venv env

source env/bin/activate

pip install -r requirements.txt

also run:

pip install wheel
pip install earthengine-api --upgrade

Running

# the first script must run in windows bash, needs ODBC to query mdb
python 1-mdb-to-csv.py
python 2-cwns-calculate-distance-to-coast.py
python 3-power-calculate-distance-to-coast.py
python 4-transport.py
python 5-distance-to-transport.py
python 6-earth-engine.py