Radioindice

class eolab.georastertools.Radioindice(indices: List[RadioindiceProcessing])[source]

Bases: Rastertool, Windowable

Raster tool that computes radiometric indices of a raster product.

If several indices are requested, the tool can generate one output image with one band per indice (merge=True), or it can generate several images, one image per indice (merge=False).

The computation can be realized on a subset of the input image (a Region Of Interest) defined by a vector file (e.g. shapefile, geojson).

The radiometric indice is an instance of eolab.georastertools.processing.RadioindiceProcessing which defines the list of channels it needs to compute the indice. The input raster product must be of a recognized raster type so that it is possible to match every channels required by the indice with an existing band in the raster product.

Attributes

Radioindice.bi

Brightness index (red, green channels)

Radioindice.bi2

Brightness index (nir, red, green channels)

Radioindice.evi

Enhanced vegetation index (red, nir, blue channels)

Radioindice.indices

List of radiometric indices to compute

Radioindice.ipvi

Infrared Percentage Vegetation Index (red, nir channels)

Radioindice.keep_vrt

Whether intermediate VRT images shall be kept

Radioindice.merge

If true, all indices are in the same output image (one band per indice).

Radioindice.mndwi

Modified Normalized Difference Water Index (green, mir channels)

Radioindice.msavi

Modified Soil Adjusted Vegetation Index (red, nir channels)

Radioindice.msavi2

Modified Soil Adjusted Vegetation Index (red, nir channels)

Radioindice.ndbi

Normalized Difference Built Up Index (nir, mir channels)

Radioindice.ndpi

Normalized Difference Pond Index (green, mir channels)

Radioindice.ndti

Normalized Difference Turbidity Index (green, red channels)

Radioindice.ndvi

Normalized Difference Vegetation Index (red, nir channels)

Radioindice.ndwi

Normalized Difference Water Index (mir, nir channels)

Radioindice.ndwi2

Normalized Difference Water Index (nir, green channels)

Radioindice.outputdir

Path of the output directory where are stored the results

Radioindice.pad_mode

//numpy.org/doc/stable/reference/generated/numpy.pad.html>`_ the image when the window is on the edge of the image The mode can be self defined or among [constant (default), edge, linear_ramp, maximum, mean, median, minimum, reflect, symmetric, wrap, empty].

Radioindice.pvi

Perpendicular Vegetation Index (red, nir channels)

Radioindice.ri

Redness index (red, green channels)

Radioindice.roi

Filename of the vector data defining the ROI

Radioindice.rvi

Ratio Vegetation Index (red, nir channels)

Radioindice.savi

Soil Adjusted Vegetation Index (red, nir channels)

Radioindice.tndvi

Transformed Normalized Difference Vegetation Index (red, nir channels)

Radioindice.tsavi

Transformed Soil Adjusted Vegetation Index (red, nir channels)

Radioindice.vrt_dir

Dir where to store intermediate VRT images

Radioindice.window_size

Size of the windows to split the image in small parts

Methods

Radioindice.__init__(indices)

Constructor

Radioindice.get_default_indices()

Get the list of predefined radiometric indices

Radioindice.postprocess_files(inputfiles, ...)

Run a postprocess when all input files have been processed.

Radioindice.process_file(inputfile)

Compute the indices for a single file

Radioindice.process_files(inputfiles)

Run the rastertool to a set of input files.

Radioindice.with_output([outputdir, merge])

Set up the output.

Radioindice.with_roi(roi)

Set up the region of interest

Radioindice.with_vrt_stored(keep_vrt)

Configure if the intermediate VRT images that are generated when handling the input files (which can be complex raster product composed of several band files) shall be stored to disk or not - for debug purpose for instance.

Radioindice.with_windows([window_size, pad_mode])

Configure the window generation for processing image