Attention:
The frontline support team will be slow on the forum because we are occupied with the GATK Workshop on March 21st and 22nd 2019. We will be back and more available to answer questions on the forum on March 25th 2019.

GenotypeGVCF - Code exception error

Trying to do variantcalling using GATKs new pipeline using HaplotypeCaller and GenotypeGVCF.

Made gVCFs using HC and now trying to do joint genotyping using GenotypeGVCF

java -Xmx5G -jar GenomeAnalysisTK.jar -T GenotypeGVCFs -R hs37d5.fa -V:VCF GVCF.list -L SureSelect_AllExon_V5_wo_chr.bed --dbsnp dbsnp_137.hg19.vcf -A QualByDepth -A HaplotypeScore -A MappingQualityRankSumTest -A ReadPosRankSumTest -A FisherStrand -A InbreedingCoeff -A Coverage -A AlleleBalance -A AlleleBalanceBySample -A BaseCounts -A BaseQualityRankSumTest -A ChromosomeCounts -A ClippingRankSumTest -A Coverage -A DepthPerAlleleBySample -A FisherStrand -A GCContent -A HaplotypeScore -A HardyWeinberg -A HomopolymerRun -A InbreedingCoeff -A LowMQ -A MappingQualityRankSumTest -A MappingQualityZero -A MappingQualityZeroBySample -A NBaseCount -A QualByDepth -A RMSMappingQuality -A SpanningDeletions -A TandemRepeatAnnotator -A VariantType -o JointGenotyped.vcf

Error

ERROR A GATK RUNTIME ERROR has occurred (version 3.0-0-g6bad1c6):
ERROR
ERROR This might be a bug. Please check the documentation guide to see if this is a known problem.
ERROR If not, please post the error message, with stack trace, to the GATK forum.
ERROR Visit our website and forum for extensive documentation and answers to
ERROR commonly asked questions http://www.broadinstitute.org/gatk
ERROR
ERROR MESSAGE: Code exception (see stack trace for error itself)

Not sure why this is happening.

Thanks,
Tinu

Tagged:

Best Answers

