Monday, August 24, 2009

Activity 14. Pattern Recognition

The goal of this activity is to classify the chosen samples to their respective classes (such as color and size) using Scilab.

Objects with different characteristics were chosen as samples for this activity. In this case, 10 pieces of 2 kinds of soft drink caps and 10 pieces of 25 centavo coins were chosen. The image of the samples were taken and then processed using Scilab. Five samples for each type of object was chosen as the basis of each types color level and size. The image containing 5 samples of each type were converted into a binary image using the im2bw function in Scilab. The sizes of the samples were then computed with the help of the bwlabel function. The mean of the sizes of the different objects were then computed. The color level of each of type of object in the image containing 5 of each type of object were computed. The mean color level (Red channel) and the mean size or area was then compared to the sizes and color levels of the objects in the image containing 10 of each objects.

The original image of the samples along with the binary image is shown below.


Figure1. Sample Objects

The generated classification graph is shown in Figure 2.

Figure2. Sample Groupings

Figure 2 shows the classification plot of the chosen samples. The x-marks represents the samples while the colored dots represent the basis or the supposed group position. The x-axis position of the group of red caps should be aligned with the position of the group of white caps since they have the same area. This is due to the enlargement of the area of the white caps when the image was converted into a binary image. The areas of the red caps seem to vary more compared to the areas of the other groups.


I give myself 10/10 in this activity.

No comments:

Post a Comment