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

Roles best practice #989

Merged
merged 23 commits into from
Feb 26, 2021
Merged

Roles best practice #989

merged 23 commits into from
Feb 26, 2021

Conversation

cholmes
Copy link
Contributor

@cholmes cholmes commented Feb 12, 2021

Related Issue(s): #966

Proposed Changes:

  1. Added best practice section on asset roles
  2. Made a list of common roles in best practice, borrowing many from card4l
  3. Moved visual and overview roles out to be in the best practice, as they aren't actually used that much today.

PR Checklist:

  • This PR is made against the dev branch (all proposed changes except releases should be against dev, not master).
  • This PR has no breaking changes.
  • I have added my changes to the CHANGELOG

@cholmes
Copy link
Contributor Author

cholmes commented Feb 12, 2021

Still some more to do here, like adding a bit more on the common roles and when / how to use them. But I think it's mostly done, any review is appreciated. As well as other 'role' ideas, I think a long list makes sense.

best-practices.md Outdated Show resolved Hide resolved
best-practices.md Outdated Show resolved Hide resolved
best-practices.md Outdated Show resolved Hide resolved
In addition to the thumbnail, data and overview [roles listed](item-spec/item-spec.md#asset-role-types) in the Item spec, there
are a number of roles that are emerging in practice, but don't have enough widespread use to justify standardizing them. So if
you want to re-use other roles then try to find them on the list below, and also feel free to suggest more to include here.

Copy link
Collaborator

Choose a reason for hiding this comment

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

Maybe also mention their use in Extensions -- for example, we use (proprietarily) a role of labels on assets in Items using the Label Extension, and there's discussion of changing that spec to use this role instead of requiring the asset be named 'labels'

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Sounds good. Will add labels to the list, and mention extensions.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually I don't think I'll add this yet, since right now it's not actually specified in the label extension. When #1001 is complete we can add it (or it can add it to this list if we merge this one first).

best-practices.md Outdated Show resolved Hide resolved
best-practices.md Outdated Show resolved Hide resolved
best-practices.md Outdated Show resolved Hide resolved
* [Representing Vector Layers in STAC](#representing-vector-layers-in-stac)
* **[Asset Best Practices](#asset-practices)**
* [Common Use Cases of Additional Fields for Assets](#common-use-cases-of-additional-fields-for-assets)
* [Working with Media Types](#working-with-media-types)
Copy link
Collaborator

Choose a reason for hiding this comment

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

Also applies to links?!

Copy link
Contributor Author

Choose a reason for hiding this comment

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

It does, but that whole section is really focused on asset media types. I can rename the title to 'working with asset media types'. Or could move it, but not sure where - I'm mostly looking for the best way to 'group' things to help people navigate a bit. Links cuts across all of them...

best-practices.md Outdated Show resolved Hide resolved
Copy link
Collaborator

@emmanuelmathot emmanuelmathot left a comment

Choose a reason for hiding this comment

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

related to the SAR, I would the following specific roles:

amplitude (GRD)
magnitude (SLC)
coherence
phase
sigma0
gamma0
beta0
displacement

@matthewhanson
Copy link
Collaborator

I like most of the roles added in the new list, but rather than include some really specific and little used SAR roles, what about just including those with the SAR extension as recommended roles?

There might be other roles tied to specific extensions, but SAR always seems to be the main source of lots of extra complicating fields.
I'd like to see the SAR specific ones removed and added to the SAR extension along with @emmanuelmathot's suggestions.

@matthewhanson
Copy link
Collaborator

Mentioned in mtg the other day, but a common asset among scientific geospatial data are plots or other graphics. These might indicate a fit of a curve to generate the main derived products, QC summary info, or ancillary info about applied corrections.

Would graphic be a good name for this?

@m-mohr
Copy link
Collaborator

m-mohr commented Feb 16, 2021

related to the SAR, I would the following specific roles:

And that's why it's a bad idea to copy/past just from CARD4L: Some entries only make sense in combination with the CARD4L spec. What is meant with sigma-gamma was the sigma-gamma ratio and not a specific sigma or gamma asset.
Do we actually need roles for those files? Isn't it better to have a SAR field for the values above and then use data? How often are these really combined so that roles make sense?

@m-mohr
Copy link
Collaborator

m-mohr commented Feb 16, 2021

I like most of the roles added in the new list, but rather than include some really specific and little used SAR roles, what about just including those with the SAR extension as recommended roles?

But then I'm wondering why not add all the cloud related stuff also to the EO extension etc? cloud_cover is also in eo and thus listing the roles there makes more sense to me. In best practices just list the domain agnostic roles (there are not many of them).

@m-mohr
Copy link
Collaborator

m-mohr commented Feb 16, 2021

Would graphic be a good name for this?

Is this an asset or a link? I think in CARD4L we somehow imply to use a link with rel type related...

@emmanuelmathot
Copy link
Collaborator

Do we actually need roles for those files? Isn't it better to have a SAR field for the values above and then use data? How often are these really combined so that roles make sense?

Ok but then the rationale should also apply for optical data. For instance, reflectance should be part of the eo extension. if the roles field "are used to describe what each asset is used for.", then being exhaustive to be sure we share common terms to describe the same measurements is not useless.

cholmes and others added 2 commits February 16, 2021 06:41
Co-authored-by: Phil Varner <[email protected]>
Co-authored-by: Matthias Mohr <[email protected]>
@cholmes
Copy link
Contributor Author

cholmes commented Feb 16, 2021

I like most of the roles added in the new list, but rather than include some really specific and little used SAR roles, what about just including those with the SAR extension as recommended roles?

But then I'm wondering why not add all the cloud related stuff also to the EO extension etc?

Sure, that makes sense to me. I think my only small hesitation is that these are at the level of 'best practice', not 'standard', and in the extension feels a bit more standard. But I think we have talked about a 'best practices' section in extensions, so I can just use this to start those. Would want to link from the overall best practice to the eo and sar roles sections, but that seems reasonable.

@matthewhanson
Copy link
Collaborator

This makes sense to me too (to put most of these in EO/SAR extension).

So with that I would say keep the roles here as the most generic ones:
thumbnail
overview
date
graphic - supporting plot, illustration, or graph associated with the Item

Plus data and metadata which are in the item-spec but didn't make it here (I think anything in item-spec should be included here)

Maybe saturation ?
I can also include including general masks here: snow-ice, land-water, mask

For the others:

EO Extension
reflectance
temperature
cloud
cloud-shadow

View Extension
azimuth
sun-azimuth
sun-elevation
terrain-shadow
terrain-occlusion
terrain-illumination

SAR Extension
contributing-area
local-incidence-angle
noise-power
gamma-sigma
date-offset
backscatter
covmat
prd

@m-mohr
Copy link
Collaborator

m-mohr commented Feb 18, 2021

gamma-sigma

Please note that this has been renamed in CARD4L for clarity reasons to gamma-sigma-ratio

Saturation could also start in eo, I think.

I'm not overly happy with "mask", even in CARD4L. Maybe we should rename that to something else? Ideas for improvements?

@matthewhanson
Copy link
Collaborator

I agree mask is too generic, what does it represent in CARD4L, nodata?

nodata-mask would be good for the general Best Practices

@m-mohr
Copy link
Collaborator

m-mohr commented Feb 18, 2021

regarding mask:

It's from the SAR spec and includes

  • Valid data
  • Invalid data
  • No-data

Optionally:

  • Layover (included as invalid data in Threshold)
  • Radar shadow (included as invalid data in Threshold)
  • Ocean water, etc.

@matthewhanson
Copy link
Collaborator

Differentiating between Invalid and Nodata doesn't seem useful, IMHO, does CARD4L require a difference? Without it this would just be a nodata-mask

@emmanuelmathot
Copy link
Collaborator

Sorry for the late contribution. I added roles corresponding to the conventions used in SAR and covering previous roles. May be reviewed in the future.

@cholmes
Copy link
Contributor Author

cholmes commented Feb 23, 2021

@emmanuelmathot - thanks! I didn't realize you'd be working so late, and checked to see if you had accepted the invite, so thought you were done for the day - would have waited for your to come in.

I think your commit missed my table of contents update, and unfortunately right now the SAR table needs to be updated in two places (included it in the SAR extension directly, but wanted a good list in one place in best practices). If you are able to clean those up that'd be great, but I can also probably do it later today.

@cholmes
Copy link
Contributor Author

cholmes commented Feb 23, 2021

Oh great, I see you got in the SAR extension one as I was writing. thanks

@emmanuelmathot
Copy link
Collaborator

emmanuelmathot commented Feb 23, 2021

I merged your table of content change. didn't I? Sorry if I missed something.

@cholmes
Copy link
Contributor Author

cholmes commented Feb 23, 2021

@emmanuelmathot - you did, but I took it out due to #989 (comment) Hrmm... I thought I reverted it, due to #1006 But now I can't find my reverting commit, so maybe I just thought I did. I'll figure it out.

@cholmes cholmes added this to the 1.0.0-RC.1 milestone Feb 24, 2021
This was referenced Feb 24, 2021
item-spec/item-spec.md Outdated Show resolved Hide resolved
@matthewhanson
Copy link
Collaborator

I think @m-mohr and I were thinking the same thing, that the generic Roles table wouldn't include extension specific Roles, such as the SAR related ones.

But I don't have a really strong opinion here so I'm going to get this approved.

@cholmes
Copy link
Contributor Author

cholmes commented Feb 26, 2021

Ok, I think this is good to go. Final approval appreciated.

Copy link
Collaborator

@m-mohr m-mohr left a comment

Choose a reason for hiding this comment

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

Looks good, but still fearing that the lists of roles get out of sync.

@cholmes
Copy link
Contributor Author

cholmes commented Feb 26, 2021

I hear you, but I do think the value of being able to see all the potential roles in one place outweighs the downside if they get a little out of date.

@m-mohr
Copy link
Collaborator

m-mohr commented Feb 26, 2021

@cholmes It will likely not be all roles in the future as extension development will be in separate repo for many, releases will be separate, new extensions will occur and stac spec will release much less often so basically this will always be an incomplete list. People should actually not understand it as a complete list. Give it a month or two after the release and I think it will be outdated and incomplete. Just saying...

@cholmes cholmes merged commit 79874f6 into dev Feb 26, 2021
@cholmes cholmes deleted the roles-best-practice branch February 26, 2021 15:24
@m-mohr
Copy link
Collaborator

m-mohr commented Feb 26, 2021

I just saw the last commit. That's a good change!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Best practice chapter on 'roles' of assets
5 participants