def gemi(red, nir):
    """Global Environment Monitoring Index boosted with Numba

    See:
        https://www.indexdatabase.de/db/i-single.php?id=25
    """

    red2 = red ** 2
    nir2 = nir ** 2
    
    eta = (2 * (nir2 - red2) + (1.5 * nir) + (0.5 * red)) / (nir + red + 0.5)

    return eta * (1 - 0.25*eta) - ((red - 0.125) / (1 - red))