Professional Documents
Culture Documents
Decision Tree For 3-D Connected Components Labeling
Decision Tree For 3-D Connected Components Labeling
Decision Tree For 3-D Connected Components Labeling
Phaisam Sutheebanjard
Chalermkamchana College
Phetchabun 67000, Thailand
dr. phaisam@gmail.com
the
Abstract-3-D
connected
components
labeling
is
3-D connected
first image scan, all those labels that belong to one component
images. This method will be used at the first round of the two
of a component.
P(x.l.V.11
P(X.1.)"1) P(x.y.1)
p(x.l.y)
Figure
tree,
INTRODUCTION
a:P(x.1.V.l zj)
b:P(x.v.l zj)
d: P(x.l.v.z.1)
e: P(x.v.z.1)
h:P(x.v+l zl)
g: P(xLv+l z1)
p:p(X'I 'LZl
. S,. P(x.l_z1
image
1.
p(x.y)
::
q:P x .1 z)
: ;
c:p(x+1.v.l zj)
fP(x+l.v.z.1)
i:P(x+Lv+1 z1)
r:P(x+Ly.Lz)
. x:p.x _z
categorized into four classes as the following: (i) one-scan [12J , (ii) two-scan [3-11J, (iii) multi-scan [12J and (iv) contour
tracing [13J algorithms.
Accordingly to Grana et at. [3J , two-scan is the fastest
algorithm for labeling the 2-dimension connected components.
Two-scan is a simple and efficient algorithm in computation
time that was previously introduced by Rosenfeld and Pfaltz in
1966 [4]. It consists of three classical operations:
1.
Equivalences
resolution:
(equivalence
classes
creation)
3.
connected
component
labeling
(26-connectivity)
which
is
further developing.
image by using the scan mask as shown in Fig. 1 [5J , and find
the 26-connectivity in 3-D binary image by using the scan
709
II.
TWO-SCAN ALGORITHM
"x",
in Fig. 4. Case 1 is the new label action, cases 2-9 and 13-16
are the assign action and cases 10-12 are the merge action.
Fig. 5.
A.
2-dimension
(1)
(4)
(3)
(2)
given
by
variables (''p'',
No action:
is
performed
if
the current
(7)
(8)
(9)
(10)
(12)
(11)
Assign action:
need
for
consideration
of
label
equivalences
(13)
(6)
3.
pixel
(5)
Figure 4.
(14)
(15)
(16)
1: If (x==Foreground)
2:
3:
4:
If (q==Foreground)
x=q
else if (s==Foreground)
5:
x=s
6:
if (r==Foreground)
x=r+s
7:
scan mask is always the neighbor of " q" (see Fig. 1). If there is
8:
else if (p==Foreground)
x=p
9:
if (r==Foreground)
10:
11:
neighbors.
12:
x=p+r
else if (r==Foreground)
x=r
13:
14:
else
x=new label
15:
16: else
17:
no action
Figure 5.
B.
3-dimension
Labeling of connected components in 3-D binary images
has been studied from the Lumia et al. in 1983 [14J and Shirai
in 1987 [15]. Recently, He et al. in 2010 [16J present an
efficient method of deciding the order for checking voxels in
the mask. They analyze number of the neighbor voxels that
need to be checked. The number of the neighbor voxels of each
Figure 3.
710
TABLE I.
III.
SCAN MASK.
indent.
if (condition_x) {
-if (condition_e) {
--goto Assign E;
-} else {
--if (condition_q) {
---if (condition_h) {
----if (condition_d) {
-----goto Assign Q;
----) else (
-----if (condition_f) (
------goto Assign Q;
-----) else {
------goto Merge HQ;
-----) Ilelse f
----} Ilelse d
---) else (
----if (condition_g) {
-----if (condition_d) {
------if (condition_i) {
-------goto Merge QI;
------} else (
-------goto Assign Q;
------) Ilelse i
-----} else {
------if (condition_i) {
-------goto Merge GIQ;
------) else {
-------goto Merge GQ;
------) Ilelse i
-----) Ilelse g
----} else {
-----if (condition_i) (
------if (condition_f) {
-------goto Assign Q;
------} else {
-------goto Merge IQ;
------} Ilelse f
-----) else {
------goto Assign Q;
-----) Ilelse i
----) Ilelse g
---) Ilelse h
--) else {
---if (condition_b) (
----if (condition_h) {
-----if (condition_d) {
------goto Assign B;
-----} else {
------} else {
------if (condition_f) {
-------goto Assign B;
------} else {
-------goto Merge BH;
------} Ilelse f
-----) Ilelse d
----) else (
-----if (condition_g) (
------if (condition_d) (
-------if (conditionj) (
--------if (condition_f) {
---------goto Assign B;
--------} else {
---------goto Merge BI;
--------} Ilelse f
-------} else {
--------goto Assign B;
-------} Ilelse i
------} else {
-------if (condition_i) {
--------if (condition_f) {
---------goto Merge BG;
--------} else {
---------goto Merge BGI;
--------} Ilelse f
-------} else {
--------goto Merge BG;
-------) Ilelse i
------) Ilelse d
-----} else {
------if (condition_i) {
-------if (condition_f) {
--------goto Assign B;
-------} else {
--------goto Merge BI;
-------} Ilelse f
------) else {
-------goto Assign B;
------) Ilelse i
-----) Ilelse g
----) Ilelse h
---) else (
----if (condition_d) {
-----if (condition_f) (
------if (condition_h) {
-------goto Assign D;
711
---------} Ilelse f
--------} else {
---------if (conditionJ) {
----------if (condition_f) {
-----------goto Assign H;
----------} else {
-----------goto Merge HR;
----------} Ilelse f
---------} else {
----------goto Assign H;
---------} Ilelse r
--------} Ilelse c
-------) else {
--------if (condition_c) (
---------if (condition_f) {
----------goto Merge AH;
---------} else {
----------goto Merge ACH;
---------} Ilelse f
--------} else {
---------if (conditionJ) {
----------if (condition_f) {
-----------goto Merge AH;
----------} else {
-----------goto Merge AHR;
----------} Ilelse f
---------} else {
----------goto Merge AH;
---------} Ilelse r
--------} Ilelse c
-------} Ilelse s
------) else (
-------if (condition) {
--------if (condition_s) {
---------if (condition_c) {
----------if (condition_f) {
-----------goto Assign H;
----------} else (
-----------goto Merge CH;
----------} Ilelse f
---------} else {
----------if (conditionJ) {
-----------if (condition_f) (
------------goto Assign H;
-----------) else (
------------goto Merge HR;
-----------} Ilelse f
----------) else (
-----------goto Assign H;
----------) Ileise r
---------} Ileise c
--------} else {
---------if (condition_c) {
----------if (condition_f) {
-----------goto Merge HP;
----------} else {
-----------goto Merge CHP;
----------} Ileise f
---------} else {
----------if (conditionJ) {
-----------if (condition_f) (
------------goto Merge HP;
-----------) else (
------------goto Merge HPR;
-----------) Ileise f
----------) else (
-----------goto Merge HP;
----------) Ileise r
---------} Ileise c
--------} Ileise s
-------} else {
--------if (condition_c) {
---------if (condition_f) {
----------goto Assign H;
---------} else {
----------goto Merge CH;
---------} Ileise f
--------} else {
---------if (conditionJ) {
----------if (condition_f) {
-----------goto Assign H;
----------) else (
-----------goto Merge HR;
----------) Ileise f
---------} else (
----------goto Assign H;
---------) Ileise r
--------} Ileise c
-------} Ilelse p
------} Ilelse a
-----} else {
------if (condition_f) {
-------if (condition_s) {
--------goto Merge FS;
-------} else (
--------if (condition_g) {
---------if (condition_a) {
----------goto Merge AFG;
---------} else (
----------if (condition) (
-----------goto Merge FGP;
----------} else {
-----------goto Merge FG;
----------} Ileise p
---------} Ileise a
--------} else {
---------if (condition_a) {
----------goto Merge AF;
---------} else (
----------if (condition) (
-----------goto Merge FP;
------------) else (
-------------goto Merge AG;
------------) Ileise i
-----------) else (
------------if (condition_i) {
-------------goto Merge AI;
------------) else (
-------------goto Assign A;
------------} Ileise i
-----------} Ileise g
----------} Ileise r
---------} Ilelse c
--------} else (
---------if (condition_c) {
----------if (condition) {
-----------if (condition_g) (
------------if (condition_i) {
-------------goto Merge CGIP;
------------) else (
-------------goto Merge CGP;
------------) Ileise i
-----------) else (
------------if (condition_i) {
-------------goto Merge CIP;
------------} else {
-------------goto Merge CP;
------------} Ileise i
-----------} Ileise g
----------} else {
-----------if (condition_g) {
------------if (condition_i) {
-------------goto Merge CGI;
------------) else (
-------------goto Merge CG;
------------) Ileise i
-----------) else (
------------if (condition_i) {
-------------goto Merge CI;
------------} else {
-------------goto Assign C;
------------} Ileise i
-----------} Ileise g
----------} Ileise p
---------} else {
----------if (condition_g) {
-----------if (condition_i) {
------------if (condition) {
-------------if (condition_r) {
--------------goto Merge GIPR;
-------------) else (
--------------goto Merge GIP;
-------------) Ilelse r
------------) else (
-------------if (condition_r) {
--------------goto Merge GIR;
-------------} else {
--------------goto Merge Gl;
-------------} Ilelse r
------------} Ileise p
-----------} else {
------------if (condition) {
-------------if (condition_r) {
--------------goto Merge GPR;
1 else (
----------) else (
-----------goto Assign F;
----------} Ileise p
---------} Ileise a
--------} Ileise g
-------} Ileise s
------) else {
-------if (condition_s) {
--------if (condition_i) {
---------if (condition_c) {
----------goto Merge CIS;
---------} else {
----------if (conditionJ) {
-----------goto Merge IRS;
----------} else {
-----------goto Merge IS;
----------} Ileise r
---------} Ileise c
--------} else {
---------if (condition_c) {
----------goto Merge CS;
---------} else (
----------if (conditionJ) (
-----------goto Merge RS;
----------} else {
-----------goto Assign S;
----------} Ileise r
---------} Ileise c
--------} Ileise i
-------} else (
--------if (condition_a) (
---------if (condition_c) (
----------if (condition_g) (
-----------if (condition_i) {
------------goto Merge ACGI;
-----------) else (
------------goto Merge ACG;
-----------) Ileise i
----------} else {
-----------if (condition_i) {
------------goto Merge ACI;
-----------} else {
------------goto Merge AC;
-----------} Ileise i
----------} Ileise g
---------} else {
----------if (conditionJ) (
-----------if (condition_g) (
------------if (condition_i) {
-------------goto Merge AGIR;
------------) else (
-------------goto Merge AGR;
------------) Ileise i
-----------) else (
------------if (condition_i) {
-------------goto Merge AIR;
------------} else {
-------------goto Merge AR;
------------} Ileise i
-----------} Ileise g
----------} else {
-----------if (condition_g) (
------------if (condition_i) {
-------------goto Merge AGI;
_____________
712
IV.
[3]
EXPERIMENTAL RESULTS
[4]
[5]
in digital picture
Press,
[6]
A. Rosenfeld and
processing,"
using a single core for the processing. All algorithms used for
1976,2005.
[7]
the image data at the end of each run by calling the standard
[8]
Letters, vol.
Pattern Recognition
31,2010,pp. 28-35
IEEE
Transactions on Image
Processing,
voLl7, No. 5,
pp. 749-756,2008
International Journal of
557-579.
algorithm,"
Understand, vol.
89,pp. 1-23,2003.
[13] F. Chang,
Image size
Time (ms)
He et aI.
DT
32x32x10
0.465
0.503
64x64xlO
1.583
l .619
128x128x10
5. l 44
5.227
256x256x10
19.615
19.658
512x512x10
77.636
78.014
1024x1024x10
306. l 39
307.581
2048x2048x10
1226.077
1230.73
V.
Process., vol.
[15] Y.
CONCLUSION
time,
it
can
be
considered
as
an
interesting technique
REFERENCES
[1]
[2]
regions,"
in
Three-Dimensional
Springer-Verlag,pp. 86-89,1987.
fastest
connected
the
Shirai, "Labeling
713