next up previous
Next: 4. Discussion Up: Moment Representation of Blobs Previous: 2. Theory

   
3. Practice

A classifier was constructed to detect each of the following images (figure 5) under any combination of translation, rotation and scaling.


  
Figure 5: Classification data.
\begin{figure}
\begin{center}
\epsfig{file=scissors.eps,width=1.5in}\epsfig{file...
...aver.eps,width=1.5in}\epsfig{file=knife.eps,width=1.5in}\end{center}\end{figure}

The classifier is designed around a simple object-oriented framework for calculating moments developed explicitly for this project. To facilitate the design, an object-oriented Image class and a number of image processing functions programmed by the author under various prior grants were employed: a 3x3 Sobel edge operator, a 2D smooth scaling routine, and a 2D smooth in-plane rotation algorithm.

As an initial verification step, translation independence was verified. Testing on 444 translations of the image of the knife within a 128x128 image, $M_1, M_2, \ldots, M_7$ were found to remain quite constant. As a measure, the difference in the order of magnitudes of the standard deviation for each M to the mean for each M ( $\log \overline{M_i} - \log \sigma_{M_i}$) is presented in table 1.


 
Table 1: Log of the standard deviation of each M, processing only translations
M1 M2 M3 M4 M5 M6 M7
14 6 4 4 4 5 3
 

Having established translation independence, Hu's seven invariant functions were tested for rotation independence. Data sets containing images of the knife, cleaver and scissors rotated at every $5^\circ$from $0^\circ$ to $360^\circ$ were constructed. The first twenty five entries in the data set for the knife are shown below in figure 6.


  
Figure 6: Angles 0-120 degrees of the knife training imagery.
\begin{figure}
\begin{center}
\epsfig{file=knife.rotate.mosaic.eps,width=3in}\end{center}\end{figure}

Although the results indicated wider distributions, a histogram of the results for the M1 moment invariant function indicates that a classifier is easily constructed for this data using only the M1 evaluation (figure 7).


  
Figure 7: Separation of M1 moments.
\begin{figure}
\begin{center}
\epsfig{file=M1.eps,width=3in}\end{center}\end{figure}

From left to right, the peaks in figure 7 correspond to the knife, the pair of scissors, and the cleaver. By simply placing two boundaries, one midway between 22,000 and 26,000 and another between 26,000 and 48,000, a classifier is constructed that has no probability of error for this training data, using only M1!

As a final test, we seek to use expressions $M_1', M_2', \ldots, M_7'$to obtain translation, rotation and scale independence. A large training set for each of the three target images was constructed to have ten scale variations from 1.0 to 0.1 for each of the angles represented in the prior training data, a total of 72 angles times 10 scale factors = 720 images for each target.


  
Figure 8: Separation of M2' moments.
\begin{figure}
\begin{center}
\epsfig{file=M2p.eps,width=3in}\end{center}\end{figure}

Figure 8 shows the results for the M2' invariant function, indicating that although the separation is reduced between target classes, a zero probability of error classifier could still easily be constructed.


next up previous
Next: 4. Discussion Up: Moment Representation of Blobs Previous: 2. Theory
Mike Andrews
1999-04-09