Answers

  • Geraldine_VdAuweraGeraldine_VdAuwera Cambridge, MAMember, Administrator, Broadie admin

    Hi Tinu, can you please post the stack trace? That's the detailed error message (before the error summary which you posted), and that is the part that is informative to us.

  • pdexheimerpdexheimer Member ✭✭✭✭

    This part of the command line worries me: -V:VCF GVCF.list. You shouldn't need to supply a type for VCF files in the first place, and I'm fairly certain that declaring a list to be a vcf will greatly confuse things

  • tinutinu Member

    Hi Geraldine.

    Please find the stack trace here...

    ERROR ------------------------------------------------------------------------------------------
    ERROR stack trace

    java.lang.NullPointerException
    at org.broadinstitute.sting.gatk.walkers.annotator.AlleleBalance.annotate(AlleleBalance.java:66)
    at org.broadinstitute.sting.gatk.walkers.annotator.VariantAnnotatorEngine.annotateContext(VariantAnnotatorEngine.java:192)
    at org.broadinstitute.sting.gatk.walkers.annotator.VariantAnnotatorEngine.annotateContext(VariantAnnotatorEngine.java:177)
    at org.broadinstitute.sting.gatk.walkers.variantutils.GenotypeGVCFs.regenotypeVC(GenotypeGVCFs.java:224)
    at org.broadinstitute.sting.gatk.walkers.variantutils.GenotypeGVCFs.map(GenotypeGVCFs.java:187)
    at org.broadinstitute.sting.gatk.walkers.variantutils.GenotypeGVCFs.map(GenotypeGVCFs.java:110)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano$TraverseLociMap.apply(TraverseLociNano.java:267)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano$TraverseLociMap.apply(TraverseLociNano.java:255)
    at org.broadinstitute.sting.utils.nanoScheduler.NanoScheduler.executeSingleThreaded(NanoScheduler.java:274)
    at org.broadinstitute.sting.utils.nanoScheduler.NanoScheduler.execute(NanoScheduler.java:245)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano.traverse(TraverseLociNano.java:144)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano.traverse(TraverseLociNano.java:92)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano.traverse(TraverseLociNano.java:48)
    at org.broadinstitute.sting.gatk.executive.LinearMicroScheduler.execute(LinearMicroScheduler.java:99)
    at org.broadinstitute.sting.gatk.GenomeAnalysisEngine.execute(GenomeAnalysisEngine.java:313)
    at org.broadinstitute.sting.gatk.CommandLineExecutable.execute(CommandLineExecutable.java:121)
    at org.broadinstitute.sting.commandline.CommandLineProgram.start(CommandLineProgram.java:248)
    at org.broadinstitute.sting.commandline.CommandLineProgram.start(CommandLineProgram.java:155)
    at org.broadinstitute.sting.gatk.CommandLineGATK.main(CommandLineGATK.java:107)

    ERROR ------------------------------------------------------------------------------------------
    ERROR A GATK RUNTIME ERROR has occurred (version 3.0-0-g6bad1c6):
    ERROR
    ERROR This might be a bug. Please check the documentation guide to see if this is a known problem.
    ERROR If not, please post the error message, with stack trace, to the GATK forum.
    ERROR Visit our website and forum for extensive documentation and answers to
    ERROR commonly asked questions http://www.broadinstitute.org/gatk
    ERROR
    ERROR MESSAGE: Code exception (see stack trace for error itself)
    ERROR ------------------------------------------------------------------------------------------
  • tinutinu Member
    edited April 2014

    @pdexheimer I removed -V:VCF GVCF.list and instead kept -V GVCF.list ran the same command and still getting the same error as above

  • tinutinu Member

    Even tried giving just one gVCF along with -V option. Still the same issue

    ERROR ------------------------------------------------------------------------------------------
    ERROR stack trace

    java.lang.NullPointerException
    at org.broadinstitute.sting.gatk.walkers.annotator.AlleleBalance.annotate(AlleleBalance.java:66)
    at org.broadinstitute.sting.gatk.walkers.annotator.VariantAnnotatorEngine.annotateContext(VariantAnnotatorEngine.java:192)
    at org.broadinstitute.sting.gatk.walkers.annotator.VariantAnnotatorEngine.annotateContext(VariantAnnotatorEngine.java:177)
    at org.broadinstitute.sting.gatk.walkers.variantutils.GenotypeGVCFs.regenotypeVC(GenotypeGVCFs.java:224)
    at org.broadinstitute.sting.gatk.walkers.variantutils.GenotypeGVCFs.map(GenotypeGVCFs.java:187)
    at org.broadinstitute.sting.gatk.walkers.variantutils.GenotypeGVCFs.map(GenotypeGVCFs.java:110)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano$TraverseLociMap.apply(TraverseLociNano.java:267)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano$TraverseLociMap.apply(TraverseLociNano.java:255)
    at org.broadinstitute.sting.utils.nanoScheduler.NanoScheduler.executeSingleThreaded(NanoScheduler.java:274)
    at org.broadinstitute.sting.utils.nanoScheduler.NanoScheduler.execute(NanoScheduler.java:245)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano.traverse(TraverseLociNano.java:144)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano.traverse(TraverseLociNano.java:92)
    at org.broadinstitute.sting.gatk.traversals.TraverseLociNano.traverse(TraverseLociNano.java:48)
    at org.broadinstitute.sting.gatk.executive.LinearMicroScheduler.execute(LinearMicroScheduler.java:99)
    at org.broadinstitute.sting.gatk.GenomeAnalysisEngine.execute(GenomeAnalysisEngine.java:313)
    at org.broadinstitute.sting.gatk.CommandLineExecutable.execute(CommandLineExecutable.java:121)
    at org.broadinstitute.sting.commandline.CommandLineProgram.start(CommandLineProgram.java:248)
    at org.broadinstitute.sting.commandline.CommandLineProgram.start(CommandLineProgram.java:155)
    at org.broadinstitute.sting.gatk.CommandLineGATK.main(CommandLineGATK.java:107)

    ERROR ------------------------------------------------------------------------------------------
    ERROR A GATK RUNTIME ERROR has occurred (version 3.0-0-g6bad1c6):
    ERROR
    ERROR This might be a bug. Please check the documentation guide to see if this is a known problem.
    ERROR If not, please post the error message, with stack trace, to the GATK forum.
    ERROR Visit our website and forum for extensive documentation and answers to
    ERROR commonly asked questions http://www.broadinstitute.org/gatk
    ERROR
    ERROR MESSAGE: Code exception (see stack trace for error itself)
    ERROR ------------------------------------------------------------------------------------------
  • tinutinu Member
    edited April 2014

    @Sheila Thank you. I removed the annotation and now it is running. I realize that few annotations work and few doesn't with GenotypeGVCFs. So may be once I have the VCF would run VariantAnnotator to get all annotations

  • tinutinu Member
    edited May 2014

    @Sheila I have been using GATK VariantAnnotator after GenotypeGVCF run inorder to get all annotations.

    When comparing the annotations of variants before and after VariantAnnotator run, I see that some of the annotation field values in the vcf changes after VariantAnnotator run as stated in the example below

    After JointGenotyping run using GenotypeGVCFs
    Y 22941490 . G A 10269.48 . AC=2;AF=0.022;AN=92;BaseQRankSum=-1.551e+00;ClippingRankSum=0.234;DP=8060;FS=1.935;InbreedingCoeff=0.7661;MLEAC=2;MLEAF=0.022;MQ=59.24;MQ0=0;MQRankSum=-2.050e-01;QD=34.00;ReadPosRankSum=0.985 .

    Ran the above VCF through VariantAnnotator
    Y 22941490 . G A 10269.48 . ABHom=0.999;AC=2;AF=0.022;AN=92;BaseCounts=248,0,8127,5;BaseQRankSum=-11.363;ClippingRankSum=0.234;DP=8381;Dels=0.00;FS=2.307;GC=45.54;HRun=0;HW=16.6;HaplotypeScore=4.2324;InbreedingCoeff=0.7661;LowMQ=0.0000,0.0000,8381;MLEAC=2;MLEAF=0.022;MQ=59.51;MQ0=0;MQRankSum=-0.947;OND=7.898e-04;PercentNBaseSolid=0.0000;QD=34.00;ReadPosRankSum=-0.405;VariantType=SNP

    DP,FS, MQRankSum, ReadPosRankSum values before and after VariantAnnotator run changes. Why is that so and which is the correct one ?

    Thanks,
    Tinu

  • SheilaSheila Broad InstituteMember, Broadie, Moderator admin

    @tinu‌

    Hi Tinu,

    You can see that the DP fields are different. Haplotype Caller imposes more stringent filters compared to Variant Annotator. Haplotype Caller also downsamples reads which accounts for the lower number of reads.

    I would trust Haplotype Caller's output.

    -Sheila

  • tinutinu Member

    @Sheila‌ Thanks

    But I would need to run VariantAnnotator inorder get all annotations required for VQSR run, right ? Since HaplotypeCaller doesnot support all annotations

    Or using VariantAnnotator should I just add annotations which are missing from HaplotypeCaller ?

  • tinutinu Member

    Does HaplotypeCaller with GATK 3.3 add all the annotations to the GVCF ?

    That would have been really useful. Now the situation is that we generate the GVCFs, but still need to retain the BAMs inorder to add additional annotations. Would have been easier if HaplotypeCaller could add all the annotations at a single go rather we having to call variants using GenotypeGVCFs and later use VariantAnnotator to add in missing annotations.

    Thanks,
    Tinu

  • Geraldine_VdAuweraGeraldine_VdAuwera Cambridge, MAMember, Administrator, Broadie admin

    @tinu‌

    HaplotypeCaller and GenotypeGVCFs add all the annotations that are recommended for VQSR by default. If you want additional annotations, then you must either specify them during the HC run (if they are supported by HC) or add them afterward with VariantAnnotator.

    What annotations are you trying to get added?

  • tinutinu Member

    I was looking for additional annotations like Coverage, AlleleBalance, AlleleBalanceBySample, VariantType like that...

  • Geraldine_VdAuweraGeraldine_VdAuwera Cambridge, MAMember, Administrator, Broadie admin

    Well, coverage is a default annotation (DP); VariantType should work with HC and anyway does not require the bam files; and the AlleleBalance annotations should work with HC (if not, let me know) but keep in mind they are experimental.

Sign In or Register to comment.