3
$\begingroup$

Consider a texture mixture (img) from Brodatz.

enter image description here

I want to classify the five different texture patterns and segment the corresponding regions.

Following this,

I tried to classify the data in the way mentioned below:

gaborMagnitude[image_, r_, k_] := 
 With[{data = ImageData[image]}, 
  Image[GaborFilter[data, r, k, 0]^2 + 
    GaborFilter[data, r, k, Pi/2]^2]]

Manipulate[
 {t1, t2, t3, t4} = 
  Table[ImageAdjust@
    gaborMagnitude[i, 
     r, \[Lambda] k], {k, {{0, 1}, {1, 1}, {1, 0}, {-1, 1}}}];
 ImageCompose[
  i, {ImageAdd @@ 
    MapThread[
     ImageMultiply[MorphologicalBinarize[#1], #2] &, {{t1, t2, t3, 
       t4}, {Red, Green, Blue, Yellow}}], x}], {\[Lambda], -5, 5}, {r,
   1, 20, 1}, {x, 0, 1}]

Even with different settings of the parameters, I don't get the desired result. This classifies the edges with different orientations. However, in the given image, a single texton is composed of edges with multiple orientations.

How can I classify the 5 textures present in the image using GaborFilter or any Wavelet based technique or any unsupervised texture classification technique for that matter?

$\endgroup$
  • $\begingroup$ You should add how your import the image (e.g. i = ColorConvert[Import["https://i.stack.imgur.com/ZOlbj.jpg"], "Grayscale"]). Playing with Manipulate, I'd say for a start you should be able to extract 3 textures: the center, top-bottom, left-right. $\endgroup$ – anderstood Mar 14 '18 at 15:33
  • $\begingroup$ There is no built-in net decoder for image segmentation $\endgroup$ – M.R. Mar 18 '18 at 22:15

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.