|[mmdfabric] [Up] [mmdflatzone]||Demonstrations|
This procedure extracts the filarial worms from a complex microscopic image by eliminating progressively the other objects present in the image. The selection of the structures begins in the gray-scale level and, after a threshold, continues based on the object geometrical properties.
A microscopic gray-scale image, with two filarial worms, is read.
a = mmreadgray('danaus.tif');
The Close by Reconstruction Top-Hat operator is applied to regularize the image background.
b = mmcloserecth(a,mmsebox(5));
The gray-scale opening by the elementary cross is applied to remove narrow objects.
c = mmopen(b);
The gray-scale area open operator is applied to remove small objects.
d = mmareaopen(c,200);
The threshold operator is applied to extract a reduced set of structures that include the two worms present in the image.
e = mmthreshad(d,50);
Warning: converting image from scalar to uint8
The objective of the sequence of transformations, that begin with the homotopic skeleton, is to eliminateg the structures that are not worms. The information used for the filtering is that the worms are longer than any other structure found.
f = mmthin(e);
The first 12 points of the skeleton branches, counting from their extremities, are eliminated. The structures that were not eliminated will be the markers for extracting the two worms.
g = mmthin(f,mmendpoints, 12);
The binary reconstruction operator is applied to reconstruct the binary image produced by the threshold from the marker image.
h = mminfrec(g,e);
The structures extracted are overlaid to the input gray-scale image.
|[mmdfabric] [Up] [mmdflatzone]|
|Copyright (c) 1998-2008 by SDC Information Systems|