Custom ReadFilter to ignore malformed reads ?
Hi GATK team,
it's not a problem with gatk (currently 4.1.5.0) but with a bam processed with bwa but containing a few reads with a cigar string starting with a Deletion.
<pre>
org.broadinstitute.hellbender.tools.walkers.haplotypecaller.HaplotypeCaller done. Elapsed time: 2.56 minute
s.
Runtime.totalMemory()=176910336
***********************************************************************
A USER ERROR has occurred: Read V1:1:HN23NDSXX:4:1405:32931:18380 chr1:5374345-5374396 is malformed: read ends with deletion. Cigar: 65H48M3
8I4D. Although the SAM spec technically permits such reads, this is often indicative of malformed files.
***********************************************************************
org.broadinstitute.hellbender.exceptions.UserException$MalformedRead: Read V1:1:HN23NDSXX:4:1405:32931:18380 chr1:5374345-5374396 is malform
ed: read ends with deletion. Cigar: 65H48M38I4D. Although the SAM spec technically permits such reads, this is often indicative of malformed
files.
at org.broadinstitute.hellbender.utils.locusiterator.AlignmentStateMachine.stepForwardOnGenome(AlignmentStateMachine.java:242)
at org.broadinstitute.hellbender.utils.locusiterator.PerSampleReadStateManager.updateReadStates(PerSampleReadStateManager.java:188)
at org.broadinstitute.hellbender.utils.locusiterator.ReadStateManager.updateReadStates(ReadStateManager.java:118)
at org.broadinstitute.hellbender.utils.locusiterator.LocusIteratorByState.lazyLoadNextAlignmentContext(LocusIteratorByState.java:318
)
at org.broadinstitute.hellbender.utils.locusiterator.LocusIteratorByState.hasNext(LocusIteratorByState.java:225)
at org.broadinstitute.hellbender.tools.walkers.haplotypecaller.AssemblyBasedCallerUtils.getPileupsOverReference(AssemblyBasedCallerU
tils.java:443)
at org.broadinstitute.hellbender.tools.walkers.haplotypecaller.ReferenceConfidenceModel.calculateRefConfidence(ReferenceConfidenceMo
del.java:195)
at org.broadinstitute.hellbender.tools.walkers.haplotypecaller.HaplotypeCallerEngine.callRegion(HaplotypeCallerEngine.java:645)
at org.broadinstitute.hellbender.tools.walkers.haplotypecaller.HaplotypeCaller.apply(HaplotypeCaller.java:212)
at org.broadinstitute.hellbender.engine.AssemblyRegionWalker.processReadShard(AssemblyRegionWalker.java:200)
</pre>
My qestion is:
1) is it worth wrtiing a custom ReadFilter https://gatk.broadinstitute.org/hc/en-us/articles/360035532092-Read-filters ? I mean is the filter evaluated before or after the stepForwardOnGenome method above ?
2) If I write this custom IgnoreMalformedCIgarReadFilter what is the best way to include it in the classpath of gatk ,
Thank you for you help ?
-
oh, I see this https://github.com/broadinstitute/gatk/pull/6498 and https://gatk.broadinstitute.org/hc/en-us/community/posts/360057963511-HaplotypeCaller-error-Read-is-malformed-read-starts-with-deletion?input_string=Custom%20ReadFilter%20to%20ignore%20malformed%20reads%20%20%3F . May be it 's the same bug. Sorry if it's a duplicate.
-
Hi Yokofakun
Yes this is the same error. This is a known bug and should be resolved in the next release. In the meantime, here is a pre-release build in a public google bucket: gs://broad-dsde-methods-davidben/gatk-builds/gatk-4.1.5.1-pre-release.jar
Please sign in to leave a comment.
2 comments