Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/eodcgmbh/eodc-openeo-bindings
Functions to translate openeo syntax to tools used at EODC (process graph to Apache Airflow DAG, process to eoDataReaders)
https://github.com/eodcgmbh/eodc-openeo-bindings
Last synced: about 1 month ago
JSON representation
Functions to translate openeo syntax to tools used at EODC (process graph to Apache Airflow DAG, process to eoDataReaders)
- Host: GitHub
- URL: https://github.com/eodcgmbh/eodc-openeo-bindings
- Owner: eodcgmbh
- License: mit
- Created: 2019-09-19T08:48:54.000Z (over 5 years ago)
- Default Branch: master
- Last Pushed: 2020-10-28T12:12:44.000Z (about 4 years ago)
- Last Synced: 2023-03-03T11:33:50.409Z (almost 2 years ago)
- Language: Python
- Size: 34.7 MB
- Stars: 0
- Watchers: 4
- Forks: 0
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.rst
- License: LICENSE.txt
Awesome Lists containing this project
README
# eodc-openeo-bindings
This package contains classes and functions to convert a job from the openEO syntax to an Apache Airflow DAG or basic
Python script, both relying on eoDataReaders for data processing.## Installation
Conda:
```
conda env create -f conda_environment.yml
python setup.py install
```Virtualenv
```
virtualenv eodc-openeo-bindings -p python3.6
source activate eodc-openeo-bindings
python setup.py install
```
In case you want to run tests also run
```
pip install -r requirements-test.txt
```## Run tests
Important: currently the tests rely on having a local CSW server set up as described in
https://github.com/Open-EO/openeo-openshift-driver/tree/master/cswTo execute the tests (Make sure you installed the test requirements - see section above):
`python setp.py test`## Examples
Create Apache Airflow DAG file (naming: `dag_.py` - `_parallelized` is added to the end of the name if the dag
is to be run in parallel):
```python
from eodc_openeo_bindings.job_writer.dag_writer import AirflowDagWriterwriter = AirflowDagWriter() # class can be initiated before usage and can then be reused multiple times
# the ProcessGraphJson can be either a dictionary or a path to a ProcessGraph json-file
writer.write_and_move_job(job_id="job-1234", user_name="test-user", process_graph_json={}, job_data="/path/to/job/folder")
```Create Python script:
```python
from eodc_openeo_bindings.job_writer.basic_writer import BasicJobWriterwriter = BasicJobWriter()
writer.write_job(process_graph_json="/path/to/process_graph.json", job_data="/path/to/job/folder")
```### Note
This project has been set up using PyScaffold 3.1. For details and usage
information on PyScaffold see https://pyscaffold.org/.