Presentation is loading. Please wait.

Presentation is loading. Please wait.

CS 376b Introduction to Computer Vision 03 / 26 / 2008 Instructor: Michael Eckmann.

Similar presentations


Presentation on theme: "CS 376b Introduction to Computer Vision 03 / 26 / 2008 Instructor: Michael Eckmann."— Presentation transcript:

1 CS 376b Introduction to Computer Vision 03 / 26 / 2008 Instructor: Michael Eckmann

2 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Today’s Topics Comments/Questions A few C++ issues that came up yesterday More texture measures –co-occurrence matrices and the features generated from them –Laws texture energy measures

3 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 C++ issues floating point absolute value is fabs(), integer absolute value is abs()‏ array elements are not automatically initialized to 0's accessing/changing elements out of bounds on a 2d array (image) altered the values of nearby declared variables –no error at compile time –runtime error – crash --> segmentation fault

4 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Co-occurrence matrix A co-occurrence matrix C has as its row and column indices, image values (e.g. intensities for greyscale or RGB values for color)‏ The value of C(i,j) is the number of times image value i occurs with image value j (in some predefined spatial relationship). example on the board for a couple of spatial relationships This spatial relationship is specified as a displacement vector d which contains 2 values --- the displacement in rows and the displacement in columns.

5 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Co-occurrence matrix figure from Shapiro and Stockman “Computer Vision”

6 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Co-occurrence matrix A word of warning --- the text speaks of C d [i,j] as an element of the co-occurrence matrix and also speaks about C [0,1] etc. –Note: d is a displacement vector and when we have C [0,1] [0,1] is that displacement vector. Let's do part of exercise 7.4

7 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Co-occurrence matrix What we've just defined and used were the standard gray-tone co-occurrence matrices. Two variations on these matrices are –Normalized co-occurrence matrix co-occurrence values now lie in [0,1] take a guess as to how you'd normalize the matrix see equation 7.5 –Symmetric co-occurrence matrix groups pairs of symmetric adjacencies see equation 7.6

8 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Co-occurrence matrix The co-occurrence matrices themselves aren't useful to compare to determine if two textures are similar. Instead, there are five numeric features computed on the co- occurrence matrices that are listed on page 219 Put these 5 values in a vector and compare 2 vectors with a distance measure (e.g. L1)‏

9 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Co-occurrence matrix Notice that when creating a co-occurrence matrix, one needs to decide on the displacement vector (how many rows away and how many columns away)‏ How to choose the best displacement vector to yield the most structure in your co-occurrence matrix? –maximize a chi-squared statistical measure (see page 220)‏

10 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Laws Texture Energy Measures L5 (level) = [ 1 4 6 4 1] E5 (edge) = [ -1 -2 0 2 1] S5 (spot) = [ -1 0 2 0 -1] R5 (ripple) = [ 1 -4 6 -4 1] can create 16 masks from these by using cross product –L5L5 –L5E5 –L5S5 –L5R5 –E5L5 –... –R5R5

11 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Laws Texture Energy Measures Laws procedure: –remove illumination effects by a small window around the image and subtract the local average from each pixel results in an image that has an avg intensity of near 0. –convolve each of the 16 masks generated from those 4 vectors (L5,S5,R5,E5) to get 16 filtered images F k –compute 16 texture energy maps E k, one from each of the 16 filtered images F k (see equation 7.12)‏ –Symmetric pairs of energy maps are averaged together. End up with nine energy maps. (not sure why L5L5 is not in the list, and making 10 energy maps)‏

12 Michael Eckmann - Skidmore College - CS 376b - Spring 2008 Laws Texture Energy Measures Laws procedure: –Final result is 9 energy map images. One can consider the mean value of each energy map to generate 9 values (see table 7.1)‏ –These 9 values can be considered as a vector which can be used to compare two images using a distance measure (e.g. L1)‏ –One can segment an image into regions of like texture by using a segmentation scheme that either segments by clustering like textures or finding boundaries between different textures covered in chapter 10.


Download ppt "CS 376b Introduction to Computer Vision 03 / 26 / 2008 Instructor: Michael Eckmann."

Similar presentations


Ads by Google