Module for doing checks of visible band and reporting and saturation. Note that this works off the original radiance file, not the TOA reflectance.
- fmask.saturationcheck.makeSaturationMask(fmaskConfig, radiancefile, outMask)¶
Checks the radianceFile and creates a mask with 1’s where there is saturation in one of more visible bands. 0 otherwise.
The fmaskConfig parameter should be an instance of
fmask.config.FmaskConfig. This is used to determine which bands are visible.
This mask is advisible since the whiteness test Eqn 2. and Equation 6 are affected by saturated pixels and may determine a pixel is not cloud when it is.
The format of outMask will be the current RIOS default format.
It is assumed that the input radianceFile has values in the range 0-255 and saturated pixels are set to 255.
- fmask.saturationcheck.riosSaturationMask(info, inputs, outputs, otherargs)¶
Called from RIOS. Does the actual saturation test. Currently assumes that only 8-bit radiance inputs can be saturated, but if this turns out not to be true, we can come back to this.