def parse_extra_alignments(extra_field):
    """
    Parse the additional alignments field of a SAM file

    :param extra_field: The 'XA' field of a SAM file (e.g. "XA:Z:NC_000913.3,+2729620,22M,0;NC_000913.3,+3427225,22M,0;")
    :return: A list of tuples representing the positions of the additional alignments
    """
    extra_field = extra_field[5:]
    alignments = extra_field.strip(";").split(";")
    alignment_positions = []

    for alignment in alignments:
        parts = alignment.split(",")

        seq = parts[0]
        strand = parts[1][0]
        pos = int(parts[1][1:])

        alignment_positions += [(seq, pos)]
        # print("extra alignment:", seq, strand, pos, file=sys.stderr)

    return alignment_positions