Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

openeo grass driver #114

Merged
merged 2 commits into from
Sep 17, 2021
Merged

openeo grass driver #114

merged 2 commits into from
Sep 17, 2021

Conversation

metzm
Copy link
Collaborator

@metzm metzm commented Sep 17, 2021

use metadata from actinia instead of guessing

use metadata from actinia instead of guessing
Copy link
Collaborator

@mmacata mmacata left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I have two suggestions for improvements. But as this is already a huge improvement itself, it is not a blocker for me to be merged.
Thank you!

src/openeo_grass_gis_driver/collection_information.py Outdated Show resolved Hide resolved
for bandname in bandlist:
# not so nice, better use different name and common_name
# waiting for GRASS GIS
bands.append(EOBands(name=bandname, common_name=bandname))
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This assumes that the band names equal always common band names, right? How many common band names are there? Could we make a list of them and if bandname is contained in it, we set it also for common_name and if not, it is empty or unknown?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

In this context, we only get a list of band names from t.info. In TGIS, there is only a single field band_reference, thus we get only one band name per raster and use it as both name and common_name.
A list of common band names in the EO STAC extension is here: https://github.com/stac-extensions/eo/#common-band-names

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes - I meant that it can be the case that the user specifies a band_reference which is not a common band name but nevertheless it would appear in this field then. To prevent this, a check could be implemented to compare the field with all common band names and only set it then, otherwise leave it empty.

* get platform and instrument
@metzm metzm merged commit 6ba16fb into master Sep 17, 2021
@metzm metzm deleted the band_names branch September 17, 2021 13:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants