[ImageJ-bugs] [Bug 938] Bug in the Intermodes algorithm of threshold
bugzilla at fiji.sc
bugzilla at fiji.sc
Fri Oct 3 16:00:33 CDT 2014
http://fiji.sc/bugzilla/show_bug.cgi?id=938
G. Landini <g.landini at bham.ac.uk> changed:
What |Removed |Added
----------------------------------------------------------------------------
Status|NEEDSINFO |RESOLVED
Resolution|--- |INVALID
--- Comment #3 from G. Landini <g.landini at bham.ac.uk> ---
Hi, just a quick update. The Intermodes threshold method 'fails' in the 16bit
image because the histogram is not bimodal. The value of 525 is just the min
value of the image-1. I do not consider this is a bug because the plugin
explains the situation in the Log window.
Now, about the issue of with why this works differently with the
Adjust>Threshod command. I am almost sure that this is because that command
packs the 16bit histogram into an 8 bit space (i.e. 256 bins) and thresholds
that histogram. You get the 'correct' result by converting the image to 8 bits
and using the Auto_Threshold plugin Intermodes method (if you do it you will
find that the binary result is identical on that neuron image).
A bit counter-intuitive, but a 16bit image and the same converted to 8 bits are
not the same, and we should not expect the same result for all the methods.
I am marking this as "Invalid" as I do not think there is a bug, just a
confusing situation, but please feel free to reopen if you think otherwise.
By the way, the issue raised about line 199, I think it is correct as is. The
histogram is sequentially, so this has to be done on the the same array.
One more thing, I could add to the code to return "-1" if the method fails. Now
it returns the minimum grey value of the histogram-1. Not sure if that makes it
any clear; suggestions are welcome.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://imagej.net/pipermail/imagej-bugs/attachments/20141003/1f948d03/attachment.html>
More information about the Imagej-bugs
mailing list