20 Kasım 2012 Salı

VLfeat Matching Examples


         While we are studying on image processing ,we have started to find interest points on images.After that we are studying on matching the interest points between two almost same images.First of all we have two images.It includes nearly same view on same viewpoint.Basic idea is that finding the interest points on the images and matching them .
         There is a result of this process.It gives us nearly correct matches.We worked on vl feat open source library which implements popular computer vision algorithms including HOG, SIFT, MSER, k-means, hierarchical k-means, agglomerative information bottleneck, SLIC superpixels, and quick shift. It is written in C for efficiency and compatibility, with interfaces in MATLAB for ease of use, and detailed documentation throughout. It supports Windows, Mac OS X, and Linux.
         But there is a problem here because your images can be different size or high quality so that you change the code lines like that:

on vl_demo_covdet.m;
         % vl_imarraysc(reshape(patches(:,1:10*10), w,w,[])) ;
         vl_imarraysc(reshape(patches(:,1:size(frames,2)), w,w,[])) ;

Then if your image has high quality you can resize images;
         imresize(image,1/3.0,'bicubic');




            








             But there are different images.There is puzzle box while you can see top of the box at first image,you can see bottom of the box at second image and the back ground is a carpet.As a result of the matching process,we can see  the program has matched the carpet pattern on images.We can not say the matching process is totally wrong but ıt has trick point.the pattern  is same all over the carpet so that program finds the interest points and matches them.but this images can be located different places on it. there  is an example for this situation:




7 Kasım 2012 Çarşamba

Samples of Key Points and Descriptors

We tried these codes in order to find key points and descriptors. Then we have these pictures as results of changing the bold line with the ones above each pictures.

imPath = fullfile(‘alex.jpg’) ;
im = imread(imPath) ;
imgs = im2single(rgb2gray(im)) ;
[frames, descrs] = vl_sift(imgs) ;
imagesc(im) ; colormap gray; hold on ;
vl_plotframe(frames) ;
vl_plotsiftdescriptor(descrs(:,432), frames(:,432)) ;

original image:
[frames, descrs] = vl_sift(imgs) ;
frames = vl_covdet(imgs, 'verbose') ;
frames = vl_covdet(imgs, 'method', 'Hessian') ;
frames = vl_covdet(imgs, 'method', 'HarrisLaplace');
frames = vl_covdet(imgs, 'EstimateAffineShape', true) ;

Local Features: Detection and Description

Matching two images is one of the subjects that we want to learn for implementing our project. Hereby we have worked on the Local Features subject. Rotation, scaling, viewpoint changes makes harder matching process. Image matching process contains five steps:
 1. Find a set of distinctive keypoints: For better results, points which changes in both directions should be chosen. These points are generally corners.
 2. Define a region around each keypoint in a scale- or affine-invariant manner: Similarity of signature functions helps matching process. In affine-invariant region detection, strong viewpoint changes can be handled too.
 3. Extract and normalize the region content: In this step rotation invariances are fixed.
 4. Compute a descriptor from the normalized region: Finally a descriptor is encoded for content discriminative matching process. SIFT and SURF are the example implementations of local descriptors. 5. Match the local descriptors.

 In conclusion we have learned the algorithm of matching process with local descriptors. This functionality can be used in stereo matching, image retrieval, object recognition and categorization.