Different outputs for ImageJ 1.38x and 1.37v with "Make Binary" command

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

Different outputs for ImageJ 1.38x and 1.37v with "Make Binary" command

Nilesh Powar
Hi,
 
I had written some code in Imagej 1.37v, one of the commands was to "Make Binary" and it used to work fine, But in the new version of 1.38x, the same command yields different results. The image is changed into Inverting LUT and is not same as before.
 
Why does the image has the inverting LUT when i don't even ask for it? When I did set the black background in the options menu, the inverting LUT goes away, but the image seems to be inverted as compared to the result of Make Binary from imagej 1.37v.
 
Is there a good solution where the new imageJ version would produce the same result as the old imagej version for the Make Binary command???
 
Thanks,
Nilesh.
 
 
Reply | Threaded
Open this post in threaded view
|

Re: Different outputs for ImageJ 1.38x and 1.37v with "Make Binary" command

Wayne Rasband
> I had written some code in Imagej 1.37v, one of the commands was to
> "Make Binary" and it used to work fine, But in the new version of
> 1.38x, the same command yields different results. The image is changed
> into Inverting LUT and is not same as before.
>  
> Why does the image has the inverting LUT when i don't even ask for it?
> When I did set the black background in the options menu, the inverting
> LUT goes away, but the image seems to be inverted as compared to the
> result of Make Binary from imagej 1.37v.
>  
> Is there a good solution where the new imageJ version would produce
> the same result as the old imagej version for the Make Binary
> command???

This macro works like the Make Binary command in ImageJ 1.37v. It
creates black objects on a white background, with no inverting lookup
table and background pixel values of 255. Newer versions of ImageJ use
an inverting lookup table so that background values are zero.

     run("Options...", "iterations=1 count=1");
     run("Make Binary");
     run("Invert");
     run("Invert LUT");

You can create a "Make Binary Like v1.37" command by saving this macro
in the plugins folder as "Make_Binary_Like_v1.37.txt" and restarting
ImageJ.

-wayne