[gdal-dev] Band names when raster stacking
volkan yazici
volkanyazici at live.com
Mon Mar 28 07:08:49 PDT 2022
Hi,
I use this code for raster stacking:
outvrt = ('result/raster_stack_vrt.tif')
outtif = ('result/raster_stack.tif')
tifs = glob.glob('data/*.tif')
outds = gdal.BuildVRT(outvrt, tifs, separate = True)
outds = gdal.Translate(outtif, outds)
Band names are automatically generated as band_1, band_2.... I want the band names to be the same as the tif names. I found the bandList argument in gdal.BuildVRTOptions but that didn't produce the result I wanted either. How can I make band names automatically generated from the names of tif files?
----
Volkan.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20220328/8f0002dc/attachment.html>
More information about the gdal-dev
mailing list