def getLengthRegion(rec):
    """
    :param rec:  pysam vcf record
    :return: length of the region of interest; pos2-pos1;
    """
    if rec.info['SVTYPE'] == "TRA" or ("TRA" in rec.info.keys() and rec.info['TRA']):
        return -1
    return abs(rec.info['ENDPOSSV']-rec.pos)