-
Notifications
You must be signed in to change notification settings - Fork 73
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ComputeSamTags java.lang.OutOfMemoryError: Java heap space error #312
Comments
Potential fixes:
|
Hi, I am assisting @emyli14 by creating a Snakemake workflow to run on a compute cluster. I encountered the same OOM exception today before getting directed to this issue. I can supply this additional information:
I can test your suggested modifications to gridss.sh, but I require a sys admin to create a copy of the environment module. I can't start editing the version shared by all users. Also, given your comments regarding And for running with 128G RAM, what value for |
OK, I have a duplicate test module setup. The relevant line for adjust
Not sure of a good value, so I will increase by 2G increments and test. |
A bit more information. I modified
|
Ok, with that error message my best guess is that you don't have unique read names. Do all your SAM records have the same read name? SAM section 1.4.1 states:
GRIDSS does not support unnamed ( |
In the same location as the reference genome itself. It it's not writable, GRIDSS will just silently fail and continue since the genome caching isn't critical. |
I have confirmed that all read names are unique and no reads are unnamed. |
This one has me stumped. Is it possible to share the data (or a subset thereof?)?
In coincidence, I just happen to have rewritten the function the crash occurs in. Would to be able to rerun the latest GRIDSS version (2.8.3)? |
NB: tags can be checked by looking at INPUT.gridss.working/INPUT.tag_metrics |
Thanks for your help and suggestions. Happy to share a subset of the data. I've attached most of my output files to this dropbox folder. None the tag metrics you mentioned above seem to be present, and as far as I can tell there are no secondary alignments reported. Will try to get GRIDSS version (2.8.3) running. |
Should be fixed in the next release. |
I am trying to run the preprocessing step of gridss on a single file to test the pipeline and am encountering an error of
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
during the ComputeSamTags command. I have tried adjusting the value of--jvmheap
to no avail. Can you offer any advice? Thanks.My gridss command line is:
gridss.sh --reference $REFERENCE --output $OUTPUT --assembly $ASSEMBLY --workingdir $WORKINGDIR --blacklist $BLACKLIST --steps PreProcess $INPUT_1
The error in the output log file reads:
19:24:41.164 INFO NativeLibraryLoader - Loading libgkl_compression.so from jar:file:/apps/gridss/2.8.0/bin/gridss-2.8.0-gridss-jar-with-dependencies.jar!/com/intel/gkl/native/libgkl_compression.so [Thu Mar 19 19:24:41 AEDT 2020] ComputeSamTags INPUT=./output/gridss/Single/intermediate/HY5NTCCXX_4_160805_FR07885900_Homo-sapiens__R_160712_KELWIL1_BLAIRDNA_M004.dupmarked.realigned.recalibrated.bam.gridss.working/tmp.HY5NTCCXX_4_160805_FR07885900_Homo-sapiens__R_160712_KELWIL1_BLAIRDNA_M004.dupmarked.realigned.recalibrated.bam.namedsorted.bam OUTPUT=/dev/stdout ASSUME_SORTED=true SOFTEN_HARD_CLIPS=true FIX_MATE_INFORMATION=true FIX_DUPLICATE_FLAG=true FIX_SA=true FIX_MISSING_HARD_CLIP=true RECALCULATE_SA_SUPPLEMENTARY=true TAGS=[R2, Q2, MQ, SA, MC, NM] WORKING_DIR=./output/gridss/Single/intermediate TMP_DIR=[./output/gridss/Single/intermediate/HY5NTCCXX_4_160805_FR07885900_Homo-sapiens__R_160712_KELWIL1_BLAIRDNA_M004.dupmarked.realigned.recalibrated.bam.gridss.working] COMPRESSION_LEVEL=0 REFERENCE_SEQUENCE=./genome2.fa IGNORE_DUPLICATES=true VERBOSITY=INFO QUIET=false VALIDATION_STRINGENCY=STRICT MAX_RECORDS_IN_RAM=500000 CREATE_INDEX=false CREATE_MD5_FILE=false GA4GH_CLIENT_SECRETS=client_secrets.json USE_JDK_DEFLATER=false USE_JDK_INFLATER=false [Thu Mar 19 19:24:41 AEDT 2020] Executing as mcc549@c324 on Linux 4.12.14-95.32-default amd64; Java HotSpot(TM) 64-Bit Server VM 1.8.0_141-b15; Deflater: Intel; Inflater: Intel; Provider GCS is not available; Picard version: 2.8.0-gridss INFO 2020-03-19 19:24:42 SAMFileWriterFactory Unknown file extension, assuming BAM format when writing file: file:///dev/stdout INFO 2020-03-19 19:24:45 ComputeSamTags Seen many non-increasing record positions. Printing Read-names as well. INFO 2020-03-19 19:25:13 ComputeSamTags Processed 1,000,000 records. Elapsed time: 00:00:30s. Time for last 1,000,000: 30s. Last read position: 8:112,220,272. Last read name: ST-E00152:202:HY5NTCCXX:4:1102:31020:32127 Exception in thread "tmp.HY5NTCCXX_4_160805_FR07885900_Homo-sapiens__R_160712_KELWIL1_BLAIRDNA_M004.dupmarked.realigned.recalibrated.bam.namedsorted.bam-tags" java.lang.RuntimeException: java.lang.OutOfMemoryError: Java heap space at au.edu.wehi.idsv.util.AsyncBufferedIterator$ReaderRunnable.run(AsyncBufferedIterator.java:189) at java.lang.Thread.run(Thread.java:748) Caused by: java.lang.OutOfMemoryError: Java heap space at java.util.ArrayDeque.doubleCapacity(ArrayDeque.java:157) at java.util.ArrayDeque.addFirst(ArrayDeque.java:231) at au.edu.wehi.idsv.sam.SAMRecordUtil.calculateSATags(SAMRecordUtil.java:1049) at au.edu.wehi.idsv.sam.SAMRecordUtil.calculateTemplateTags(SAMRecordUtil.java:729) at au.edu.wehi.idsv.sam.TemplateTagsIterator.ensureQueue(TemplateTagsIterator.java:47) at au.edu.wehi.idsv.sam.TemplateTagsIterator.hasNext(TemplateTagsIterator.java:54) at au.edu.wehi.idsv.util.AsyncBufferedIterator$ReaderRunnable.run(AsyncBufferedIterator.java:165) ... 1 more [Thu Mar 19 19:25:40 AEDT 2020] gridss.ComputeSamTags done. Elapsed time: 0.99 minutes. Runtime.totalMemory()=4151836672 Exception in thread "main" java.lang.OutOfMemoryError: Java heap space at java.util.ArrayDeque.doubleCapacity(ArrayDeque.java:157) at java.util.ArrayDeque.addFirst(ArrayDeque.java:231) at au.edu.wehi.idsv.sam.SAMRecordUtil.calculateSATags(SAMRecordUtil.java:1049) at au.edu.wehi.idsv.sam.SAMRecordUtil.calculateTemplateTags(SAMRecordUtil.java:729) at au.edu.wehi.idsv.sam.TemplateTagsIterator.ensureQueue(TemplateTagsIterator.java:47) at au.edu.wehi.idsv.sam.TemplateTagsIterator.hasNext(TemplateTagsIterator.java:54) at au.edu.wehi.idsv.util.AsyncBufferedIterator$ReaderRunnable.run(AsyncBufferedIterator.java:165) at java.lang.Thread.run(Thread.java:748) [bam_sort_core] merging from 0 files and 8 in-memory blocks...
The text was updated successfully, but these errors were encountered: