CorrectIllumination_Calculate questions


#1

Hello,

I have been trying to implement the ‘CorrectIllumination_Calculate’ module in my pipeline. So far I have been unable to produce a satisfactory illumination correction function, and am trying to figure out why. I have a few questions about this module which I would greatly appreciate answers to (I have read the manual and the scientific articles also).

The following questions concern the various options for CorrectIllumination_Calculate:

For REGULAR INTENSITY: If the incoming images are binary …
Am I correct to assume that this setting is used only as a specialized method for binary images? That is, for my grayscale images, I would not use this setting?

For MEDIAN FILTER or GAUSSIAN FILTER …
If I am using the ‘Regular’ option, then I imagine that I need to smooth out the actual cell structures in the image. Therefore should I enter the approximate cell width in pixels here?

If you want override the above width of artifacts …
I am curious how this setting differs from the one above.

Some general questions:

  1. In the 2008 article by Vokes and Carpenter (Current Protocols in Molecular Biology), there is a description of the CorrectIllumination_Calculate module on page 12. Reference is made here to the ‘smoothing size’. Would this correspond to the median/Gaussian filter setting? Also it is stated that the ‘smoothing size’ is set automatically and displayed in the figure window. I would like to know which window (and where) the smoothing size can be found.

  2. I have experimented on a single image with about 100 cells. Is it feasible to create a workable smoothing function using the ‘Background’ method for a single image? (Segmentation using ‘IdentifySecondary’ indicates that 34.1% of the image consists of object). When I try to use this method, the illumination correction function resembles a blurred version of the original image of cells for some reason. Would it be feasible to create a workable smoothing function on this image using the ‘Regular’ option and appropriate smoothing (so far I have been unable to produce a sufficiently smooth correction function)? … any pointers would be welcome.

  3. In the CorrectIllumination_Calculate Display window, a ‘Min Value’ and ‘Max Value’ is listed. I would like to know if possible what these values correspond to.

Thanks very much,

Ernest


#2

Hi Ernest,

Yes, the settings in CorrectIllumCalc can be pretty confusing- we’re definitely working on this!

[quote]
Am I correct to assume that this setting is used only as a specialized method for binary images? That is, for my grayscale images, I would not use this setting?[/quote]

Actually, this setting will not break if you use it on a grayscale image; it does what it says it does, which is dilating each object before averaging the images (which is really all ‘Regular’ is, if you don’t do any smoothing- averaging your images).

[quote]If I am using the ‘Regular’ option, then I imagine that I need to smooth out the actual cell structures in the image. Therefore should I enter the approximate cell width in pixels here?

If you want override the above width of artifacts …
I am curious how this setting differs from the one above.[/quote]

You are correct- when you enter the artifact width, that’s the same as setting the filter size. In reality, the settings are not used any differently in the code- we’re aware this is confusing and we’ve taken this into consideration in upcoming releases.

In general:

When using Regular, if you don’t smooth, all you’re doing is averaging together your images. Regular is usually a good option if you think that most of your image is foreground, and the illumination pattern in the foreground is representative (for example, if the cells at the edges always look dimmer than the ones in the middle). Averaging together your images (the ALL option) and then smoothing with a filter will generate a function that then represents this foreground illumination pattern and allows you to correct for it. Regular + EACH is a less robust, since if you didn’t do any smoothing this would be your original image! You want the illumination function to look like the actual pattern of illumination, not like the distribution of your cells. Generally with Regular, you rescale the function so it’s greater than 1, and select ‘Divide’ in the CorrectIllumApply.

When using Background, the module calculates the minimum pixel value in a block of size X (where X is what you enter under 'Enter the block size, which should be large enough…) and uses this as the illumination function (plus any smoothing). If you select ‘Each’ in this case, as you’d expect, this minimum calculation is just for one image; while ‘ALL’ cycles through your images to determine the minimum pixel value in some block size X for the whole set of images. What you end up with is the background level that you can ‘Subtract’ (in CorrectIllumApply) - so you don’t necessarily want to rescale. Background really doesn’t work if most of your image is foreground- because the minimum pixel value in any neighborhood that contains only foreground will be foreground.

These values correspond to min and max values in the illumination correction function, to let you get an idea of how severe the correction was.

To create a smoother function, try using a larger filter size, and selecting ‘All’ rather than ‘Each’. We usually recommend median filtering, though FitPolynomial will give the smoothest function. Illumination correction is definitely very tricky, so it may take some work to get a good function.

~kate


Illumination correction
#3

Hello Kate,
Thank you very much for all the prompt and helpful clarifications.
Best,

  • Ernest

#4

Reading this post has been helpful. I have a specific question:

The illumination function is in the form of a .mat file.
Do the values of this image represent absolute numbers (which are subtracted from the sample images), or are they fractional/ percent values?