svtyper icon indicating copy to clipboard operation
svtyper copied to clipboard

KeyError: 'MATEID'

Open YiweiNiu opened this issue 6 years ago • 3 comments

Hi,

I'm running svtyper on the output of Delly2. Then I got these error messages:

Traceback (most recent call last):
  File "/home/work01/tools/SVTyper/svtyper/svtyper", line 1808, in <module>
    sys.exit(main())
  File "/home/work01/tools/SVTyper/svtyper/svtyper", line 1803, in main
    args.max_reads)
  File "/home/work01/tools/SVTyper/svtyper/svtyper", line 1480, in sv_genotype
    if var.info['MATEID'] in breakend_dict:
KeyError: 'MATEID'

Thanks!

YiweiNiu avatar Sep 21 '17 00:09 YiweiNiu

I'm getting a similar KeyError, for the CIPOS field:

.. svtyper/classic.py", line 262, in sv_genotype ciA = map(int, var.info['CIPOS'].split(',')) KeyError: 'CIPOS'

I assume that this is because my vcf has no CIPOS field -- it was generated with Sniffles, not Lumpy, as I'm trying to see if I can use svtyper to genotype variants from Illumina reads (bam file) given a vcf which was generated from long reads.

Are there certain fields which are required in the vcf such as MATEID (which is also not in my vcf) and CIPOS, and if so, is that documented somewhere?

Thanks!

RSherman15 avatar Apr 14 '18 00:04 RSherman15

You are correct in your assumptions, but there isn't a documented list.

Looking quickly through the code, it would appear that MATEID, END, CIPOS, CIEND and SVTYPE are all required.

Furthermore, the only supported variant types are BND, DEL, DUP or INV.

ernfrid avatar Apr 17 '18 17:04 ernfrid

Thanks!

RSherman15 avatar Apr 19 '18 09:04 RSherman15