Posted by
Chris Tully on
URL: http://confocal-microscopy-list.275.s1.nabble.com/Auotmatic-thresholding-tp3130613p3130713.html
Disclaimer: Although I no longer work for Media Cybernetics or any of their dealerships, I have worked for Media Cybernetics and two of their dealers in the past, in addition to using Image-Pro Plus in my own research.
Image-Pro Plus' (IPP) automatic threshold is based on the theory that the image is a roughly bimodal distribution of pixels between object and back ground. There is no requirement that their be equal numbers of pixels in each class, I have seen the algorithm work on images that have very few (> 10% of pixels in one class). However, I have also seen it fail on images that to my eye have a beautifully bimodal histogram... With that said I have been doing microscopy and image analysis for myself and customers since 1992 and have always noticed that manual thresholding is highly variable by user and by processing methods (e.g. a slightly stronger contrast setting one day than the next). With that in mind I alway urge a client to try the auto threshold first. If it works, great! If not, then we need to look at how and why it failed. One of the most common causes of failure is a non-uniform background. To address this, IPP offers two options:
1) The Flatten Background filter (Process|Filters...|Enhance|Flatten or Image|Flatten Background from the Count?size dialog's menu bar). This filter attempts to derive a background from the image itself by reducing and massively smoothing the image to remove objects and then enlarging the result to the image's original size. This is then used as the background image in a Background Correction operation (see Process|Background Correction...|Background Correction). This will work well on some images (e.g. the Spots.tif sample image) and not so well on others. In any case it may be the only choice if you have not captured a background image.
2) Background Correction (Process|Background Correction...) This dialog offers two methods Background Correction and Background Subtraction. See Help for the exact equations used in each method. Background Correction is the most relevant to most failures of Auto Threshold. To capture the background, first focus on your sample and then find a field of view on the coverslip that is free of sample and dust, but does have mounting medium. Do not defcous if you can avoid it - doing so can lead to artifacts in the corrected image.
If Background Correction (either method) helps, then you are golden. If not it is instructive to test auto thresholding on several images (at least 10-20) both as acquired and background corrected. You want to look at two things:
1) Does background correction alter the mode of failure? Or is the failure on corrected images less acute?
2) In either case (as acquired or corrected) is the failure consistent across all or most of the test images?
You may conclude that it is worth while to go back and acquire new images with backgrounds (keep in mind that the background images is highly dependent on lighting conditions [lamp voltage and iris settings], and so really should be captured at the same time, or at least in the same session as the sample images).
Another possibility is that the knowledge obtained from the above activities and your previous work manually thresholding images will give you enough knowledge about your samples and images to develop a specialized automatic thresholding macro. In particular, you really have to carefully document the manual enhancements you use for each image and the thought process that goes into each manual threshold. There is a reasonable probability that with a little bit of thought about your acquisition methods and your enhancement and analysis methods that you can come up with an automatible process.
If you would like to discuss this in further detail, please feel free to contact me directly.
Getting back to your original comments, I understand that it is not always possible to capture images with consistent settings, but I would urge you to carefully examine your acquisition methods. Anything that you can do to improve the consistency of your acquisition methods will go a long way towards simplifying your analysis tasks. Variations in magnification should not have any significant effect on the ability of IPP's auto threshold to pick out objects.
Chris Tully
Microscopy and Image Analysis Expert
[hidden email]240-888-1021
http://www.linkedin.com/in/christully
On Sun, Jun 21, 2009 at 9:28 PM, Elizabeth Nickless
<[hidden email]> wrote:
I have a question regarding thresholding. Do users have much success with automatic thresholding of samples? We have Image Pro Plus and anlayse samples with variable size ranges and signal intensities. We manually threshold very carefully with enhancement features but it would be nice for this to be done automatically with a robust method but I am not sure how to do this and be confident with the results.
DISCLAIMER:
This email contains confidential information and may be legally privileged. If you are not the intended recipient or have received this email in error, please notify the sender immediately and destroy this email.
You may not use, disclose or copy this email or its attachments in any way.
Any opinions expressed in this email are those of the author and are not necessarily those of the Fonterra Co-operative Group.
http://www.fonterra.com/