Re: where's the problem?
Posted by
Michael Schmid on
Jun 19, 2007; 5:37pm
URL: http://imagej.273.s1.nabble.com/where-s-the-problem-tp3699080p3699081.html
Hi Nicolas,
you have closed the stack while saving to disk was still in
progress. I could reproduce the exception by quickly closing
an image with a large stack (150 MB) while saving.
Having a quick look at the code of ImageJ, it seems to me that
saving does not lock the image to prevent the user from closing
the image stack prematurely or modifying it otherwise.
Be more patient with "close", especially on a slow computer!
Michael
________________________________________________________________
On 19 Jun 2007, at 16:02, Nicolas PREYAT wrote:
> Hi everybody,
> I'm a new user of this software, it is useful for me to align some
> slices but I encounter a problem. When the size of my stack
> increase ( more than 100MB, I think), if I close it and try to open
> it in a second step, here is what's happening:
> While the file is opening I can see in the status bar the correct
> number of slices but when the software charged the half of the
> correct size of the stack, Image J provide me a file with the just
> the half of what it could be.
> I hope somebody knows what I'm telling about.
> Thank in advance for your help.
> Preyat Nicolas
>
> NB:
> 1) in Edit/option menu I put the memory to 600MB so it is not the
> problem.
> 2) When I closed the file, a window appeared, perhaps is there a link:
> java.lang.NullPointerException
> at java.io.FileOutputStream.writeBytes(Native Method)
> at java.io.FileOutputStream.write(FileOutputStream.java:260)
> at java.io.BufferedOutputStream.write(BufferedOutputStream.java:105)
> at java.io.DataOutputStream.write(DataOutputStream.java:90)
> at ij.io.ImageWriter.write8BitImage(ImageWriter.java:28)
> at ij.io.ImageWriter.write8BitStack(ImageWriter.java:38)
> at ij.io.ImageWriter.write(ImageWriter.java:180)
> at ij.io.TiffEncoder.write(TiffEncoder.java:103)
> at ij.io.FileSaver.saveAsTiffStack(FileSaver.java:108)
> at ij.io.FileSaver.saveAsTiff(FileSaver.java:70)
> at ij.io.FileSaver.save(FileSaver.java:46)
> at ij.plugin.Commands.save(Commands.java:55)
> at ij.plugin.Commands.run(Commands.java:27)
> at ij.IJ.runPlugIn(IJ.java:127)
> at ij.Executer.runCommand(Executer.java:95)
> at ij.Executer.run(Executer.java:49)
> at java.lang.Thread.run(Thread.java:613)