RabadanLab / arcasHLA

Fast and accurate in silico inference of HLA genotypes from RNA-seq
GNU General Public License v3.0
113 stars 49 forks source link

KeyError when running the command arcasHLA convert -r p-group #91

Closed HaiHuaLiu closed 1 year ago

HaiHuaLiu commented 2 years ago

Here is my workflow:

  1. arcasHLA extract paired_end_bam_file -o $sample -t 16 -v
  2. arcasHLA genotype -g A,B,C,DPB1,DQB1,DQA1,DRB1 $r1_read $r2_read -o $sample -t 8 -v
  3. arcasHLA merge -i genotype/ -o genotype/ --run output -v The first 3 steps were OK. After I finished the first 3 steps, used arcasHLA to convert HLA results to P-group format. However, it didn't work, it reported one error: Traceback (most recent call last): File "convert.py", line 196, in genotypes[subject][gene] = convert_allele(allele, resolution) File "convert.py", line 98, in convert_allele if allele in p_group[i]: KeyError: 3
beijish commented 1 year ago

Good evening, having the same issue... was a solution ever found to this, please? BW

SV

alienzj commented 1 year ago

@HaiHuaLiu @beijish Hi, all, I also meet the same issue. Then I fixed it by converting the int index to the str index. You might refer to PR #94. Hope it can help you both.

HaiHuaLiu commented 1 year ago

@alienzj Thanks, it does work.