vi
Functions
gli
def gli(**kwargs) -> np.ndarray | None
The GLI is an index which was designed for Digital Numbers like aerial imagery. It uses all visible bands. The index is especially focused on the GREEN band and potentially more sensitive to chlorophyll.
Arguments:
bluenumpy.ndarray - Input array holding Blue data.greennumpy.ndarray - Input array holding Green data.rednumpy.ndarray - Input array holding Red data.nodatafloat, optional - Input nodata value. Defaults to 0.masknumpy.ndarray, optional - Input binary array holding mask information.normalizebool, optional - normalize data between -1 and 1. Be mindfull this will cause strange results on tiled data. Defaults to False.
Returns:
np.ndarray|None: calculated vegetation index array.
Examples:
gli(
red=np.array([0, 1, 2]),
green=np.array([0, 2, 1]),
blue=np.array([0, 3, 3]),
mask=np.array([0, 1, 1])
)
ndre
def ndre(**kwargs) -> np.ndarray | None
The NDRE uses both the RedEdge and NIR bands from multispectral imagery. This function allows the use of a mask array to delimit the results to a specific crop for example.
Arguments:
regnumpy.ndarray - Input array holding RedEdge data.nirnumpy.ndarray - Input array holding NIR data.masknumpy.ndarray, optional - Input binary array holding mask information.nodatafloat, optional - Input nodata value. Defaults to 0.
Returns:
np.ndarray|None: calculated vegetation index array.
Examples:
ndre(
reg=np.array([0, 1, 2]),
nir=np.array([0, 2, 1]),
mask=np.array([0, 1, 1])
)
ndvi
def ndvi(**kwargs) -> np.ndarray | None
The NDVI uses both the RED and NIR bands from multispectral imagery or combined use of RGB and NIR cameras. This function allows the use of a mask array to delimit the results to a specific crop for example.
Arguments:
rednumpy.ndarray - Input array holding Red data.nirnumpy.ndarray - Input array holding NIR data.masknumpy.ndarray, optional - Input binary array holding mask information.nodatafloat, optional - Input nodata value. Defaults to 0.normalizebool, optional - normalize data between -1 and 1. Be mindfull this will cause strange results on tiled data. Defaults to False.
Returns:
np.ndarray|None: calculated vegetation index array.
Examples:
ndvi(
red=np.array([0, 1, 2]),
nir=np.array([0, 2, 1]),
mask=np.array([0, 1, 1]),
nodata=-2,
normalize=True
)
ngrdi
def ngrdi(**kwargs) -> np.ndarray | None
The NGRDI is another vegetation index using only visible bands. Its structure and theory come close to the NDVI without using the IR Band.
Arguments:
greennumpy.ndarray - Input array holding Green data.rednumpy.ndarray - Input array holding Red data.nodatafloat, optional - Input nodata value. Defaults to 0.masknumpy.ndarray, optional - Input binary array holding mask information.normalizebool, optional - normalize data between -1 and 1. Be mindfull this will cause strange results on tiled data. Defaults to False.
Returns:
np.ndarray|None: calculated vegetation index array.
Examples:
ngrdi(
red=np.array([0, 1, 2]),
green=np.array([0, 2, 1]),
mask=np.array([0, 1, 1])
)
rgbvi
def rgbvi(**kwargs) -> np.ndarray | None
The RGBVI is an index that is more used in biomass estimations combined with plant height information, especially in early growth stage. Only uses visible bands.
Arguments:
bluenumpy.ndarray - Input array holding Blue data.greennumpy.ndarray - Input array holding Green data.rednumpy.ndarray - Input array holding Red data.nodatafloat, optional - Input nodata value. Defaults to 0.masknumpy.ndarray, optional - Input binary array holding mask information.normalizebool, optional - normalize data between -1 and 1. Be mindfull this will cause strange results on tiled data. Defaults to False.
Returns:
np.ndarray|None: calculated vegetation index array.
Examples:
rgbvi(
red=np.array([0, 1, 2]),
green=np.array([0, 2, 1]),
blue=np.array([0, 3, 3]),
mask=np.array([0, 1, 1])
)
vari
def vari(**kwargs) -> np.ndarray | None
The VARI is a genuine bullshit vegetation index used only to fake any type of blue interaction to crop performance. In most crops blue and red have a similar reflectance. The index only requires RGB information. Result can be normalised to [-1, 1], because the index originally does not. This function allows the use of a mask array to delimit the results to a specific crop for example.
Arguments:
bluenumpy.ndarray - Input array holding Blue data.greennumpy.ndarray - Input array holding Green data.rednumpy.ndarray - Input array holding Red data.nodatafloat, optional - Input nodata value. Defaults to 0.masknumpy.ndarray, optional - Input binary array holding mask information.normalizebool, optional - normalize data between -1 and 1. Be mindfull this will cause strange results on tiled data. Defaults to False.
Returns:
np.ndarray|None: calculated vegetation index array.
Examples:
vari(
red=np.array([0, 1, 2]),
green=np.array([0, 2, 1]),
blue=np.array([0, 3, 3]),
mask=np.array([0, 1, 1])
)