Genome Analysis Toolkit

Variant Discovery in High-Throughput Sequencing Data

GATK process banner

Need Help?

Search our documentation

Community Forum

Hi, How can we help?

Developed in the Data Sciences Platform at the Broad Institute, the toolkit offers a wide variety of tools with a primary focus on variant discovery and genotyping. Its powerful processing engine and high-performance computing features make it capable of taking on projects of any size. Learn more

GC overhead limit exceeded using Mutect2 only tumor version

Answered
0

5 comments

  • Avatar
    Genevieve Brandt (she/her)

    Hi Shirliya Dadon,

    Thanks for writing in! Here are my recommendations to try, and if none of this helps, we can look into more specific solutions for your case:

    • How much memory and disk space is available on your machine?
    • Make sure your --tmp-dir location has enough room for all the necessary temporary files
    • Check the depth of coverage for your sample at this site- ENST00000453890:301 (if it's crashing at the same site every time)

    Let me know what you find and I can help from there.

    Best,

    Genevieve

    0
    Comment actions Permalink
  • Avatar
    Shirliya Dadon

    Hi Genevieve Brandt (she/her),

    Thanks for the quick response! From what I've found:

    • There is plenty of memory and disk space available (I allocated 100G for the memory), the same goes for --tmp-dir. To have a better start point, how much memory is usually needed?
    • What is the coverage needed for Mutect to succeed? I don't think it crashed at the same site every time, but I'll look into it.

    I'm interested to understand the format of the program log. It confuses me as it seems that all the tools completed running successfully and the error only shows at the end. How do I know at which stage the error occurred?

    Thanks!

    Shir Liya.

    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Hi Shir Liya, 

    Thank you for these details. You can try turning off the java garbage collector overhead limit to see if you can get through this particular spot on the genome by using the java option -XX:-UseGCOverheadLimit. Adding another java option to your command looks like this:

    gatk --java-options "-Xmx80G -XX:-UseGCOverheadLimit" Mutect2 [Program arguments]
    • You should be providing enough memory for Mutect2 to succeed.
    • There's not a specific coverage for Mutect2 to succeed, I was just wondering if you had really high depth and the number of reads in some regions was causing the program to slow and then crash.
    • The part of the program log where the error is occurring is here:
    Exception in thread "main" java.lang.OutOfMemoryError: GC overhead limit exceeded
        at htsjdk.samtools.SAMTextHeaderCodec$ParsedHeaderLine.<init>(SAMTextHeaderCodec.java:280)
        at htsjdk.samtools.SAMTextHeaderCodec.decode(SAMTextHeaderCodec.java:97)
        at htsjdk.samtools.reference.ReferenceSequenceFileFactory.loadDictionary(ReferenceSequenceFileFactory.java:236)
        at htsjdk.samtools.reference.AbstractFastaSequenceFile.findAndLoadSequenceDictionary(AbstractFastaSequenceFile.java:91)

    This site was one of the last sites the program went through:

    12:05:06.889 INFO  ProgressMeter -  ENST00000453890:301             25.3                  1430             56.5

    Let me know if the solution I recommended helps, and if you have any further questions.

    Best,

    Genevieve

    0
    Comment actions Permalink
  • Avatar
    Shirliya Dadon

    Thanks, Genevieve!

    I tried turning off the java garbage collector, and it seemed to free up memory since the program ran longer but it crushed with a different error and on a different site, here is the full stack:

    Using GATK jar /usr/local/hurcs/miniconda3/envs/gatk4-4.2.3.0/share/gatk4-4.2.3.0-0/gatk-package-4.2.3.0-local.jar
    Running:
        java -Dsamjdk.use_async_io_read_samtools=false -Dsamjdk.use_async_io_write_samtools=true -Dsamjdk.use_async_io_write_tribble=false -Dsamjdk.compression_level=2 -Xmx90G -XX:-UseGCOverheadLimit -jar /usr/local/hurcs/miniconda3/envs/gatk4-4.2.3.0/share/gatk4-4.2.3.0-0/gatk-package-4.2.3.0-local.jar Mutect2 -R /{path}/GRCh38_RSEM/Ensembl_RSEM.transcripts.fa -I /{path}/811_NSR.sort.bam -O /{path}/NSR_bulk_811.vcf.gz -bamout /{path}/811_NSR_only_snv.bam --tmp-dir /{path}/temp_out/
    09:09:17.324 INFO  NativeLibraryLoader - Loading libgkl_compression.so from jar:file:/usr/local/hurcs/miniconda3/envs/gatk4-4.2.3.0/share/gatk4-4.2.3.0-0/gatk-package-4.2.3.0-local.jar!/com/intel/gkl/native/libgkl_compression.so
    Feb 15, 2022 9:09:17 AM shaded.cloud_nio.com.google.auth.oauth2.ComputeEngineCredentials runningOnComputeEngine
    INFO: Failed to detect whether we are running on Google Compute Engine.
    09:09:17.658 INFO  Mutect2 - ------------------------------------------------------------
    09:09:17.659 INFO  Mutect2 - The Genome Analysis Toolkit (GATK) v4.2.3.0
    09:09:17.659 INFO  Mutect2 - For support and documentation go to https://software.broadinstitute.org/gatk/
    09:09:17.659 INFO  Mutect2 - Executing as shirliyadadon@glacier-12.cs.huji.ac.il on Linux v5.10.46-aufs-1 amd64
    09:09:17.659 INFO  Mutect2 - Java runtime: OpenJDK 64-Bit Server VM v1.8.0_302-b08
    09:09:17.660 INFO  Mutect2 - Start Date/Time: February 15, 2022 9:09:17 AM IST
    09:09:17.660 INFO  Mutect2 - ------------------------------------------------------------
    09:09:17.660 INFO  Mutect2 - ------------------------------------------------------------
    09:09:17.660 INFO  Mutect2 - HTSJDK Version: 2.24.1
    09:09:17.660 INFO  Mutect2 - Picard Version: 2.25.4
    09:09:17.660 INFO  Mutect2 - Built for Spark Version: 2.4.5
    09:09:17.660 INFO  Mutect2 - HTSJDK Defaults.COMPRESSION_LEVEL : 2
    09:09:17.660 INFO  Mutect2 - HTSJDK Defaults.USE_ASYNC_IO_READ_FOR_SAMTOOLS : false
    09:09:17.660 INFO  Mutect2 - HTSJDK Defaults.USE_ASYNC_IO_WRITE_FOR_SAMTOOLS : true
    09:09:17.660 INFO  Mutect2 - HTSJDK Defaults.USE_ASYNC_IO_WRITE_FOR_TRIBBLE : false
    09:09:17.660 INFO  Mutect2 - Deflater: IntelDeflater
    09:09:17.660 INFO  Mutect2 - Inflater: IntelInflater
    09:09:17.661 INFO  Mutect2 - GCS max retries/reopens: 20
    09:09:17.661 INFO  Mutect2 - Requester pays: disabled
    09:09:17.661 INFO  Mutect2 - Initializing engine
    09:09:31.054 INFO  Mutect2 - Done initializing engine
    09:09:33.714 INFO  NativeLibraryLoader - Loading libgkl_utils.so from jar:file:/usr/local/hurcs/miniconda3/envs/gatk4-4.2.3.0/share/gatk4-4.2.3.0-0/gatk-package-4.2.3.0-local.jar!/com/intel/gkl/native/libgkl_utils.so
    09:09:33.766 INFO  NativeLibraryLoader - Loading libgkl_pairhmm_omp.so from jar:file:/usr/local/hurcs/miniconda3/envs/gatk4-4.2.3.0/share/gatk4-4.2.3.0-0/gatk-package-4.2.3.0-local.jar!/com/intel/gkl/native/libgkl_pairhmm_omp.so
    09:09:33.844 INFO  IntelPairHmm - Flush-to-zero (FTZ) is enabled when running PairHMM
    09:09:33.844 INFO  IntelPairHmm - Available threads: 4
    09:09:33.844 INFO  IntelPairHmm - Requested threads: 4
    09:09:33.844 INFO  PairHMM - Using the OpenMP multi-threaded AVX-accelerated native PairHMM implementation
    09:09:37.504 INFO  ProgressMeter - Starting traversal
    09:09:37.505 INFO  ProgressMeter -        Current Locus  Elapsed Minutes     Regions Processed   Regions/Minute
    09:09:48.500 INFO  ProgressMeter - ENST00000612152:1501              0.2                    30            164.3
    09:10:01.761 INFO  ProgressMeter -  ENST00000371582:601              0.4                    50            123.7
    09:10:21.434 INFO  ProgressMeter -    ENST00000367770:1              0.7                    70             95.6
    09:10:32.422 INFO  ProgressMeter -    ENST00000470238:1              0.9                   120            131.1
    09:10:43.038 INFO  ProgressMeter - ENST00000459772:1801              1.1                   170            155.6
    09:10:54.334 INFO  ProgressMeter -    ENST00000472795:1              1.3                   180            140.6
    09:11:05.053 INFO  ProgressMeter - ENST00000374003:1201              1.5                   210            143.9
    09:11:15.661 INFO  ProgressMeter -  ENST00000457296:301              1.6                   240            146.7
    09:11:33.109 INFO  ProgressMeter -  ENST00000359637:301              1.9                   250            129.8
    09:11:46.290 INFO  ProgressMeter -  ENST00000630130:901              2.1                   300            139.8
    09:12:03.025 INFO  ProgressMeter -    ENST00000505197:1              2.4                   330            136.1
    09:12:16.413 INFO  ProgressMeter -  ENST00000514004:901              2.6                   360            135.9
    09:12:41.073 INFO  ProgressMeter -  ENST00000616923:301              3.1                   380            124.2
    09:12:52.962 INFO  ProgressMeter - ENST00000353205:1501              3.3                   430            132.0
    09:13:03.444 INFO  ProgressMeter -    ENST00000435187:1              3.4                   460            134.0
    09:13:15.330 INFO  ProgressMeter -    ENST00000483261:1              3.6                   490            135.0
    09:13:30.015 INFO  ProgressMeter -  ENST00000003912:901              3.9                   510            131.6
    09:13:41.983 INFO  ProgressMeter -  ENST00000432012:901              4.1                   560            137.4
    09:13:57.004 INFO  ProgressMeter -    ENST00000374811:1              4.3                   590            136.4
    09:14:20.769 INFO  ProgressMeter - ENST00000484069:2308              4.7                   610            129.2
    09:14:41.439 INFO  ProgressMeter -    ENST00000434342:1              5.1                   670            132.3
    09:14:53.676 INFO  ProgressMeter - ENST00000003084:2401              5.3                   700            132.8
    09:15:18.745 INFO  ProgressMeter -  ENST00000546407:129              5.7                   740            130.1
    09:15:50.740 INFO  ProgressMeter -  ENST00000621535:601              6.2                   750            120.6
    09:16:02.282 INFO  ProgressMeter - ENST00000647978:1201              6.4                   770            120.1
    09:16:28.459 INFO  ProgressMeter -  ENST00000649781:601              6.8                   800            116.8
    09:16:39.322 INFO  ProgressMeter -  ENST00000413588:601              7.0                   850            120.9
    09:16:56.859 INFO  ProgressMeter -  ENST00000003100:355              7.3                   870            118.8
    09:17:08.113 INFO  ProgressMeter - ENST00000340022:2101              7.5                   900            119.8
    09:17:20.500 INFO  ProgressMeter -  ENST00000412043:301              7.7                   950            123.1
    09:17:34.816 INFO  ProgressMeter -  ENST00000430102:301              8.0                   970            121.9
    09:17:48.024 INFO  ProgressMeter -    ENST00000445516:1              8.2                   980            119.9
    09:18:07.278 INFO  ProgressMeter -  ENST00000470309:301              8.5                  1010            118.9
    09:18:24.531 INFO  ProgressMeter -  ENST00000228345:601              8.8                  1040            118.4
    09:19:09.768 INFO  ProgressMeter -    ENST00000461568:1              9.5                  1070            112.2
    09:19:24.517 INFO  ProgressMeter -    ENST00000488642:1              9.8                  1100            112.4
    09:19:39.646 INFO  ProgressMeter -    ENST00000542584:1             10.0                  1120            111.6
    09:19:58.284 INFO  ProgressMeter -  ENST00000425880:301             10.3                  1140            110.2
    09:20:10.546 INFO  ProgressMeter - ENST00000453194:1501             10.6                  1180            111.8
    09:20:34.614 INFO  ProgressMeter -  ENST00000544785:301             11.0                  1200            109.6
    09:20:50.109 INFO  ProgressMeter -    ENST00000508014:1             11.2                  1220            108.8
    09:21:42.043 INFO  ProgressMeter -  ENST00000512397:601             12.1                  1230            101.9
    09:21:54.113 INFO  ProgressMeter -  ENST00000381177:601             12.3                  1250            101.8
    09:22:07.043 INFO  ProgressMeter -    ENST00000381192:1             12.5                  1260            100.9
    09:22:21.796 INFO  ProgressMeter - ENST00000611428:1201             12.7                  1280            100.5
    09:22:32.899 INFO  ProgressMeter -  ENST00000646103:301             12.9                  1290             99.8
    09:22:48.741 INFO  ProgressMeter -  ENST00000360937:901             13.2                  1330            100.9
    09:23:01.117 INFO  ProgressMeter -  ENST00000480582:301             13.4                  1360            101.5
    09:23:15.743 INFO  ProgressMeter -    ENST00000361301:1             13.6                  1390            101.9
    09:24:00.950 INFO  ProgressMeter -  ENST00000453890:301             14.4                  1430             99.4
    09:24:12.825 INFO  ProgressMeter - ENST00000471043:2401             14.6                  1460            100.1
    09:25:22.385 INFO  ProgressMeter -  ENST00000492310:601             15.7                  1470             93.3
    09:25:54.886 INFO  ProgressMeter -  ENST00000265854:301             16.3                  1480             90.9
    09:26:27.209 INFO  ProgressMeter -  ENST00000402746:301             16.8                  1500             89.1
    09:26:56.989 INFO  ProgressMeter -  ENST00000406869:901             17.3                  1510             87.2
    09:27:29.380 INFO  ProgressMeter -  ENST00000429625:301             17.9                  1520             85.1
    09:29:29.503 INFO  ProgressMeter -    ENST00000444373:1             19.9                  1530             77.0
    09:32:26.676 INFO  ProgressMeter -    ENST00000459731:1             22.8                  1540             67.5
    09:38:15.311 INFO  ProgressMeter -    ENST00000481633:1             28.6                  1550             54.1
    08:21:54.328 INFO  VectorLoglessPairHMM - Time spent in setup for JNI call : 9.607140000000001E-4
    08:21:54.330 INFO  PairHMM - Total compute time in PairHMM computeLogLikelihoods() : 0.08795621
    08:21:54.330 INFO  SmithWatermanAligner - Total compute time in java Smith-Waterman : 0.05 sec
    08:21:54.331 INFO  Mutect2 - Shutting down engine
    [February 16, 2022 8:21:54 AM IST] org.broadinstitute.hellbender.tools.walkers.mutect.Mutect2 done. Elapsed time: 1,392.62 minutes.
    Runtime.totalMemory()=79934521344
    Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
        at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.addConditionWaiter(AbstractQueuedSynchronizer.java:1860)
        at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos(AbstractQueuedSynchronizer.java:2073)
        at java.util.concurrent.ArrayBlockingQueue.poll(ArrayBlockingQueue.java:418)
        at htsjdk.samtools.util.AbstractAsyncWriter$WriterRunnable.run(AbstractAsyncWriter.java:122)
        at java.lang.Thread.run(Thread.java:748)

    0
    Comment actions Permalink
  • Avatar
    Genevieve Brandt (she/her)

    Thanks so much for trying this. I have one other option in mind to try, which would try to decrease the memory needed by the program. Could you run Mutect2 with the option —linked-de-bruijn graph true? 

    Let me know how that goes too.

    0
    Comment actions Permalink

Please sign in to leave a comment.

Powered by Zendesk