hall-lab / svtyper

Bayesian genotyper for structural variants
MIT License
126 stars 55 forks source link

Failed to build insert size histogram for paired-end reads. #115

Open tirohia opened 4 years ago

tirohia commented 4 years ago

Trying to run svtyper on a vcf produced by lumpy, using the docker container found via: docker pull halllab/svtyper:v0.7.1-3c5218a

$ docker run  -v "/blue/project/trios/data:/blue/project/trios/data" halllab/svtyper:v0.7.1-3c5218a svtyper -B /blue/project/trios/data/trio3F15.sorted.bam -l trio3F.diagnostic.json 

Error: failed to build insert size histogram for paired-end reads.                                                                                                                                                                            
Please ensure BAM file (/blue/project/trios/data/trio3F15.sorted.bam) has inward facing, paired-end reads

This looks the same as an error produced whilst attempting to diagnose another fault, detailed here: https://github.com/hall-lab/speedseq/issues/91

The response to that was SVTyper could not find any paired-end, inward facing reads in the bam and that it was an alignment issue. If I do samtools stats on the file in question though:

samtools stats data/trio3F15.sorted.bam > trio3F15.stats

then in amongst everything else I get: SN raw total sequences: 127748452
SN reads paired: 127748452 # paired-end technology bit set SN inward oriented pairs: 55933739

i.e this bam file contains only paired reads and ~80% of them are inward orientated. The initial command above runs fine if I omit this particular file, so it's something in the file that's causing it. I don't know what specifically to look at in the file to be able to identify the problem though.

The header of the sam file was requested in the other issue mentioned, so I've attached that in case it helps:

trio3F15.bam.header.txt

Thanks Ben.