cannot specify instrument mode
This is a great API, but for for Sentinel-1 GRD, i only want to use imaging mode IW, but cannnot be specified here:(
Hi,
can you be a bit more specific? For example: what openEO backend (URL) are you using? I'm also not sure this is an issue specifically for the openEO Python client, but more a back-end specific question. E.g. if you are using the openEO backend from the Copernicus Data Space Ecosystem, I would recommend to raise your question at the user forum https://forum.dataspace.copernicus.eu/c/openeo/28
Hi,
I am using openeo.dataspace.copernicus.eu. I just realized that actually the imaging mode for Sentinel-1 over the study areas is only IW, so i guess this is no longer the problem. However, still i wish load_collection module can also specify the orbital pass (ascending/descending) and orbit number.
In the metadata, the imaging mode and orbital pass are exist, but i could not use it in load_collection module for filtering the image i am looking for. Or also maybe I did not know how to specify such information....
I hope this answers and thanks for the link!
note that load_collection supports filtering on particular properties: see https://open-eo.github.io/openeo-python-client/data_access.html#filter-on-collection-properties
@Pratichhya @VincentVerelst @VictorVerhaert dou you have by any chance an example (community notebook) of using this for filtering on IW mode?
We don't have an example for instrument mode filtering, however the simple example of filtering by properties is: https://github.com/eu-cdse/notebook-samples/blob/main/openeo/Radar_ARD.ipynb
So basically, for filtering based on instrument mode, the following example should work:
s1 = conn.load_collection( "SENTINEL1_GRD",
spatial_extent=spatial_extent,
bands=["VV", "VH"],
temporal_extent=["2021-01-01", "2021-01-08"],
properties={"sat:instrumentmode": lambda od: od == "IW"},
)
since python client 0.26, it looks nicer, I guess, to use this pattern (avoiding the lambda), as mentioned at https://open-eo.github.io/openeo-python-client/data_access.html#filter-on-collection-properties:
import openeo
s1 = conn.load_collection( "SENTINEL1_GRD",
...,
properties=[
openeo.collection_property("sat:instrumentmode") == "IW",
],
)
I think we should promote that in example notebooks @Pratichhya
@soxofaan @Pratichhya
Thank you very much for answering the question, is it indeed helpful. I tried the code and it works well. I should have explored more of course. One last question, how do i know the key let say, for example for instrument mode it is "sat:instrumentmode", orbit state it is "sat:orbit_state", and relative orbit number is "relativeOrbitNumber"? Well now i know, but just in case i will need more properties, i know which document I can then look up to...
One last question, how do i know the key let say, for example for instrument mode it is "sat:instrumentmode", orbit state it is "sat:orbit_state", and relative orbit number is "relativeOrbitNumber"? Well now i know, but just in case i will need more properties, i know which document I can then look up to...
There is indeed still a usability gap here.
FYI, this ticket is to improve this in the python client:
- https://github.com/Open-EO/openeo-python-client/issues/483
However, this also need support on the backend-side, which is not there yet (e.g. see https://github.com/Open-EO/openeo-geopyspark-driver/issues/536)
Well now i know, but just in case i will need more properties, i know which document I can then look up to...
Unfortunately, at the moment, I'm afraid we don't have some king of listing/documentation on this as far as I know. Or do we @Pratichhya ? If you have a concrete question, the only solution currently to reach out for support, e.g. at https://forum.dataspace.copernicus.eu/c/openeo/28
No, unfortunately, we don't have that documented anywhere yet.