Thursday, September 18, 2008

A18 - Pattern Recognition

Pattern recognition is the act of taking in raw data and taking an action based on the category of the data.(Wikipedia)

For this activity, the goal is to classify images of one peso coins and 25 centavo coins using features extracted from the training images. I have three training images from both the one-peso coin and 25-centavo coin.


The features I extracted from the images are their area and RED-GREEN contrast. To find the area, I binarize the image and to pixel counting.

I assigned 1 for piso and 2 for 25 centavos.

The result of pattern recognition is:
There is a 100% accuracy in determing the right coin.

Acknowledgments:

Aiyin, April - for the help.

Grade: 10/10 although I had difficulty in making this activity, I think I made a correct activity.

Thursday, September 4, 2008

A17 – Basic Video Processing

This activity is all about video processing.

Video is a sequence of still images representing scenes in motion. Video processing is the use of different image processing techniques for each still images in a video.

In our video, we are concern with the diffusion of ink in water. Diffusion is the natural process of intermingling of the molecules of two substances. We are concerned with the area of the ink that is diffused in water.

Using the images below,


image 1
Finding the threshold of the image, using the image below

image 2
After finding the threshold, we can change the images to binary.

image 3
Our region of interest is the ink in the middle of the water. Finding the area of the ROI for each images by pixel counting. We can find the plot below
image 4
We will compare image 4 with the image below.
image 5
We will consider image 5 as the theoretical values for area. This plot is from 'Ink diffusion in water' by Lee S. et. al, 2004.

We can see that there is error in the area of the diffusion of ink in water. It is because of the other part of the images that is not part of the ROI but is still considered in pixel counting.

//code//
t=108/255;
c=[];
for i=1:9
im=imread('vid000'+string(i)+'.jpg');
imb=im2bw(im, t);
c(i)=sum(abs(1-imb));
end
for i=10:99
im=imread('vid00'+string(i)+'.jpg');
imb=im2bw(im, t);
c(i)=sum(abs(1-imb));
end
plot(c);

Acknowledgements:
Instru Lab- for the place
Gerold - for the code
Benj and Billy - for being my groupmates.. :)
http://mitgcm.org/eh3/Tracer_work/papers/ejp4_2_020.pdf


Grade: 10/10
because I think I did what is needed to do. :)

Tuesday, September 2, 2008

A16 – Color Image Segmentation

In image segmentation, a region of interest (ROI) is picked out from the rest of the image such that further processing can be done on it. Selection rules are based on features unique to the ROI.

normalized chromaticity coordinates
- represent color space not by the RGB but by one that can separate brightness and chromaticity (pure color) information

Per pixel, let I = R+G+B. Then the normalized chromaticity coordinates are

We note that r+g+b = 1 which implies r,g and b can only have values between 1 and 0 and b is dependent on r and g since b = 1-r-g.from R G B, the color space has been transformed to r g I where chromatic information is in r and g while brightness information is in I.
Parametric vs Non-Parametric Probability Distribution Estimation

Segmentation based on color can be performed by determining the probability that a pixel belongs to a color distribution of interest.

The probability that a pixel with chromaticity r belongs to the ROI is then
Histogram backprojection

Histogram backprojection is one such technique where based on the color histogram, a pixel location is given a value equal to its histogram value in chromaticity space.

Using the image:
cropping an the image:
Thus, we will use the yellow ball as the ROI.

We will use to techniques.
Parametric:

Non-Parametric

Acknowledgements:

Mark Leo - for the help.

Grade:
10/10
- because I think I did what is needed to do. And I think the image is well segmented.

 
template by suckmylolly.com