Imagej 1.48 - Java heap space error - unable to load high resolution images

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Imagej 1.48 - Java heap space error - unable to load high resolution images

sharanbabuk
This post was updated on .
I'm working on ImageJ 1.48V and I received below error while I was trying to open high resolution images with it. Image size was approximately 500mb with 21600 x 21600 dimension. I'm not sure if i need to increase any heap size to bypass this error.
Any help would be appreciated.


Error:
        at java.awt.image.DataBufferByte.<init>(DataBufferByte.java:58)
        at java.awt.image.ComponentSampleModel.createDataBuffer(ComponentSampleModel.java:397)
        at java.awt.image.Raster.createWritableRaster(Raster.java:938)
        at javax.imageio.ImageTypeSpecifier.createBufferedImage(ImageTypeSpecifier.java:1056)
        at javax.imageio.ImageReader.getDestination(ImageReader.java:2879)
        at com.sun.imageio.plugins.png.PNGImageReader.readImage(PNGImageReader.java:1263)
        at com.sun.imageio.plugins.png.PNGImageReader.read(PNGImageReader.java:1560)
        at javax.imageio.ImageIO.read(ImageIO.java:1422)
        at javax.imageio.ImageIO.read(ImageIO.java:1282)
        at ij.io.Opener.openUsingImageIO(Opener.java:595)
        at ij.io.Opener.openImage(Opener.java:298)
        at ij.io.Opener.openImage(Opener.java:334)
        at ij.io.Opener.open(Opener.java:144)
        at ij.io.Opener.openAndAddToRecent(Opener.java:247)
        at ij.plugin.DragAndDrop.openFile(DragAndDrop.java:176)
        at ij.plugin.DragAndDrop.run(DragAndDrop.java:152)
        at java.lang.Thread.run(Thread.java:619)




imagej - error for high resolution files
Reply | Threaded
Open this post in threaded view
|

Re: Imagej 1.48 - Java heap space error - unable to load high resolution images

Michael Schmid
Hi Sharan,

you can try to increase the maximum memory allocated to ImageJ in Edit>Options>Memory&Threads.

If you click on the status line below all the tools in the main ImageJ toolbar you will see how much free memory you have. If you run Plugins>Utilities>Monitor Memory while opening the stack you will also see how much memory is used.

Michael
________________________________________________________________
On Oct 4, 2014, at 03:51, sharanbabuk wrote:

> I'm working on ImageJ 1.48V and I received below error while I was trying to
> open high resolution images with it. Imagej size was approximately 500mb
> with 21600 x 21600 dimension. I'm not sure if i need to increase any heap
> size to bypass this error.
> Any help would be appreciated.
> <http://imagej.1557.x6.nabble.com/file/n5009900/imagej-error.jpg>
>
> Error:
> / at java.awt.image.DataBufferByte.<init>(DataBufferByte.java:58)
> at
> java.awt.image.ComponentSampleModel.createDataBuffer(ComponentSampleModel.java:397)
> at java.awt.image.Raster.createWritableRaster(Raster.java:938)
> at
> javax.imageio.ImageTypeSpecifier.createBufferedImage(ImageTypeSpecifier.java:1056)
> at javax.imageio.ImageReader.getDestination(ImageReader.java:2879)
> at
> com.sun.imageio.plugins.png.PNGImageReader.readImage(PNGImageReader.java:1263)
> at
> com.sun.imageio.plugins.png.PNGImageReader.read(PNGImageReader.java:1560)
> at javax.imageio.ImageIO.read(ImageIO.java:1422)
> at javax.imageio.ImageIO.read(ImageIO.java:1282)
> at ij.io.Opener.openUsingImageIO(Opener.java:595)
> at ij.io.Opener.openImage(Opener.java:298)
> at ij.io.Opener.openImage(Opener.java:334)
> at ij.io.Opener.open(Opener.java:144)
> at ij.io.Opener.openAndAddToRecent(Opener.java:247)
> at ij.plugin.DragAndDrop.openFile(DragAndDrop.java:176)
> at ij.plugin.DragAndDrop.run(DragAndDrop.java:152)
> at java.lang.Thread.run(Thread.java:619)
> /
>
>
>
> <http://imagej.1557.x6.nabble.com/file/n5009900/imagej-error.jpg>
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html