Skip to content

GEE tasks is a workflow manager for Google Earth Engine processes

Notifications You must be signed in to change notification settings

FENIX-Platform/fenix-geo-gee_tasks

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

What is GEE tasks

GEE tasks is a workflow manager for executing tasks and processing in Google Earth Engine and then getting back the result locally. It is a simple Django app that is using Channels for scheduling jobs asyncronously into a Celery application and monitoring their status through a web API. The status of each job can be monitored through the websocket channel in a dashboard page.

Quick start

  1. Add "gee_tasks" to your INSTALLED_APPS setting like this:
INSTALLED_APPS = (
    ...
    'gee_tasks',
    'jobs',
    'api',
    #etc
)
  1. In your settings.py or local_settings.py file, add a CELERYBEAT_SCHEDULE setting to specify when Celery should run jobs tasks:
from celery.schedules import crontab
CELERYBEAT_SCHEDULE = {
    'mytask-every-1minute': {
        'task': 'jobs.tasks.download',
        'schedule': crontab(minute='*/1'),
    },
}
  1. In your settings or local_settings file, add the configuration of Channels for using a REDIS back-end:
# Channels settings
CHANNEL_LAYERS = {
    "default": {
        "BACKEND": "asgi_redis.RedisChannelLayer",  # use redis backend
        "CONFIG": {
            "hosts": [os.environ.get('REDIS_URL', 'redis://localhost:6379')],  # set redis address
        },
        "ROUTING": "gee_tasks.routing.channel_routing",  # load routing from our routing.py file
    },
}

How to run/debug

Start the Celery process with DEBUG logging:

celery worker -A gee_tasks -l debug -B

Start the Django application as usual in your virtual environment:

python manage.py runserver

Access the Dashboard and API

Dashboard - Dashboard

API page:

DjangoRestFramework

Swagger

About

GEE tasks is a workflow manager for Google Earth Engine processes

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published