Assignment 3-Texture & Shape

DUE: 4.1.2001


TEXTURE

Texture is usually related to a repetition of a basic pattern in an image. It is an important characteristic of many images, and may contain more information than color (or gray-levels) features. However, there is no precise mathematical definition of texture, and many approaches have been suggested for its characterization.

 

I.)

In this Assignment, we focus on texture analysis using Co-occurrence matrices. We investigate features extracted from the matrices, as possible characterization of the textures:

Part I - coding co-occurrence m-function

Code a Matlab function that calculates the co-occurrence matrix:

Building the co-occurrence matrix P is done by computing for each pair of gray-levels (usually 0-255), the number of adjecent pixels that hold this pair in the image, for different directions and distances.

For image of size MxN, for distance d=1pixel, in the horizontal direction, the co-occurrence matrix P will be defined as follows:

where i,j=0. . . 255, (number of possible gray-levels), k,m=1 . . . M (image width), l,n=1 . . . N (image height).
 
 

Input arguments:

A two dimensional matrix X, containing the gray-level values of an image.

The distance d for the co-occurrence calculations.

Output argument:

A 256*256 co-occurrence matrix P, summed on all directions.
 
 

Part II - Building Feature space for a training set

 
where  are the co-occurrence matrix entries,  is the mean gray-level, and  is the gray-level variance.
Part III - Metrics and Retrieval


II.)

   A. Obtain the gray-level co-occurrence matrix (GLCM)  of a 5 x 5 image of
        alternating 1’s and 0’s. Top left pixel has a value 0.
       (a) d = 1 pixel to the right
       (b) d = 2 pixels to the right.

    B.  Explain the following observation:

  SHAPE

I.)   (a)   Show that redefining the starting point of a chain code so that the resulting  sequence of numbers
        forms an integer of minimum magnitude makes the code independent of the initial starting point on the boundary.
        (b)   Find the normalized starting point of the code 11076765543322.
        (c) Show that the first difference of a chain code normalizes it to rotation.
        (d) Compute the 1st difference of the code 0101030303323232212111.
 

II.)     Find the Euler number of the characters: 0, 1, 8, 9, X.