Differences in Image Histograms for ImageThreshold on 16bit Images
jjweimer
I have a 16bit image.
I can generate an image histogram with ImageHistogram/I. This gives a histogram of 65536 points. I can also generate an image histogram with ImageHistogram (no /I flag). This gives a histogram of 256 points.
When I run ImageThreshold/M=7 on the image, the threshold value returned is 812. The histogram in the display runs to just beyond 2000. This histogram result does not fit with the 8bit or 16bit histogram generated by ImageHistogram.
What histogram calculation is used on 16bit images prior to running the ImageThreshold operation? How can I repeat that same histogram calculation using ImageHistogram by itself.
OK. I see what is happening. ImageHistogram without the /I flag creates a 256 bin histogram regardless of the image bit size. ImageThreshold uses the same 256 bin histogram.
The better question is whether ImageThreshold can eventually be updated to support analysis of a 16bit image with 65536 bins?
FWIW, the histogram operation in Fiji (the ImageJ2 software) creates a 256 bin histogram of the 16bit image. So, IgorPro is consistent.
July 12, 2019 at 08:27 am - Permalink