I have a Sentinel 2 multidate image data set and I'm trying to resample all of them at 10m and then stack them to apply a cloud mask, in Python language. Being new to programming, I have a hard time getting started. By cons I have some ideas like: - recover the coordinates (x, y) of one of the 4 spectral bands at 10m (B2, B3, B4 or B8) and apply them on all the other bands of the multidate images. The fact is that the ultimate goal is to create an atlas, so I also asked the question of whether to create a stack for each image in a function, but it looks very complicated. ..
1 Answer
As you did not provide any code, it is hard to tell how far you are in the implementation. I assume, you already have all the libraries you need and that your data is in tif format. If so, I would recommend using gdal warp function to resample the tifs.
gdal.Warp('outputRaster.tif', 'inputRaster.tif', xRes=10, yRes=10)
there is no need to stack them for applying a cloud mask. you can just apply one after another.