This is the main repository for the Emissions API.
- numpy
- gdal (C Library and Python bindings)
- SQLAlchemy
- GeoAlchemy2
- psycopg2
- Connexion
- swagger-ui-bundle
- geojson
- PyYAML
- sebtinel5dl
- iso8601
These can be installed by executing
pip install -r requirements.txt
Follow this guide to install GDAL. For some reason pip have trouble to install the gdal package using pip. The easiest way to fix this is to manually install the wheel package from lfd.uci.edu. Note that the packages are unoffical windows binaries. Install the wheel package with
pip install <FILENAME>
Note that you do not need to install this project to run the different parts of it. But you can install this tool and its binaries in your environment by executing
python setup.py install
Emissions API will look for configuration files in the following order:
- ./emissionsapi.yml
- ~/emissionsapi.yml
- /etc/emissionsapi.yml
A configuration file template can be found at etc/emissionsapi.yml
.
To get started, just copy this to the main project directory and adjust the
values if the defaults do not work for you.
To build the documentation you need to have sphinx
and sphinx-rtd-theme
.
With that installed, simply run
make -C docs clean html
To execute the programs in this project run
- download:
python -m emissionsapi.download
- preprocess:
python -m emissionsapi.preprocess
- web:
python -m emissionsapi.web
or execute the binaries after installation
- download:
emissionsapi-download
- preprocess:
emissionsapi-preprocess
- web:
emissionsapi-web
This project is using a PostgreSQL database with the PostGIS extension. Attention: PostGIS is not yet available for the newest PostgreSQL v.12.
There is a simple docker-compose.yml
file to make it easier to setup a
database for development.
You can also setup the database on your own.