Posted by
Johannes Koch on
Sep 17, 2013; 9:56am
URL: http://imagej.273.s1.nabble.com/ImageJ-does-not-wait-for-ImageJ-tp5004817.html
Dear Listers,
just to inform you about an issue, which did not happen (to me)
previously. Maybe it's a feature, I'd rather consider it as (slightly)
buggy - is the case with 1.48b and c (on Win7, 64-bit).
I open a series of images, say 20 and run this macro:
//snip
run("Set Measurements...", "area mean min integrated redirect=None
decimal=2");
n=nImages;
for(i=0; i<n; i++) {
name=getTitle();
Stack.setPosition(2, 1, 1);
run("Duplicate...", "title=work channels=1-3");
selectWindow(name);
close();
*wait(500);*
run("Subtract Background...", "rolling=25 sliding disable");
*wait(500);*
run("Measure");
setResult("Description", i, name);
updateResults();
selectWindow("work");
close();
*wait(500);*
}
//snip
without the "WAIT(500);" commands, ImageJ does not necessarily waits
until the previous operation is finished and already performs the next.
In that scenario, I obvioulsy wanted to subtract the background BEFORE
measuring integrated densities. Every now and then (10-30% of the
processed images), irregularities occured, i.e. suddenly the mean grey
value was 10fold higher (in comparable images). Processing the images
manually produced expected results.
after I added the two middle wait commands, measurement results were ok.
But then it happened that, ImageJ did not necessarily wait until the
previous "work" image was closed and already started the next iteration.
This became obvious as suddenly the NAME variable did not contain the
image title of the next image but rather the place-holder "work". Again,
adding the wait comman eliminated that problem.
cheers,
Johannes
--
*Dr. Johannes Koch*
*Tissue Med Biosciences GmbH*
Magnesitstrasse1 | A-3500 Krems
T: +43/2732/87470-300 | M:
[hidden email]
<mailto:
[hidden email]>
*www.tmbiosciences.com <
http://www.tmbiosciences.com/>*
Diese E-Mail enthält vertrauliche und/oder rechtlich geschützte
Information. Wenn Sie nicht der richtige Adressat sind oder diese E-Mail
irrtümlich erhalten haben, informieren Sie bitte unverzüglich den
Absender und vernichten Sie diese E-Mail sofort. Das unerlaubte Kopieren
sowie die unbefugte Weitergabe dieser E-Mail sind nicht gestattet.
This e-mail may contain confidential and/or privileged information. If
you are not the intended recipient or have received this e-mail in error
please notify the sender immediately and destroy this e-mail. Any
unauthorized copying, disclosure or distribution of the material in this
e-mail is strictly forbidden.
--
ImageJ mailing list:
http://imagej.nih.gov/ij/list.html