I've been trying to use rasterio.merge.merge() but it seems I have a nodata
issue forbidding it (Rasterio.merge.merge() does not work): there is no value defined as nodata
for my rasters (they all have the same metadata).
I would like to change it to nan
in format float32.
How could I do this, on Python ?
The metadata of the raster is:
print('Raster 1: \n', raster1.profile)
Raster 1:
{'driver': 'GTiff', 'dtype': 'float32', 'nodata': None, 'width': 3532, 'height': 3537, 'count': 16, 'crs': CRS.from_epsg(32607), 'transform': Affine(30.0, 0.0, 484200.0,
0.0, -30.0, 6719670.0), 'blockxsize': 256, 'blockysize': 256, 'tiled': True, 'compress': 'lzw', 'interleave': 'pixel'}
rasterio.open(path, nodata=np.nan)