Digital Image Processing - Practice Homework 1 | COSC 4393, Assignments of Digital Signal Processing

Material Type: Assignment; Class: Digital Image Processing; Subject: (Computer Science); University: University of Houston; Term: Fall 2008;

Typology: Assignments

Pre 2010

Uploaded on 08/17/2009

koofers-user-9vh-1
koofers-user-9vh-1 🇺🇸

10 documents

1 / 2

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
COSC 4393/6380
Digital Image Processing
Department of Computer Science
University of Houston
Assignment #1
Due: 10/14/08
1. Write a program to binarize a gray-level image based on the assumption that the
image has a bimodal histogram. You are to implement a method that assumes
that both the foreground and background regions of the image represent a
Gaussian distribution and the optimal threshold to binarize the image is the
average of the means of the two Gaussians. Your code should report both the
binarized image and the optimal threshold value. Assume that foreground takes a
value of 1 and the background a value of 0 in the binary image. Also assume that
foreground objects are darker than background objects in the input gray-level
image.
2. Write to program to perform morphological smoothing of the resultant binarized
image. Include both Open-Close and Close-Open smoothing operations using a
windowing function that is a 3 x 3 window and a 5 x 5 window. The input to your
code would be a binary image and the output would be a smoothed version that
eliminates small regions and fills holes of larger regions.
3. Write a program to perform blobcoloring based on both a 4-connected and a 8-
connected neighborhood (3 x 3 window). The input to your code should be a
binary image from the previous step and the output should be a count of total
objects in the image as well as the labeled image where each object is color coded
starting with the value of 1 and the background taking a value of 0. Assume that
objects in the binary image take a value of 1 while the background takes a value
of 0. In addition, your code should also report the area and centroid of each
object in the binary image.
4. Write a main program to read in the supplied gray-level image (‘cells.png’) and
threshold the image to generate a binary image using the function developed in
part 1. Next, use morphological operations to eliminate small regions and fill
holes in larger regions. Finally, use the blobcoloring function developed in part 3
to count the number of cells in the image and report on their statistics. Ignore
cells smaller than 15 pixels in area and generate a report of the remaining cells
(Cell Number, Area, Location, Total Count). In addition, display the original
input image, the binary image, the smoothed image, and the final cell labeled
image. The final image should use a distinct color to represent each uniquely
labeled cell.
pf2

Partial preview of the text

Download Digital Image Processing - Practice Homework 1 | COSC 4393 and more Assignments Digital Signal Processing in PDF only on Docsity!

COSC 4393/

Digital Image Processing

Department of Computer Science

University of Houston

Assignment

Due: 10/14/

  1. Write a program to binarize a gray-level image based on the assumption that the image has a bimodal histogram. You are to implement a method that assumes that both the foreground and background regions of the image represent a Gaussian distribution and the optimal threshold to binarize the image is the average of the means of the two Gaussians. Your code should report both the binarized image and the optimal threshold value. Assume that foreground takes a value of 1 and the background a value of 0 in the binary image. Also assume that foreground objects are darker than background objects in the input gray-level image.
  2. Write to program to perform morphological smoothing of the resultant binarized image. Include both Open-Close and Close-Open smoothing operations using a windowing function that is a 3 x 3 window and a 5 x 5 window. The input to your code would be a binary image and the output would be a smoothed version that eliminates small regions and fills holes of larger regions.
  3. Write a program to perform blobcoloring based on both a 4-connected and a 8- connected neighborhood (3 x 3 window). The input to your code should be a binary image from the previous step and the output should be a count of total objects in the image as well as the labeled image where each object is color coded starting with the value of 1 and the background taking a value of 0. Assume that objects in the binary image take a value of 1 while the background takes a value of 0. In addition, your code should also report the area and centroid of each object in the binary image.
  4. Write a main program to read in the supplied gray-level image (‘cells.png’) and threshold the image to generate a binary image using the function developed in part 1. Next, use morphological operations to eliminate small regions and fill holes in larger regions. Finally, use the blobcoloring function developed in part 3 to count the number of cells in the image and report on their statistics. Ignore cells smaller than 15 pixels in area and generate a report of the remaining cells (Cell Number, Area, Location, Total Count). In addition, display the original input image, the binary image, the smoothed image, and the final cell labeled image. The final image should use a distinct color to represent each uniquely labeled cell.