ImageMath not saving metadata

Issue #1353 invalid
Agustin Lobo created an issue

Despite specifying metadata to be transferred, the output seems not to keep them:

setMetadata(result, metadata(enmap))

https://www.dropbox.com/s/whr1seyr3kvr2c3/metadata.jpeg?dl=0

Although the editor does report the metadata…

https://www.dropbox.com/s/cyipgegqhox35nb/metadata2.jpeg?dl=0

Version 3.10.0.20220401T124144.develop c7d679b

Comments (8)

  1. Agustin Lobo reporter

    Please note that in terms of the user processing chain this issue is blocking.

    (the reason to use image math was that the gain was not being applied to the spectra. Then we try to apply it through ImageMath and we lose all metadata…)

  2. Andreas Rabe

    Hi Agus,

    why do you think that the metadata is missing? Your second screenshot indicates that metedata was copied.

    Please also check what metadata is shown here:

  3. Andreas Rabe

    Note that GTiffs can store metadata inside the *.tif file itself.

    A GDAL PAM *.aux.xml file may not be created in all cases.

  4. Agustin Lobo reporter

    why do you think that the metadata is missing? Your second screenshot indicates that metedata was copied.

    Please also check what metadata is shown here:

    Raster Properties/GDAL Metadata reports no metadata (1st screenshot) while the editor reports metadata (2nd screenshot). The real problem is that critical metadata (band names, wavelength, bias) are not available for display (eg Color space explorer):

  5. Log in to comment