[Insight-users] Fwd: co-occurrence matrix
Zachary Pincus
zpincus at stanford.edu
Wed Jun 30 14:36:16 EDT 2004
I'm forwarding this to the insight-users list in case anyone has a
similar question or such a question in the future... The answer will
follow momentarily.
Zach
Begin forwarded message:
From: Tanja Stumpf <t.stumpf at dkfz-heidelberg.de>
Date: June 30, 2004 4:20:50 AM PDT
To: Zachary Pincus <zpincus at stanford.edu>
Subject: Re: co-occurrence matrix
I wanted to use your newly written
itkScalarImageToGreyLevelCooccurrenceMatrixGenerator class. And when I
read about the submitted test I couldn't reconstruct how the given
histogram was composed. With the given test image
1 2 1 2 1
1 2 1 2 1
1 2 1 2 1
1 2 1 2 1
1 2 1 2 1
you observed with offset (0,1) and (1,0) you get the
Cooccurrence-Matrix (only the interesting part):
0 1 2
+------
0| 0 0 0
1| 0 6 9
2| 0 9 12
In my calculations I got the following "North"-Cooccurrence-Matrix:
N 0 1 2
+-------
0| 0 0 0
1| 0 12 0
2| 0 0 8
and the "East"-Cooccurrence-Matrix (the occurances of (1,2) are also
added to those of (2,1) to get a symmetric matrix):
E 0 1 2
+--------
0| 0 0 0
1| 0 0 20
2| 0 20 0
finally you get this matrix:
0 1 2
+--------
0| 0 0 0
1| 0 12 20
2| 0 20 8
Is there a mistake in my thoughts? Or are any their any specification
I didn't see? Thanks for your help!
Tanja
More information about the Insight-users
mailing list