actinia-org / actinia-core

Actinia Core is an open source REST API for scalable, distributed, high performance processing of geographical data that uses mainly GRASS GIS for computational tasks (DOI: https://doi.org/10.5281/zenodo.5879231) | Tutorial: https://actinia-org.github.io/actinia-core/ | Docker: https://hub.docker.com/r/mundialis/actinia-core
https://actinia.mundialis.de/
GNU General Public License v3.0
78 stars 23 forks source link

Add "tgis" support in actinia for persistent processing and export #192

Open neteler opened 3 years ago

neteler commented 3 years ago

At time the directory tgis is not yet copied:

https://github.com/mundialis/actinia_core/blob/e1510fce08f8d40d5fc048dc7fd81e920ed5ffc3/src/actinia_core/resources/persistent_processing.py#L477

In addition, the support needs to be added also in some other places:

For inspiration, see https://redocly.github.io/redoc/?url=https://actinia.mundialis.de/latest/swagger.json#tag/STRDS-Management

metzm commented 3 years ago

Updating the mapset names in the tgis db is not easy: you have to check the current tgis db connection as defined in the <mapset>/VAR file, then use custom SQL commands to update the correct table and most probably some views need to be recreated.

neteler commented 3 years ago

Here a dirty hack to change mapset names in tgis/sqlite.db:

  1. dump SQLite DB, change mapset names on the fly and save to new dump file
  2. restore new dump file as a new tgis/sqlite.db:
/actinia_core/grassdb/geoharmonizer_aq/PERMANENT/tgis # sqlite3 sqlite.db .dump | sed 's+PERMANENT+mymapset+g' > dumpfile
/actinia_core/grassdb/geoharmonizer_aq/PERMANENT/tgis # cat dumpfile | sqlite3 my_database.sqlite
anikaweinmann commented 3 years ago

Parts are done in #233, but t.rast.extract does not work yet or creating a STRDS from rasters from a previous PC (t.create + t.register) does not work either. For this I have created a new bug ticket in GRASS GIS: https://github.com/OSGeo/grass/issues/1791

metzm commented 2 years ago

A first step for TGIS support has been done in GRASS with https://github.com/OSGeo/grass/pull/1924 to register maps from a different mapset in a stds in the current mapset.

metzm commented 2 years ago

TGIS has been enhanced in GRASS 8.0 to work with maps that are not in the current mapset.

Waiting for a new deployment of actinia for testing.

anikaweinmann commented 1 year ago

@metzm please test if it is done or waiting for https://github.com/OSGeo/grass/pull/2448