radiantearth / stac-spec

SpatioTemporal Asset Catalog specification - making geospatial assets openly searchable and crawlable
https://stacspec.org
Apache License 2.0
777 stars 178 forks source link

Add palette asset role #1181

Closed zakjan closed 1 year ago

zakjan commented 2 years ago

Related Issue(s): https://github.com/stac-extensions/raster/issues/17

Proposed Changes:

  1. Add palette asset role

PR Checklist:

zakjan commented 2 years ago

Searching for references about color palette files in other tools, it seems there is no common standard or MIME type. I'm not sure whether the palette asset role can recommend a particular format or a library to parse it, so I haven't included it yet. @cholmes What do you think?

The largest collection of color palettes cpt-city provides palettes in 11 different formats. There is a good formats reference as well. GDAL-compatible format (cpt or pg) seems safe to recommend. Some formats can be converted using cptutils or cptutils-online.

zakjan commented 2 years ago

Found download stats by format! So it's cpt the most used indeed.

m-mohr commented 1 year ago

Would this make more sense to be added to the raster or classification extension instead?

zakjan commented 1 year ago

Yeah, makes sense. Asset role palette or raster:palette?

m-mohr commented 1 year ago

palette, rel types are not prefixed.

m-mohr commented 1 year ago

@zakjan Do you still plan to open a PR for this in the raster and/or classification extensions?

zakjan commented 1 year ago

Hi @m-mohr, I'm sorry for inactivity, I'm totally swamped these days :( Have you seen any interest about this topic from anyone else?

m-mohr commented 1 year ago

@zakjan Unfortunately not so much, so take your time, I guess....

zakjan commented 1 year ago

I'm going to close this for now, thanks.

m-mohr commented 1 year ago

It's so funny how like 30mins after you closed this, someone asked me about it. I forwarded this link, so maybe someone will chime in soon.

zakjan commented 1 year ago

Haha :) Anyway, this is only about standardizing a STAC field if there is more interest about it. Anyone can still use it as a custom field.

Regarding the implementation, I've implemented https://github.com/weatherlayers/cpt2js for parsing the palette files.