University of California, San Diego



Homework 3For all of the Matlab problems, give your Matlab commands as well as showing image results.Using Matlab, read in the retinal image with the command:P1 = imread(‘retina1.tif’);Display the image. You should see a retinal image containing blood vessels and a circular yellow disk at the right side. Let’s call the blood vessels Obj1 and the circular yellow disk Obj2. The rest of the image consists of black background, which we will ignore, and orange-colored tissue, which we will refer to as background. Following the same procedure, read in ‘retina2.tif’ and ‘retina3.tif’; store these images in P2 and P3, respectively. In this homework, we will locate Obj2 in every image. Convert the color image P1 into grayscale image with the following command:bw = rgb2gray(P1);Compute the histogram of the grayscale image. As we will not be considering the black pixels surrounding the retina, only consider the pixel values ranging from 51 to 255. Based on the histogram, try to find a threshold above which all the pixel values belong to Obj2. Display only those pixels having value greater than the threshold. Repeat the same procedure for P2 and P3. Is it possible to find a threshold for every image that cleanly segments the images into the desired regions? Does the same threshold works for all the images? If not, explain why.Perform 3x3 Sobel edge filtering on P1 to produce a binary edge map. You can use the Matlab built-in function edge() for this purpose. Look at the binary edge map while varying the threshold. What threshold would you say corresponds to a reliable binary edge map, in which almost every 1-pixel corresponds to the proper edge of Obj1 and Obj2? Next, perform same operations on P2 and P3. Does the same threshold work for all the three images to produce reliable edge maps of Obj1 and Obj2? Why or why not?The edge map of problem 2 contains both Obj1 and Obj2. Design a method to separate these two objects. Your method should produce two separate edge maps: one consisting of only Obj1, and the other consisting of only Obj2. We will call these edge maps E1 and E2 respectively. Use E2 to segment the grayscale image to produce an image showing only Obj2. Compare your edge-based segmentation performance with that of problem 1. [Hint: you can use morphological operations to get the segmentation mask from edge map.]For this part we will only consider P2. We would like to find line segments in E1 that you have obtained from P2. Perform a Hough transform on E1 to find the strongest 5 lines of E1, and draw the lines on grayscale image P2. Do the lines accurately represent the blood vessels of Obj1? Add 15% salt and pepper noise to E1 and find the strongest 5 lines again. How well does Hough Transform perform amidst noise? What effect does the noise have on the Hough lines? ................
................

In order to avoid copyright disputes, this page is only a partial summary.

Google Online Preview   Download