raster_tools.Raster.set_null#
- Raster.set_null(mask_raster)[source]#
Update the raster’s null pixels using the provided mask
- Parameters
mask_raster (str, Raster) – Raster or path to a raster that is used to update the masked out pixels. This raster updates the mask. It does not replace the mask. Pixels that were already marked as null stay null and pixels that are marked as null in mask_raster become marked as null in the resulting raster. This is a logical “OR” operation. mask_raster must have data type of boolean, int8, or uint8. mask_raster must have either 1 band or the same number of bands as the raster it is being applied to. A single band mask_raster is broadcast across all bands of the raster being modified.
- Returns
The resulting raster with updated mask.
- Return type