Posted by
LIM Soon Yew John (IMB) on
Aug 06, 2013; 7:33am
URL: http://imagej.273.s1.nabble.com/Memory-Problems-in-Fiji-using-macro-setBatchMode-true-tp5004321p5004322.html
Dear List,
Sorry for the extra e-mail as the problem with the memory I wrote below had been solved by updating to ImageJ 1.48b daily build and using run("Collect Garbage") in the macro to free up memory.
Best Regards,
John
________________________________________
From: ImageJ Interest Group [
[hidden email]] On Behalf Of LIM Soon Yew John (IMB) [
[hidden email]]
Sent: Tuesday, August 06, 2013 2:52 PM
To:
[hidden email]
Subject: Memory Problems in Fiji using macro setBatchMode(true)
Dear All,
I noticed that when I run macro setBatchMode(true) in Fiji, all the images created during setBatchMode(true) are trapped in memory and cannot be clear away [run("Close All") does not work]. This become a problem for 32bit Fiji as the program quickly run out of memory.
I do not encounter this problem in ImageJ. Does anyone else face this problem?
Best Regards,
John
________________________________________
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html> Dear List,
>
> I experience the same problem when using the doCommand in a macro:
Thanks to Johannes Schindelin, this bug is fixed in the ImageJ 1.48b daily build. Use the following macro to demonstrate both the problem and the fix. Run it using ImageJ 1.48b1 and the memory used to open the 100 images is reclaimed when you run the garbage collector by clicking in the "Memory" window. With ImageJ 1.48a and earlier, the memory is not reclaimed when you click in the "Memory" window.
-wayne
doCommand("Monitor Memory...");
setBatchMode(true);
for(i=0;i<100;i++) {
run("Open Image");
wait(20);
}
run("Close All");
exit;
macro "Open Image" {
newImage("Untitled", "8-bit ramp", 1024, 1024, 1);
}
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html