def getSVTYPE(chr1, chr2, extend1, extend2):
    """Get SVTYPE from extend right"""
    if chr1 != chr2:
        return 'TRA'
    eventmap = {(True): {(True): 'INV', (False): 'DUP'}, (False): {(True):
        'DEL', (False): 'INV'}}
    return eventmap[extend1][extend2]
