Notice:
If you happen to see a question you know the answer to, please do chime in and help your fellow community members. We appreciate your help!

Test-drive the GATK tools and Best Practices pipelines on Terra


Check out this blog post to learn how you can get started with GATK and try out the pipelines in preconfigured workspaces (with a user-friendly interface!) without having to install anything.

FilterMutectCalls "--contamination-table contamination.table" error

FishcanFishcan ChinaMember
I'm tring build PON for FFPE sample, so I folow the pipeline as mentioned at article?id=24057.
I'm using gatk4.1.2.0 installed by miniconda3 , in standalone virtualenv.

I just follow "A step-by-step guide to the new Mutect2 Read Orientation Artifacts Workflow", but in tumor-only manner.

~ gatk Mutect2 -R <ref.fasta> -I <nomal.bam> -germline-resource af-only-gnomad/af-only-gnomad.raw.sites.b37.vcf.gz --f1r2-tar-gz f1r2.tar.gz -O unfiltered.vcf

~ gatk LearnReadOrientationModel -I f1r2.tar.gz -O read-orientation-model.tar.gz

~ gatk GetPileupSummaries -I <nomal.bam> -V GetPileupSummaries/small_exac_common_3_b37.vcf.gz -L GetPileupSummaries/small_exac_common_3_b37.vcf.gz -O getpileupsummaries.table

~ gatk CalculateContamination -I getpileupsummaries.table -tumor-segmentation segments.table -O calculatecontamination.table

these command abave all run well without error, but when running

~ gatk FilterMutectCalls -V unfiltered.vcf --tumor-segmentation segments.table --contamination-table contamination.table --ob-priors read-orientation-model.tar.gz -O filtered.vcf.gz

I got "A USER ERROR has occurred: Encountered an IO exception while reading from contamination.table."

contamination.table look like
"""
sample contamination error
normal 0.0036448755598194275 3.2698551543146396E-4
"""

I have been search around, but find nothing really helpful.

So, I just come here for help.

Thanks for any help !

Answers

  • bhanuGandhambhanuGandham Cambridge MAMember, Administrator, Broadie, Moderator admin

    Hi @Fishcan

    1) What file system are you running this on?
    2) Also please generate and send us the stack trace for this error by running the gatk command with this option -DGATK_STACKTRACE_ON_USER_EXCEPTION=true

  • FishcanFishcan ChinaMember
    LSB Version: :core-4.1-amd64:core-4.1-noarch
    Distributor ID: CentOS
    Description: CentOS Linux release 7.5.1804 (Core)
    Release: 7.5.1804
    Codename: Core

    all file in /home are in file system like this:
    sdb
    └─sdb1 LVM2_member xxxxxxx
    └─data-home xfs xxxxxxxx /home


    When I try again ,with --java-options '-DGATK_STACKTRACE_ON_USER_EXCEPTION=true',
    got the stack trace below:
    ***********************************************************************

    A USER ERROR has occurred: Encountered an IO exception while reading from contamination.table.

    ***********************************************************************
    org.broadinstitute.hellbender.exceptions.UserException: Encountered an IO exception while reading from contamination.table.
    at org.broadinstitute.hellbender.tools.walkers.contamination.ContaminationRecord.readFromFile(ContaminationRecord.java:53)
    at org.broadinstitute.hellbender.tools.walkers.mutect.filtering.ContaminationFilter.lambda$new$0(ContaminationFilter.java:24)
    at java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:193)
    at java.util.ArrayList$ArrayListSpliterator.forEachRemaining(ArrayList.java:1382)
    at java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:481)
    at java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:471)
    at java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:708)
    at java.util.stream.AbstractPipeline.evaluate(AbstractPipeline.java:234)
    at java.util.stream.ReferencePipeline.collect(ReferencePipeline.java:499)
    at org.broadinstitute.hellbender.tools.walkers.mutect.filtering.ContaminationFilter.<init>(ContaminationFilter.java:25)
    at org.broadinstitute.hellbender.tools.walkers.mutect.filtering.Mutect2FilteringEngine.buildFiltersList(Mutect2FilteringEngine.java:207)
    at org.broadinstitute.hellbender.tools.walkers.mutect.filtering.Mutect2FilteringEngine.<init>(Mutect2FilteringEngine.java:55)
    at org.broadinstitute.hellbender.tools.walkers.mutect.filtering.FilterMutectCalls.onTraversalStart(FilterMutectCalls.java:124)
    at org.broadinstitute.hellbender.engine.GATKTool.doWork(GATKTool.java:1037)
    at org.broadinstitute.hellbender.cmdline.CommandLineProgram.runTool(CommandLineProgram.java:139)
    at org.broadinstitute.hellbender.cmdline.CommandLineProgram.instanceMainPostParseArgs(CommandLineProgram.java:191)
    at org.broadinstitute.hellbender.cmdline.CommandLineProgram.instanceMain(CommandLineProgram.java:210)
    at org.broadinstitute.hellbender.Main.runCommandLineProgram(Main.java:162)
    at org.broadinstitute.hellbender.Main.mainEntry(Main.java:205)
    at org.broadinstitute.hellbender.Main.main(Main.java:291)
  • FishcanFishcan ChinaMember
    > @bhanuGandham said:
    > Hi @Fishcan
    >
    > 1) What file system are you running this on?
    > 2) Also please generate and send us the stack trace for this error by running the gatk command with this option -DGATK_STACKTRACE_ON_USER_EXCEPTION=true

    Maybe I need @bhanuGandham ?
  • FishcanFishcan ChinaMember
    > @bhanuGandham said:
    > Hi @Fishcan
    >
    > 1) What file system are you running this on?
    > 2) Also please generate and send us the stack trace for this error by running the gatk command with this option -DGATK_STACKTRACE_ON_USER_EXCEPTION=true

    Hi, I have tested the whole pipeline on another server, and everything looks just fine.
    After some check , I think the Error simply came from wrong file path, As I had been running multiple test on different tools on frist sever, I missplace some of the output file, so that the commond won't work.

    Sorry for my carelessness.

    So I would advise some clearer Error mesage such as "File not found".
    Which would be less confused to user.
Sign In or Register to comment.