

def get_chromosome_priority(chrom, chrom_dict={
    
}):
    '\n    Return the chromosome priority\n    \n    Arguments:\n        chrom (str): The cromosome name from the vcf\n        chrom_dict (dict): A map of chromosome names and theis priority\n    \n    Return:\n        priority (str): The priority for this chromosom\n    '
    priority = 0
    chrom = str(chrom).lstrip('chr')
    if chrom_dict:
        priority = chrom_dict.get(chrom, 0)
    else:
        try:
            if (int(chrom) < 23):
                priority = int(chrom)
        except ValueError:
            if (chrom == 'X'):
                priority = 23
            elif (chrom == 'Y'):
                priority = 24
            elif (chrom == 'MT'):
                priority = 25
            else:
                priority = 26
    return str(chrom)

dataset/ETHPy150Open moonso/genmod/genmod/utils/get_priority.py get_chromosome_priority/VarMisuse@142/266 `priority`->`chrom`