Eigenvector Negative Array Size Exception Error?

352 views
Skip to first unread message

Michael Johnston

unread,
Oct 20, 2017, 12:47:04 PM10/20/17
to 3D Genomics
Hi,

I tried running eigenvector at 5 kb resolution and received the following error:

Exception in thread "main" java.lang.NegativeArraySizeException
at juicebox.matrix.InMemoryMatrix.<init>(InMemoryMatrix.java:50)
at juicebox.tools.clt.old.Pearsons.computePearsons(Pearsons.java:319)
at juicebox.data.MatrixZoomData.computePearsons(MatrixZoomData.java:571)
at juicebox.data.MatrixZoomData.getPearsons(MatrixZoomData.java:478)
at juicebox.data.Dataset.getEigenvector(Dataset.java:807)
at juicebox.tools.clt.old.Eigenvector.run(Eigenvector.java:149)
at juicebox.tools.HiCTools.main(HiCTools.java:86)

What could be causing this error?

Thanks for any tips!

- Michael




On a related note, the default juicer_tools script did not request enough memory to work with 5 kb resolution, leading to this error:

Exception in thread "main" java.lang.OutOfMemoryError: Java heap space
at juicebox.data.MatrixZoomData.computePearsons(MatrixZoomData.java:549)
at juicebox.data.MatrixZoomData.getPearsons(MatrixZoomData.java:478)
at juicebox.data.Dataset.getEigenvector(Dataset.java:807)
at juicebox.tools.clt.old.Eigenvector.run(Eigenvector.java:149)
at juicebox.tools.HiCTools.main(HiCTools.java:86)

To allow it to run, the following change was made to the end of the juicer_tools script:

else # default, don't use temp directory or gpus, use CUDA 7.0
    # java -Djava.awt.headless=true  -Xmx16000m  -jar `dirname $0`/juicer_tools.jar  $*
    java -Djava.awt.headless=true  -Xmx32000m  -jar `dirname $0`/juicer_tools.jar  $*
fi

Neva Durand

unread,
Oct 20, 2017, 1:11:44 PM10/20/17
to Michael Johnston, 3D Genomics
Hello,

This means your matrices are too big to calculate the eigenvector at this resolution.  Java only allows ints to assign array lengths; the size of your matrix (dimension*dimension) is bigger than the maximum int (2,147,483,647) and so it's overflowing to a negative number.  

It's failing at line 50 in this file:

Best
Neva

--
You received this message because you are subscribed to the Google Groups "3D Genomics" group.
To unsubscribe from this group and stop receiving emails from it, send an email to 3d-genomics+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/3d-genomics/0ba41a94-32ba-4709-a405-e08bd9538968%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.



--
Neva Cherniavsky Durand, Ph.D.
Staff Scientist, Aiden Lab

Michael Johnston

unread,
Oct 20, 2017, 2:23:03 PM10/20/17
to Neva Durand, 3D Genomics
That makes perfect sense. Thank you!
Reply all
Reply to author
Forward
0 new messages