gauss#

geetools.ee_image.ImageAccessor.gauss(band='')#

Apply a gaussian filter to the image.

We apply the following function to the image:

\[\exp\left(\frac{(\text{val}-\text{mean})^2}{-2 \cdot (\text{std}^2)}\right)\]

where \(\text{val}\) is the value of the pixel, \(\text{mean}\) is the mean of the image, \(\text{std}\) is the standard deviation of the image.

See the Gaussian filter Wikipedia page for more information.

Parameters:

band (str | ee.String) – The band to apply the gaussian filter to. If empty, the first one is selected.

Returns:

The image with the gaussian filter applied. A single band image with the gaussian filter applied.

Return type:

ee.Image

Examples

import ee, geetools

ee.Initialize()

image = ee.ImageCollection("COPERNICUS/S2_SR_HARMONIZED").first()
image = image.geetools.gauss()
print(image.bandNames().getInfo())