Friday, October 14, 2011

Pattern Recognition 2

In this activity we discuss about the pattern recognition technique of linear discriminant analysis (LDA).

The purpose of Discriminant Analysis is to classify objects into one of two or more groups based on a set of features that describe the objects. In general, we assign an object to one of a number of predetermined groups based on observations made on the object.

To use LDA for pattern recognition we need to know the conditional probability P(i|x) that an object belong to group i. However this is often hard to obtain. What we can obtain however is the probability of getting certain feature, given that the object is from group i, this is P(x|i). The relation between the two probabilities is given by:

This equation however, is directly impractical since we need a large sample size to obtain the relative P(x|i) for each group. A more practical way is to assume the distribution and get the probability theoretically. This is where we get the LDA formula:

Again, we apply the above equation on the 1-peso, 5-peso, leaf and card classes. Again the characteristics I used were the RGB information and the area of each object. From these characteristics, I was able to obtain a 100% recognition rate for all classes. This may be due to the fact that most of the object look very much alike. Also I solved the problem of the areas of each object being of different orders of magnitude by normalizing them. This may have helped in the processing of the algorithm. This was an easy activity since the steps on what to do are already given so I give myself a 10/10.

No comments:

Post a Comment