def label_iit_to_bio(label_iit, seq):
    """ use BIO tags
    :param label_iit: e.g., [[9, 11, 'sobj'], [11, 14, 'obj'], [18, 22, 'prop'], [22, 26, 'cmp'], [26, 29, 'Rprop']]
    :return:  e.g., ['O',...,'B-obj','I-obj',...]
    """
    seq_len = len(seq)
    label_bio = ['O'] * seq_len
    for t in label_iit:
        i, j = t[0], t[1]  # start/end index
        if j > seq_len:
            j = seq_len
            print(f'!Index Error (ignore): get {t} in len={seq_len} sentence "{seq}"')

        label_bio[i] = 'B-' + t[2]
        for k in range(i + 1, j):
            label_bio[k] = 'I-' + t[2]

    return label_bio