aboyle / F-seq

A Feature Density Estimator for High-Throughput Sequence Tags
http://fureylab.web.unc.edu/software/fseq/
GNU General Public License v3.0
23 stars 5 forks source link

F-seq 1.85 craches out of memory error #7

Open ghuls opened 10 years ago

ghuls commented 10 years ago

F-seq 1.85 craches on one of my bed files (BAM ==> BED) with an out of memory error (F-Seq is allowed to use 240 GiB of memory) (the other 11 samples work fine with 8Gib of memory):

$ /software/fseq/fseq-1.85/bin/fseq -of wig -o output_dir test.bed
F-Seq Version 1.85
Exception in thread "main" java.lang.OutOfMemoryError: Requested array size exceeds VM limit
        at java.util.Arrays.copyOf(Arrays.java:2219)
        at java.util.ArrayList.grow(ArrayList.java:213)
        at java.util.ArrayList.ensureCapacityInternal(ArrayList.java:187)
        at java.util.ArrayList.add(ArrayList.java:411)
        at edu.duke.igsp.gkde.Main.wgShiftCalc(Main.java:403)
        at edu.duke.igsp.gkde.Main.main(Main.java:193)

F-seq 1.84 works (uses around 6.4 GiB of memory):

$ /software/fseq/fseq-1.84/bin/fseq -of wig -o output_dir test.bed
antonkratz commented 8 years ago

I am running into exactly the same problem.

I am using F-Seq Version 1.85.

I invoke f-seq with a paired-end bed12 file like this: ./fseq -of bed input.srtd.bed12

...and get:

Exception in thread "main" java.lang.OutOfMemoryError: Requested array size exceeds VM limit at java.util.Arrays.copyOf(Arrays.java:2219) at java.util.ArrayList.grow(ArrayList.java:213) at java.util.ArrayList.ensureCapacityInternal(ArrayList.java:187) at java.util.ArrayList.add(ArrayList.java:411) at edu.duke.igsp.gkde.Main.wgShiftCalc(Main.java:403) at edu.duke.igsp.gkde.Main.main(Main.java:193) I increased the RAM to the java vm gradually until a whopping 128 GB in fseq/bin/fseq:

JAVAOPTS="-Xmx128G"

The original issue has been reported on Jan 9, 2014. I am reporting on Sep 5, 2016.

aboyle commented 8 years ago

Can you provide a link to the bed file? One thought is that there is an aberrant read position throwing things off because it is much larger than the chromosome. This function is estimating the distance between reads. If you have a good idea of that distance, you can just set the fragment size.

Another note, F-seq doesn't support paired end reads in BED12 format. You would actually be losing half of your reads. What you will want to do is just take the center of each read pair and set -f 0.

marina-yurieva commented 7 years ago

F-seq crashes on my bed files as well even if I increase memory to 100GB and make a small bed file with just 2 chromosomes. I do use PE reads though. Could you please explain how to deal with PE? What do you mean by taking the center?

Thanks!

olgabaranov commented 5 years ago

I can confirm a similar (or related, not sure) issue on Ubuntu 18.04. Starting with a small bed-file of 241Mb (containing chromosome 1 reads only, paired ends) after a short while I get an error (I have increased the limit to 60 Gb RAM)

F-Seq Version 1.85
Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
    at java.base/java.util.Arrays.copyOf(Arrays.java:3688)
    at java.base/java.util.ArrayList.grow(ArrayList.java:237)
    at java.base/java.util.ArrayList.grow(ArrayList.java:242)
    at java.base/java.util.ArrayList.add(ArrayList.java:467)
    at java.base/java.util.ArrayList.add(ArrayList.java:480)
    at edu.duke.igsp.gkde.Main.wgShiftCalc(Main.java:403)
    at edu.duke.igsp.gkde.Main.main(Main.java:193)

Though there was an issue preceeding it. I can not ant F-seq as it stands now. The error message I get when trying is:


prepare:

compile:
    [javac] /home/rad/packages/F-seq/build.xml:59: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
    [javac] Compiling 11 source files to /home/rad/packages/F-seq/build~/classes
    [javac] warning: [options] bootstrap class path not set in conjunction with -source 5
    [javac] error: Source option 5 is no longer supported. Use 6 or later.

BUILD FAILED
/home/rad/packages/F-seq/build.xml:59: Compile failed; see the compiler error output for details.

Total time: 0 seconds

When I change the source in build.xml to 1.6 (or 1.8) I get a warning, but the build is successful:


prepare:

compile:
    [javac] /home/rad/packages/F-seq/build.xml:59: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
    [javac] Compiling 11 source files to /home/rad/packages/F-seq/build~/classes
    [javac] warning: [options] bootstrap class path not set in conjunction with -source 6
    [javac] warning: [options] source value 6 is obsolete and will be removed in a future release
    [javac] warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
    [javac] /home/rad/packages/F-seq/src/edu/duke/igsp/gkde/KDEChromosome.java:34: warning: UtilSystemException is internal proprietary API and may be removed in a future release
    [javac] import com.sun.corba.se.impl.logging.UtilSystemException;
    [javac]                                     ^
    [javac] Note: /home/rad/packages/F-seq/src/edu/duke/igsp/gkde/Main.java uses or overrides a deprecated API.
    [javac] Note: Recompile with -Xlint:deprecation for details.
    [javac] 4 warnings

jar:
      [jar] Building jar: /home/rad/packages/F-seq/build~/fseq.jar

dist-all:
      [tar] Building tar: /home/rad/packages/F-seq/dist~/fseq.tar
     [gzip] Building: /home/rad/packages/F-seq/dist~/fseq.tgz

all:

BUILD SUCCESSFUL
Total time: 1 second