eurodatacube / eodash

Software behind the RACE dashboard by ESA and the European Commission (https://race.esa.int), the Green Transition Information Factory - GTIF (https://gtif.esa.int), as well as the Earth Observing Dashboard by NASA, ESA, and JAXA (https://eodashboard.org)
https://race.esa.int
MIT License
93 stars 42 forks source link

NEW Feature - Ad-hoc indicator generation based on user defined AOI #451

Closed aapopescu closed 3 years ago

aapopescu commented 4 years ago

The user can draw a bounding box to derive the indicator for that area on the fly.

This would work with the precomputed / wall-to-wall Truck detections, which are provided as GeoPackage point layers

But in principle also for the air quality and potentially the water quality layers.

Schpidi commented 4 years ago

Info for S5P data (N1) from SH: Need to use the Statistical API on the BYOD that has time configured.

Statistical API uses ID like OGC services.

Schpidi commented 4 years ago

@dzelge actions:

lubojr commented 4 years ago

@gobaRules @AlessandroScremin Just a quick question. I tried to access the SH FIS api on an example N3_CUSTOM_TRILATERAL layer (water quality BYOC), and I am receiving a statistics of the viewed RGBA composite, not the source data. Do I understand it right, that a different layer needs to be configured for FIS api to be used? (I tried setting STYLE=INDEX and STYLE=SENSOR), but the results are the same. example url used: <url>/ogc/fis/<instance_id>?STYLE=SENSOR&LAYER=N3_CUSTOM_TRILATERAL&CRS=CRS:84&TIME=2020-08-01/2020-08-25&RESOLUTION=100m&GEOMETRY=POLYGON((12.73%2045.4,13.3%2045.4,13.3%2045,12.73%2045,12.73%2045.4))

Schpidi commented 4 years ago

@dzelge do you have any updates on any of your 3 actions? thanks

gobaRules commented 4 years ago

@gobaRules @AlessandroScremin Just a quick question. I tried to access the SH FIS api on an example N3_CUSTOM_TRILATERAL layer (water quality BYOC), and I am receiving a statistics of the viewed RGBA composite, not the source data. Do I understand it right, that a different layer needs to be configured for FIS api to be used? (I tried setting STYLE=INDEX and STYLE=SENSOR), but the results are the same. example url used: <url>/ogc/fis/<instance_id>?STYLE=SENSOR&LAYER=N3_CUSTOM_TRILATERAL&CRS=CRS:84&TIME=2020-08-01/2020-08-25&RESOLUTION=100m&GEOMETRY=POLYGON((12.73%2045.4,13.3%2045.4,13.3%2045,12.73%2045,12.73%2045.4))

Hi @lubojr, yes, the approach is to create another configuration that returns the raw band values and then use that one for the FIS request.

lubojr commented 4 years ago

Hi, thank you for the clarification. All clear.

AlessandroScremin commented 4 years ago

@gobaRules @gmilcinski I think we need support to create this new layer not much information on sentinel hub about it...Or at least I was not able to find them....so We try ourself to generate this custom script to use raw data...is it fine or there are other ways to do it isn a more reliable way?

//VERSION=3

function setup() { return { input: ["tropno2","weight", "dataMask"], output: { bands: 4, sampleType: "FLOAT32" } }; }

function evaluatePixel(sample) { var valt = sample.tropno2; var valw = sample.weight; // if (val>180) return [0,0,0,0]; // no data values return [valt,valt,valw,255];

}

gmilcinski commented 4 years ago

In general, this seems OK. Not sure, why you want to have "valt" output in two bands, but if this is what you need, that should be fine.

If you are not getting the result you are expecting, please let us know, what you would like to get, if possible, with examples, then also attach one sample URL request, so that we can debug, and we will help you create a custom script.

AlessandroScremin commented 4 years ago

@gmilcinski EOX need to access the raw data. I checked and the raw data are in the band tropono2, so I changed the script into the simpliest way: //VERSION=3

function setup() { return { input: ["tropno2"], output: { bands: 1, sampleType: "FLOAT32" } }; }

function evaluatePixel(sample) {

return [sample.tropno2];

}

SO should be enouhg in this way I presume!

gmilcinski commented 4 years ago

Agreed, this should work.

lubojr commented 4 years ago

@gobaRules @gmilcinski We have a question regarding the script. Currently for one band this script works, but nodata value was not set on the source cog inserted via byoc - due to a presumed limitation that nodata value must have been integer. So ingested cogs have values set as 9.9E36 for pixels, where this should be marked as nodata. Is there a way to modify this resulting script so it would ignore these "nodata" 9.9E36 values in FIS API response completely (without setting it to some arbitrary value, like 0 - which would skew the resulting dashboard chart)?

gmilcinski commented 4 years ago

No, unfortunately not. FIS will take into account "no data" values in the raw imagery.

Schpidi commented 3 years ago

NO2 drawing is tracked in #589. Closing this as it is done for the trucks.