1 Some directions and helpful hints on how to work with the region extraction/
\r
2 shape classification system.
\r
5 - region comparison now gives additional info, i.e. ratios of areas,
\r
6 volumes, and average intensities.
\r
7 - pixels are now removed according to regions, not to colors.
\r
8 - labeling of the image is now possible. Please read below under "place a label"
\r
9 - it is possible to change colors of regions ("Region" menu, "Color" submenu).
\r
10 - it is now possible to pick regions not from their lists but by simply
\r
11 clicking and using "(un)select 1-st/2-nd region". This is equivalent to
\r
12 using the pop-up menus which remain.
\r
13 - lines with which the region boundaries are drawn could be made thinner
\r
14 and thicker ("Region" menu, "Thin next line"/"Thicken next line" submenus).
\r
15 - images are now saved in "low" and "high" quality formats - with different
\r
16 resolutions and sizes of files.
\r
19 - To start the system: type in "Biomed_demo" at Matlab prompt.
\r
21 - To read in an image: "Image" menu "Open" submenu ("Alt-I" and "Alt-O", or
\r
22 "Ctrl-O") either in the start window or in any window containing an image.
\r
23 In any case the image will appear in a separate window, not overwriting an
\r
24 existing image. Currently only "tiff", "jpeg", and "bmp" formats are supported.
\r
25 It is preferrable to crop the part of the image you will work with first in
\r
26 some other editor, as Matlab seems to take much memory to process it when
\r
27 reading, even without any processing.
\r
29 - To smooth an opened image: "Image" menu "Smooth" submenu ("Alt-I" and
\r
30 "Alt-M", or "Ctrl-M"). Available filters are: "Circle-5" - averaging over a
\r
31 "circular" window of diameter 5 (a matrix of size 5 by 5 is taken first, 3
\r
32 corner elements in each of the 4 corners are set to 0, and all others are set
\r
33 to 1/(sum of elts)); "Symlet" - each color component is smoothed by means of
\r
34 the particular wavelet family in the usual fashion; "Avg-3" - square 3x3
\r
35 matrix of 1/(sum of elts) is taken as a filter). I prefer the first filter as
\r
36 it provides quick and sufficiently good results. The wavelet-based one seems
\r
37 to need some debugging (as of 11/25/98).
\r
39 - To crop a part of an image: "Image" menu "Crop" submenu ("Alt-I" and
\r
40 "Alt-C", or "Ctrl-C"). Then pick a vertex of the future rectangular window
\r
41 by clicking once on the image with the mouse and select a rectangle that will
\r
42 become a new image. When rectangle is completed a prompt whether to crop or
\r
43 not appears. If "Yes" is pressed, the cropped part appears in a separate
\r
44 window, while blue rectangle in the original image indicates where the part
\r
45 came from. To get rid of the rectangle use "Image"/"Refresh".
\r
47 - To refresh an image (get rid of various extraneous dots and lines): "Image"
\r
48 menu "Refresh" submenu ("Alt-I" and "Alt-E", or "Ctrl-E").
\r
50 - (NEW) To place a label on the image click on the place where the label
\r
51 should begin first. Then go to "Image" menu "Label" submenu ("Alt-I" and
\r
52 "Alt-L", or "Ctrl-L"). A menu offering the title for the label, the font
\r
53 size, type, and color will pop up. When the label is entered, it will be
\r
54 first tentatively placed on the image upon which a confirmation dialogue will
\r
55 pop up. If "No" is chosen the label will not be placed. To edit an existing
\r
56 label, click with the mouse close to the starting point of the label (leftmost
\r
57 character) and again select "Label" submenu of "Image" menu. To erase an
\r
58 existing label this step can be followed - entering in the editing mode first
\r
59 and blanking the label second.
\r
61 - To save an image: "Image" menu "Save as" submenu ("Alt-I" and "Alt-S", or
\r
62 "Ctrl-S"). Currently only "tiff", "jpeg", "bmp", "eps" formats are supported.
\r
63 The figures are saved along with all the lines they may contain. The saved
\r
64 figures are usually stored in two files ("file_low.xxx" and "file_high.xxx")
\r
65 where the first file is of low quality and the latter file (of usually
\r
66 much bigger size) is of high quality. "Eps" is the Encapsulated PostScript
\r
67 and there is just one version of it. For "bmp" the low-quality image is
\r
68 placed in the file "file.bmp" while the high quality one into "file.jpg".
\r
70 - To segment an image (MAIN OPERATION): "Image" menu "Segment" submenu
\r
71 ("Alt-I" and "Alt-G", or "Ctrl-G"). Segmentation means splitting the image
\r
72 pixels into color clusters first (as prescribed by the "Mean Shift Algorithm")
\r
73 and into connected regions second (as is usually done in case of images).
\r
74 The segmentation parameters (appear in the parameter setting window):
\r
75 - Window size: determines the radius of the search window used by the
\r
76 segmentation algorithm. The smaller the window size the more likely the
\r
77 search for the maximum density location will end up in a local maximum, and
\r
78 therefore the bigger number of initial color clusters will be. It also
\r
79 affects the value of the "cluster diameter", i.e. the value by which
\r
80 two colors of the same color cluster could differ.
\r
81 - Color components to use: determines the number of "principal components"
\r
82 to use when segmenting the image. Since a color image consists of 3 color
\r
83 components in any color system, there is a possibility to use 1-3 principal
\r
84 ones for segmentation purpose. When 1 component is used, it is equivalent
\r
85 to using just intensity info, while 3 components uses full color info.
\r
86 The fewer color components are used, the faster the segmentation is.
\r
87 The parameter is automatically set to 1 in case of grey-scale images.
\r
88 - Color group size: determines the minimum number of pixels in a color
\r
89 group for it to be considered a "color cluster". This parameter usually has
\r
90 little effect on the final segmentation due to the fact that the number
\r
91 of pixels of nearly the same color is fairly high in a typical image.
\r
92 - Min region size: determines the minimum number of 8-connected pixels
\r
93 to be considered as a separate connected region. Thus to find only
\r
94 sufficiently big and regular regions (as opposed to small specks) the
\r
95 number must be set to a sufficiently high value.
\r
96 - Separate layers: determines whether to show ("yes") or not ("no") all
\r
97 color clusters at once as "layers" of the original image, i.e. nearly all
\r
98 the image pixels are placed into one of the layers. The white color of a
\r
99 particular pixel in the produced black and white figures is interpreted
\r
100 as "the particular pixels is placed in the particular layer", and vice
\r
101 versa. Some pixels not belonging to any color clusters (due to
\r
102 their color deviation) will not belong to any of the layers.
\r
103 NOTE: the regions handling which will now follow is based on the layers.
\r
105 Having segmented the image (the operation may be repeated if necessary) we
\r
106 now can apply various operations to the resulting segments. Segments are
\r
107 always connected (unless obtained by explicit merging of two disconnected
\r
110 - To find a region's boundary: click on a point belonging to the desired region,
\r
111 then "Region" menu, "Find boundary" submenu ("Alt-R" and "Alt-F", or "Ctrl-F").
\r
113 NOTE: the following operations will require selecting one or two regions. The
\r
114 selection window is basically the same for all the operations. A list of
\r
115 regions (with their numbers) is presented. Upon (tentatively) selecting a
\r
116 region the region's color changes from a non-white to white. Upon deselecting
\r
117 a region the region's color is changed back from white to a non-white.
\r
118 Selecting is done by clicking on the region's number in the list (which should
\r
119 hang down when the down arrow in right side is pressed). Deselecting is done
\r
120 automatically when another region is selected or "cancel" button is pressed.
\r
122 NEW: now region selection can be done by clicking on the region and choosing
\r
123 "(un)select 1-st/2-nd region" from "Region" menu (or "Ctrl-1"/"Ctrl-2").
\r
124 The region chosen again becomes white and turns its usual color when another
\r
125 region is selected. For most operations (e.g. Region save/Cut/Intensity 3-d)
\r
126 choose the region to be the 1-st. The second region needs to be chosen only
\r
127 for binary operations, e.g. comparison or merge. Thus to compare two regions
\r
128 in the same window one would click/select 1-st and 2-nd region and then choose
\r
129 "Compare...Image regions". To compare two regions in different window one
\r
130 however needs to pick 1-st region in one window and select
\r
131 "Compare...Window regions" in that window. Then 2-nd region needs to be
\r
132 chosen in the second window and the same menu item "Compare...Window regions"
\r
133 needs to be selected, so that the system would know which two 1-st/2-nd
\r
134 pair of regions to compare.
\r
136 - To save a region (in a format that can be later used for shape comparison
\r
137 with other regions): "Region" menu, "Save as" submenu ("Alt-R" and "Alt-V",
\r
138 or "Ctrl-V"). The files have extension ".rgn" (for "ReGioN").
\r
140 - To compare two regions in terms of their shapes (as described in the
\r
141 article) and obtain some additional info:
\r
142 "Compare to" submenu of "Region menu". A region can be compared with a
\r
143 region of the same image ("Image region" submenu of "Compare to" submenu
\r
144 ("Alt-R" and "Alt-C" and "Alt-I", or "Ctrl-I"), or a region in a
\r
145 different window ("Window region" submenu of "Compare to" submenu ("Alt-R"
\r
146 and "Alt-C" and "Alt-W", or "Ctrl-W"), or a region previously saved on disk
\r
147 ("Disk region" submenu of "Compare to" submenu ("Alt-R" and "Alt-C" and
\r
148 "Alt-D", or "Ctrl-D"). In the first case the choice of the two regions is
\r
149 done in the same dialogue. In the second case the action of choosing the
\r
150 regions must be done in the two windows (same sequence of keys must be
\r
151 repeated in both windows, and windows may coincide). In the third case after
\r
152 the image region is chosen a prompt to choose a saved region is given.
\r
154 - To merge two regions (which may be disconnected): "Merge" submenu of
\r
155 "Region" menu ("Alt-R" and "Alt-R", or "Ctrl-R"). The region is then treated
\r
156 as a single entity, while the regions from which it was formed "disappear"
\r
157 from various menus (e.g. "Compare", "Merge", etc).
\r
159 - To cut a region into two pieces: "Cut" submenu of "Region" menu ("Alt-R"
\r
160 and "Alt-U", or "Ctrl-U"). Upon choosing the region a prompt to draw the
\r
161 separating line appears. Please be very careful drawing the line as the
\r
162 algorithm for separating the region is quite unstable and must be improved.
\r
163 The line must start and end a little bit outside the region. Upon successful
\r
164 splitting 2 new regions will appear while the old one will disappear.
\r
166 - To visualize a region and obtain some basic info: "Intensity 3-d" submenu
\r
167 of "Region" menu ("Alt-R" and "Alt-3", or "Ctrl-3"). As of today (11/29/98)
\r
168 the region is shown correctly, not flipped. In the image the horizontal axes
\r
169 correspond to image dimensions, while the vertical one corresponds to image
\r
170 intensity. The 3-dimensional graph can be rotated left and right, and up and
\r
171 down by means of "Ctrl-L", "Ctrl-R", "Ctrl-U", and "Ctrl-D" keys while the
\r
172 window is active. The amount by which the graph is rotated could be
\r
173 increased/decreased by means of "Ctrl-A" and "Ctrl-V" keys. While these
\r
174 operations don't allow to choose an arbitrary point of view, large flexibility
\r
175 is achieved. To obtain some relevant to the region information use "Values"
\r
176 menu of the graph window.
\r
178 - To exclude some regions from further consideration (will be shown usefulness
\r
179 of later): "Background" submenu of "Region" menu ("Alt-R" and "Alt-K",
\r
180 or "Ctrl-K"). Now the pixels are removed according to the found regions,
\r
181 not underlying colors. Thus the background should preferrably consist of
\r
182 one or few regions.
\r
184 - To change the color of a region's boundary, first select the region, and
\r
185 second click on "Region"/"Color" submenu (or "Ctrl-L"). A list of possible
\r
186 colors to choose from will be presented.
\r
188 - To thicken/thin the next boundary use "Thicken/Thin next line" submenu of
\r
189 "Region" menu. This could be useful if the lines are too thin for printing
\r
190 purposes. If the next line is still not thick enough, try to do it several
\r
193 A typical use of the system:
\r
194 - read in an image ("jpeg", "tiff", "bmp" formats only) (Image/Open)
\r
195 - select a rectangular region to work with (Image/Crop)
\r
196 - segment with the initially given parameters (Image/Segment)
\r
197 - if the resulting regions are too small (oversegmentation), increase the
\r
198 window size in Segmentation parameters window and resegment;
\r
199 - if the resulting regions are too large (undersegmentation), reduce the
\r
200 window size in Segmentation parameters window and resegment;
\r
201 - if there is large uniformity in "the background":
\r
202 - first segment the image with a small window size but large enough
\r
203 to capture most of the background into one or few regions;
\r
204 - second use "Background" operation from "Region" menu to exclude the
\r
205 corresponding regions from further processing (pixel removal);
\r
206 - third resegment the image with a larger window size so that to capture
\r
207 less uniform foreground;
\r
208 - if a region is best obtained as a result of merge of two fairly different
\r
209 (in color respect) regions that are adjacent, use "Region/Merge" operation.
\r
210 - if a region has some extraneous parts (may be from other similar regions
\r
211 as in case of cells), use "Region/Cut" operation.
\r
212 - having obtained a suitable region it can be visualized in terms of its
\r
213 intensity (Region/Intensity-3d).
\r
214 - having obtained two regions (in the same window or different ones) they can
\r
215 be compared in terms of their shapes and some other respects (e.g. areas or
\r
216 average intensities) (Region/Compare to/[Disk/Window/Region])
\r
217 - an exemplary region can be saved (shape info only, no intensity info) for
\r
218 future comparisons.
\r
219 - an image with or without lines could be saved for future work (Image/Save).
\r