first = np.hstack(([True], rlabels[:-1] != rlabels[1:]))