def lab2ext(lab, lL0):
    """ label to extent

    Parameters
    ----------

    lab : string
        'i0-0' to 'i255-255'
    lL0 : tuple
        (lon0,lat0)

    Returns
    -------

    ext : extent
        (lonmin,lonmax,latmin,Latmax)

    """
    lab=lab.replace('i','')
    ilon = int(lab.split('-')[0])
    ilat = int(lab.split('-')[1])
    lonmin = lL0[0] + ilon/256
    lonmax = lL0[0] + (ilon+1)/256
    latmin = lL0[1] + ilat/256
    latmax = lL0[1] + (ilat+1)/256

    ext = (lonmin, lonmax, latmin, latmax)
    return ext