<div dir="ltr"><div>The easiest way to assign custom band names to raster maps in a strds is to create a corresponding file for t.register.</div><div><br></div><div>Note that band names in a strds do not need to match band names assigned with i.bands. The whole concept of band references in GRASS is IMHO still experimental and unfortunately far away from the STAC eo bands extension.</div><div><br></div><div>Markus M<br></div><div><br></div></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Tue, Aug 24, 2021 at 11:09 AM Maris Nartiss <<a href="mailto:maris.gis@gmail.com">maris.gis@gmail.com</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">Band reference rules were totally relaxed 7 days a go:<br>
<a href="https://github.com/OSGeo/grass/commit/abe194dce78adf5f63885a6a09c452fc7ae4f735" rel="noreferrer" target="_blank">https://github.com/OSGeo/grass/commit/abe194dce78adf5f63885a6a09c452fc7ae4f735</a><br>
<br>
New relaxed rule changes haven't propagated to the documentation yet<br>
(PR's welcome).<br>
<br>
Band reference editing via r.support was added on 4th of July:<br>
<a href="https://github.com/OSGeo/grass/commit/ca1551206eaa0fc462f4849a06ebb035808470da" rel="noreferrer" target="_blank">https://github.com/OSGeo/grass/commit/ca1551206eaa0fc462f4849a06ebb035808470da</a><br>
<br>
Still – keep in mind – there are no changes in band metadata as<br>
managed by g.bands. Changes only deal with ability to have a band<br>
reference without extended metadata in json files. Thus limitation of<br>
not being able to define your own band reference is still in place,<br>
now only you can assign a band reference without having a definition<br>
(and thus any extended metadata apart from its name).<br>
<br>
Māris.<br>
<br>
2021-08-24 11:18 GMT+03:00, Stefan Blumentrath <<a href="mailto:Stefan.Blumentrath@nina.no" target="_blank">Stefan.Blumentrath@nina.no</a>>:<br>
> Thanks Maris for the reply.<br>
><br>
> I could not find that option in r.support.<br>
><br>
> i.band allows to add e.g. S2_12 as band reference, but nothing custom. And<br>
> the g.bands manual says that user-defined band references are not yet<br>
> supported.<br>
><br>
> Has that been added recently? Or would I have to edit the bands json file of<br>
> the system first?<br>
><br>
> My system is:<br>
> g.version -ger<br>
> version=<a href="http://8.0.dev" rel="noreferrer" target="_blank">8.0.dev</a><br>
> date=2021<br>
> revision=dd9d36830<br>
> build_date=2021-07-08<br>
> build_platform=x86_64-pc-linux-gnu<br>
> build_off_t_size=8<br>
> libgis_revision=d2a5e8e8f<br>
> libgis_date=2021-06-16T04:05:21+00:00<br>
> proj=7.0.0<br>
> gdal=3.0.4<br>
> geos=3.8.0<br>
> sqlite=3.22.0<br>
><br>
> Cheers<br>
> Stefan<br>
><br>
> -----Original Message-----<br>
> From: Maris Nartiss <<a href="mailto:maris.gis@gmail.com" target="_blank">maris.gis@gmail.com</a>><br>
> Sent: tirsdag 24. august 2021 09:03<br>
> To: Stefan Blumentrath <<a href="mailto:Stefan.Blumentrath@nina.no" target="_blank">Stefan.Blumentrath@nina.no</a>><br>
> Cc: Martin Landa <<a href="mailto:landa.martin@gmail.com" target="_blank">landa.martin@gmail.com</a>>; Markus Metz<br>
> <<a href="mailto:markus.metz.giswork@gmail.com" target="_blank">markus.metz.giswork@gmail.com</a>>; GRASS developers list<br>
> <<a href="mailto:grass-dev@lists.osgeo.org" target="_blank">grass-dev@lists.osgeo.org</a>><br>
> Subject: Re: [GRASS-dev] lib/gis/band_reference.c ?<br>
><br>
> GRASS supports arbitrary band reference names. Just make them unique enough<br>
> to not mix together apples with oranges by accident (e.g. "min"<br>
> is a bad idea, "min_t_c" is better; "NDVI" would work; "elevation" – bad,<br>
> "elevation_m" – better).<br>
> You can set band references after import with r.support module.<br>
><br>
> Have fun,<br>
> Māris.<br>
><br>
</blockquote></div>