Skip to main content
added 11 characters in body
Source Link
Kadir Şahbaz
  • 78k
  • 57
  • 257
  • 404

The documentation https://rasterio.readthedocs.io/en/latest/api/rasterio.merge.html says:

"Input files are merged in their listed order using the reverse painter’s algorithm (default) or another method."

"Input files are merged in their listed order using the reverse painter’s algorithm (default) or another method."

And for the available methods predefined by rasterio:

"first: reverse painting

last: paint valid new on top of existing

min: pixel-wise min of existing and new

max: pixel-wise max of existing and new"

first: reverse painting
last: paint valid new on top of existing
min: pixel-wise min of existing and new
max: pixel-wise max of existing and new

You can also write your own function, for example for a median or average of the files.

For your use case of removing clouds, you will probably not get good results from the predefined functions, a min for example would leave you without white clouds but with their dark shadows.

The documentation https://rasterio.readthedocs.io/en/latest/api/rasterio.merge.html says:

"Input files are merged in their listed order using the reverse painter’s algorithm (default) or another method."

And for the available methods predefined by rasterio:

"first: reverse painting

last: paint valid new on top of existing

min: pixel-wise min of existing and new

max: pixel-wise max of existing and new"

You can also write your own function, for example for a median or average of the files.

For your use case of removing clouds, you will probably not get good results from the predefined functions, a min for example would leave you without white clouds but with their dark shadows.

The documentation https://rasterio.readthedocs.io/en/latest/api/rasterio.merge.html says:

"Input files are merged in their listed order using the reverse painter’s algorithm (default) or another method."

And for the available methods predefined by rasterio:

first: reverse painting
last: paint valid new on top of existing
min: pixel-wise min of existing and new
max: pixel-wise max of existing and new

You can also write your own function, for example for a median or average of the files.

For your use case of removing clouds, you will probably not get good results from the predefined functions, a min for example would leave you without white clouds but with their dark shadows.

Source Link
bugmenot123
  • 11.3k
  • 3
  • 38
  • 75

The documentation https://rasterio.readthedocs.io/en/latest/api/rasterio.merge.html says:

"Input files are merged in their listed order using the reverse painter’s algorithm (default) or another method."

And for the available methods predefined by rasterio:

"first: reverse painting

last: paint valid new on top of existing

min: pixel-wise min of existing and new

max: pixel-wise max of existing and new"

You can also write your own function, for example for a median or average of the files.

For your use case of removing clouds, you will probably not get good results from the predefined functions, a min for example would leave you without white clouds but with their dark shadows.