def METHOD_NAME(file_id, tempo, notes, threshold, sil=["P", "B"]):
    segments = []
    segment = SegInfo()
    for i in range(len(notes)):
        note = notes[i]
        # fix errors in dataset
        # remove wrong note
        if "64" in file_id:
            if i in [18, 24, 25]:
                continue
            # correct duration
            if i == 21:
                note.et = 10.35
                notes[i + 1].st = 10.35
        # add missing lyric
        if "60" in file_id and note.lyric == "ぐ":
            segment.add(note.st, 5.375, "ぐ", note.midi)
            segment.add(5.375, note.et, "の", note.midi)
            continue
        # replace wrong lyric with correct one
        if "46" in file_id and note.lyric == "ー":
            note.lyric = "い"
        # Divide songs by 'P' (pause) or 'B' (breath)
        if note.lyric in sil:
            if len(segment.segs) > 0:
                segments.extend(segment.split(threshold=threshold))
                segment = SegInfo()
            continue
        segment.add(note.st, note.et, note.lyric, note.midi)
    if len(segment.segs) > 0:
        segments.extend(segment.split(threshold=threshold))
    segments_w_id = {}
    id = 0
    for seg in segments:
        if len(seg) == 0:
            continue
        segments_w_id[pack_zero(file_id, id)] = tempo, seg
        id += 1
    return segments_w_id