Open-EO / openeo-web-editor

An interactive and easy to use web-based editor for the OpenEO API.
https://editor.openeo.org
Apache License 2.0
12 stars 17 forks source link

eo:bands `scale` rounding issue #219

Closed soxofaan closed 2 years ago

soxofaan commented 2 years ago

(not sure where to report this, so feel free to move)

in Vito backend we have collection TERRASCOPE_S2_TOC_V2, which has "scale": 0.0001 for a couple of bands

"eo:bands": [
      {
        "aliases": [
          "TOC-B01_60M"
        ],
        "common_name": "coastal aerosol",
        "gsd": 60,
        "name": "B01",
        "offset": 0,
        "scale": 0.0001,
        "type": "int16",
        "unit": "1",
        "wavelength_nm": 442.7
      },

In the hub/editor/vuecomponents, this scale is rounded to 0:

Screenshot from 2021-11-03 12-08-38

m-mohr commented 2 years ago

The issue actually resides in stac-fields, which does round values by default. As scale and offset are not specified officially (they are in raster:bands though), I have no option to disable it.

m-mohr commented 2 years ago

Moved to https://github.com/stac-utils/stac-fields/issues/16

m-mohr commented 2 years ago

Fixed in v0.9.5 due to upgrades in stac-fields and openeo-vue-components:

image