A problem with Thresholding!


#1

Hello all,

I am facing a problem with thresholding while I am using Imagej. I am analyzing 2160 images as one stack. I usually divide them as 3 groups (720 images / each group) but this time I got three different values for threshloding (converting images to Black and white). Is any one has any idea why I got this?

Best Regards,
Mayy


#2

Dear @Mayy,

welcome to the forum! :slight_smile:

Could you please be more precise about the steps that you have taken and, if possible, provide a small sample stack

It sounds like you are applying an automated threshold to the images, which (in most cases) depends on the image composition. Does the overall appearance of the images change between the classes (i.e. what makes them different classes)?

Best,
Stefan


#3

Hello Stefan,

I am so sorry for late response!

I am working on images for bones that are taken by using SR CT
They are 2160 images for one stack to avoid so many crashes I divide each stack to 3 groups (720 per each group).

  1. I insert 720 by using ( File image sequence) I repeat this step for each group(720 images) to end up with three windows on my screen for the whole 3 groups.

  2. Image-> Adjustment-> Brightness / contrast for each group and I write-down the values for each group. Then, I choose a range to make sure I am involving everything, this range is the mini. Of the maxi. And the maxi. Of the mini.
    After that, I reset all groups to have the same values by click reset.

  3. Converting each of 3 groups to 8 bits and saving them

  4. Then, Press Image-> Adjust-> Thresholding and I usually check all groups to have the same values Rest Apply with marking Dark background box
    The problem is here, that each group has a different Thresholding value, even they are considered as a one stack


#4

Regarding thresholding: I usually choose Default Red to make sure that I am getting all my bone and then I change to Default B & W and marking Dark Background


#5

When you are selecting the Default option in Image > Adjust > Threshold the threshold value is computed automatically based on the image histogram of the currently active slice of your stack. You will notice the latter when you close the Threshold window, change to a different slice in your stack and reopen the Threshold: the value will (most likely) have changed.

If you really want to set the same threshold for all the groups, is specifing it manually an option? When you click the Set button in the Threshold window, you enter values that are used for thresholding (see https://imagej.nih.gov/ij/docs/guide/146-28.html#sub:Threshold…[T] for a more detailed explanation).

Also, take a look at this page on the ImageJ wiki - it might be useful: