# Good inhomogenity measures in images?

Can you advise me on good inhomogenity measurements in an image? I am trying to find the borders where homogenous zones touch inhomogenous ones in a image.

I am going to work with sick lung ct images like this:

I am looking for different ways to measure inhomogenity in the texture in the image.

Thank you

• Can you add an example image? – Vertex Apr 1 '15 at 17:49

The variance is a good inhomogenity measure. For example, take 20*20 patches and calculate the empirical variance of the patch using these 400 samples. For very simple purpose, this could work.

Edit : After viewing your example images, try to just play around with simple tools like manual thresolding and edge detection.

Edit 2: Added Example with different patch sizes (40, 10, 2)

• Thankyou for taking the time to make a result image. Thing is, I already know where the lungs are, I am not trying to segment them but characterize their texture. So I am looking for a mesure to analize the lung texture and find its inhomogenity – Zloy Smiertniy Apr 6 '15 at 17:33
• Then start looking at the inhomogenity in the grey level distribution, let's discard any spatial correlation analysis. You should display the pixel's gray level histogram and look at the distribution. Variance would give an insight on the distribution's spreads and would suit very well your analysis if the distribution is gaussian. If it is not, you can try more advanced modelisation tool like a gaussian mixture model and estimate it's parameter using expectation-maximisation, k-mean etc ... – Antoine Bassoul Apr 7 '15 at 8:04

Another good texture measure would be gray-level co-occurence matrix, which is implemented in Matlab as graycomatrix. By the way, in your case a simple Otsu threshold might do the trick as well.