Skip to content

Geotiff Tags not fully compatible with GDAL #3496

Closed

Description

@jdries

Describe the bug

It seems not possible to write a band name to geotiff metadata that is compatible with GDAL.
Geotrellis writes this:

<GDALMetadata>
  <Item name="DESCRIPTION" sample="0">B02</Item>
</GDALMetadata>

While GDAL would like to also see a "role" attribute:

<GDALMetadata>
  <Item name="DESCRIPTION" sample="0" role="description">B02</Item>
</GDALMetadata>

In the Geotrellis code, it is very clear that the role attribute is not used:

<Item name={key} sample={i.toString}>{value}</Item>

Originally reported here:
Open-EO/openeo-geopyspark-driver#257

To Reproduce

Simply write a geotiff with tags, trying to set a DESCRIPTION on the bands.

Expected behavior

Geotrellis can generate metadata compliant with GDAL, as it already tries to do that.

Environment

Geotrellis 3.6.x

Activity

  1. pomadchin commented on Jan 25, 2023

    @pomadchin
    Member

    Hey @jdries thanks for reporting, definitely sounds like a bug / oversight to me.

  2. added a commit that references this issue on Mar 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions