From 47351d78984e0efa1dff914c81afde618dc96ddf Mon Sep 17 00:00:00 2001 From: Luca Delucchi Date: Mon, 20 Nov 2023 09:57:40 +0100 Subject: [PATCH 1/3] added singualrity recipes file --- sadasadam.def | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 sadasadam.def diff --git a/sadasadam.def b/sadasadam.def new file mode 100644 index 0000000..9496b1f --- /dev/null +++ b/sadasadam.def @@ -0,0 +1,20 @@ +Bootstrap: docker +From: davidfrantz/force + +%help + Singularity container to install FORGE, GDAL and sadasadam + +%labels + Maintainer Luca Delucchi + +%files + * /sadasadam/ + +%post + apt install ipython3 + # install SADASADAM + cd /sadasadam/ + pip install . + +%runscript + sadasadam --help \ No newline at end of file From 4a97eb719ffe7ade42592192f7ff9270261131c1 Mon Sep 17 00:00:00 2001 From: Luca Delucchi Date: Tue, 14 Nov 2023 14:40:32 +0100 Subject: [PATCH 2/3] small improvements in the README file --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 9136064..0f5d381 100644 --- a/README.md +++ b/README.md @@ -67,14 +67,14 @@ The steps above will automatically install the Python library [eodag](https://eo Before running SADASADAM, eodag needs to be configured (see [eodag documentation](https://eodag.readthedocs.io/en/stable/getting_started_guide/configure.html)). The eodag config file needs to be filled with credentials for satellite data providers. SADASADAM calls eodag to download only Sentinel-2 and Landsat-8/9 Level 1C data. Therefore, providing credentials to the `cop_dataspace` and `usgs` sections of the eodag config file -is recommended. In order to make the downloaded data accessible to FORCE, the download path `outputs_prefix` of the eodag config file -needs to be defined in the SADASADAM config file parameter `download_dir` as well (see below). It is recommended to define `extract: False` in the -eodag config file as SADASADAM automatically extracts the downloaded data according to the input requirements of FORCE. +is recommended. In order to make the downloaded data accessible to FORCE, +**the download path `outputs_prefix` of the eodag config file needs to be defined in the SADASADAM config file parameter `download_dir` as well** +(see below). It is recommended to define `extract: False` in the eodag config file as SADASADAM automatically extracts the downloaded data according to the input requirements of FORCE. A priority of providers can be defined in the eodag config file. We noticed the unexpected behaviour that download of Sentinel-2 -from `cop_dataspace` fails, if both `cop_dataspace` and `usgs` have the same priority. A functioning workaround seems to be to -set the priority of `cop_dataspace` to 2, and that of `usgs` to 1 - this way both Sentinel-2 and Landsat download worked in our -tests. +from `cop_dataspace` fails (error related to `peps` provider credentials), if both `cop_dataspace` and `usgs` have the same priority. +A functioning workaround seems to be to **set the priority of `cop_dataspace` to 2, and that of `usgs` to 1** - this way both Sentinel-2 and +Landsat download worked in our tests. # Usage @@ -182,7 +182,7 @@ clear_download: True # Will clear the content of the download directory . + # and postprocessing, assuming there is satellite data in . ``` ### Running SADASADAM From 0a421e3dd4cbd05de9df78e3cb4d4a89157a49a4 Mon Sep 17 00:00:00 2001 From: Luca Delucchi Date: Wed, 22 Nov 2023 10:52:04 +0100 Subject: [PATCH 3/3] added how to use SADASADAM with Singularity --- README.md | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/README.md b/README.md index 0f5d381..7639b26 100644 --- a/README.md +++ b/README.md @@ -195,3 +195,25 @@ sadasadam --config /path/to/sadasadam_conf_file.yaml Note: This will start the entire process (data download, FORCE processing, postprocessing) and may take a lot of time depending on data filtering and parallelization options defined in the config file. + +#### Using SADASADAM with Singularity + +Singularity is a free and open source container platform released with BSD license. + +To run SADASADAM with Singularity you need first to create the container using the `sadasadam.def` receipt file. To build the container image you need to be root. + +```commandline +sudo singularity build sadasadam.simg sadasadam.def +``` + +At this point it is possible to run SADASADAM into the created container. + +```commandline +singularity exec sadasadam.simg sadasadam --config config.yaml +``` + +If you need to pass the EODAG configuration file you can use the `EODAG_CFG_FILE` environmental variable as written in [EODAG documentation](https://eodag.readthedocs.io/en/stable/getting_started_guide/configure.html#yaml-user-configuration-file) + +```commandline +singularity exec --env EODAG_CFG_FILE=/PATH/TO/eodag.yml sadasadam.simg sadasadam --config config.yaml +```