Open-EO / openeo-processes

Interoperable processes for openEO's big Earth observation cloud processing.
https://processes.openeo.org
Apache License 2.0
48 stars 17 forks source link

`load_stac` scale and offset clarifications #512

Open clausmichele opened 5 months ago

clausmichele commented 5 months ago
  1. I moved the json spec out of the proposals folder, since now the process is available on many different back-ends CDSE, VITO, openEO Platform, EODC, Eurac Research.
  2. I tried to clarify the behavior of the process in case of Items/Assets with associated scale and offset parameters, which from this discussion we aggreed shouldn't be applied by default: https://github.com/Open-EO/openeo-processes/issues/503
clausmichele commented 5 months ago

@m-mohr what should I add to make the load_stac tests passing? I'm not sure to understand. This is also the result of a local tests run:

npm test

> @openeo/processes@2.0.0 test /home/mclaus@eurac.edu/openeo-processes/tests
> openeo-processes-lint testConfig.json

/home/mclaus@eurac.edu/openeo-processes/tests/node_modules/@jest/core/build/SearchSource.js:137
  _context;
          ^

SyntaxError: Unexpected token ;
    at Module._compile (internal/modules/cjs/loader.js:723:23)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
    at Module.load (internal/modules/cjs/loader.js:653:32)
    at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
    at Function.Module._load (internal/modules/cjs/loader.js:585:3)
    at Module.require (internal/modules/cjs/loader.js:692:17)
    at require (internal/modules/cjs/helpers.js:25:18)
    at Object.<anonymous> (/home/mclaus@eurac.edu/openeo-processes/tests/node_modules/@jest/core/build/index.js:30:44)
    at Module._compile (internal/modules/cjs/loader.js:778:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
npm ERR! Test failed.  See above for more details.
m-mohr commented 3 months ago

From the dev telco:

Applies to both load_collection and load_stac. We should add for both processes something like:

scale and offset need to be applied manually if present in metadata.

Not sure whether we should add:

If scale and offset are not present in metadata, no scale and offset need to be applied.

soxofaan commented 3 months ago

We should add for both processes something like:

scale and offset need to be applied manually if present in metadata.

Instead of "manually" I would express this in terms of "client side" or "explicitly in the process graph", so that openEO clients still can provide an automatic rescaling feature in some way.

soxofaan commented 3 months ago

Not sure whether we should add:

If scale and offset are not present in metadata, no scale and offset need to be applied.

I agree, I would leave this out. There might be reasons that some kind of scaling is necessary, but it can not be expressed in structured metadata (e.g. because the scaling factors change at a certain date, or the scaling is non-linear)