Analysis of diffuse and uneven muscle staining


Dear all,

My work is to fibertype muscle sections using immunofluorescence. This is what I stained for: Blue for the edges of individual fibers, green for a specific type of fibers (type IIa) and red for type IIb fibers. The attached figures were obtained using TileScan functions (several pictures joined together) for Blue. For Green and Red figures I uploaded only the individual images.

My pipeline works well when identify the individual number of fibers (Blue image) but sometimes individual fibers are splited into 2. I should have overcome this using MaskImage but the problem remains. Overall this is not a major issue as I can refine the staining or obtained a better picture quality. This pipeline attached was done for this purpose.

When I try to identify objects manually or corrected those that were split, the coloured edges of the object does not come out. The only available option is to press F. Please, let me know what I am doing wrong.

Individual fibers may either be positive to green, red or both. When positive to both colours they may colocalise or not. The staining for green or red is diffuse and fibers present different intensity to the staining. Some are very bright while other do not. Inside the fiber types, they also differ in their morphology. Furthermore, the green or red staining may or may not cover the complete size of the fiber.

Please, I’d like you to help me with:

The pictures need to be in high quality and be analysed as a total. The issue is that they are very heavy (100Mb) and the processing takes time. I tried reducing the quality or rescale but does not work properly. When I save the images in PNG I do not get the same quantification of fibers. What else could I do?
As I have the total number of fibers and their properties (size, etc), I want to have the same for the green, red and those positive for both. The segmentation of each of them is not proper as you can see if look at the blue channel.
Please note that the pipeline attach is for the Blue channel of the Tilescan no for the individual images, which have the red and green colour. If provide me an email I will send the TIFF image of the Tilescan.Or you may suggest how to do it with the images attach and I modify the diameter.

I sincerely hope you can give me some clues.

Best regards,

Practise34_julian_Tile_scan.cpproj (426.2 KB)


Hello there,

Can you grant us the access to your images, I currently don’t have permission to view it yet.



Dear Minh,

You have access now. Thanks in advance.Alan



The high resolution of the image is quite impressive ! But it indeed makes every test run a lengthy one.

I suggest to try the following steps:

You may have to tune the smoothing size and distance between local maxima to solve undersegmentation / oversegmentation
The huge image size really makes this tuning difficult though…

Here is the demonstrating pipeline musclefibers.cpproj (645.7 KB)

Good luck

Issues with muscle fiber histology analysis
Possible to Identify Objects Within Tertiary Object

:clap: very nice! I think this pipeline neatly demonstrates the utility of masking, and the occasional need to invert an image to take advantage of the watershed algorithm.

Since the image is so big I wonder if you’d see any performance boost by down-sampling the image, processing it, and than resizing the binary image that would then become the mask of the full size image.


Downsampling and resizing the mask is a neat idea ! Thanks Kyle !


Dear Minh,

The pipeline works perfectly fine but I wonder how you got some of the manual values (May be it is just practise !!!). Also, I run your pipeline and it gave me 4104 acepted objects not 4204 as you showed there. I may play a little bit though. You have helped me a lot to identify each fiber´s edge. Thanks a lot for that.

So, going back to one of initial questions about the staining of individual fibers. As you may see in the pics attached, how can I segmentate each individual fiber that is positive for both green and red staining but do not colocalise?

Best regards and sorry for the delay in my reply.




I guess you mean the “manual values” as those parameters for segmentation? Yes, I think we all just need to play around with different values to come down to a good one.

Regarding red and green: I suggest to do an ImageMath in which you add Red and Green channels together, to form a new “Sum” channel.
This “Sum” channel will be then used as the signal for segmentation fibers. This way, any resultant segmented fiber objects will has at least Red or green signal, no mater they are overlapped or not.
You then add all necessary measurements for these segmented objects, e.g. MeasureObjectIntensity, MeasureObjectSizeShape, MeasureTexture and MeasureCorrelation , in which you choose the images to measure to be original Red and original Green channels.

I imagine that in the end, if you plot a 2-D plot for these objects, with X axis = ratio Red intensity/Green intensity, Y axis for Area, you will see that:

  • A fiber that has both Red and Green, they will be near center, on X axis
  • A fiber that has more Red will be on the right side, on X axis
  • A fiber that has more Green will be closer to 0, on X axis.

You can even do 3-D plot with at least 1 axis with this ratio, and 2 other axes for e.g. area and texture… to see what comes out.

Hope it helps.


Ok I´ll try this. Thanks for your help I really appreciate it. Alan