def refl_vgroupi(refl):
    """
        >>> refl_vgroupi([0, 0, 0, 1, 2, 2, 2])
        [[0, 1, 2], [3], [4, 5, 6]]
    """
    rslts = []
    prev_value = refl[0]
    prev_index = 0
    lngth = len(refl)
    for i in range(1, lngth):
        curr_value = refl[i]
        if curr_value == prev_value:
            pass
        else:
            slc = list(range(prev_index, i))
            rslts.append(slc)
            prev_value = curr_value
            prev_index = i
    slc = list(range(prev_index, lngth))
    rslts.append(slc)
    return rslts
