Click here to Skip to main content
12,956,173 members (59,354 online)
Rate this:
 
Please Sign up or sign in to vote.
See more:
HELLO :)
this is my first question on CodeProject. actually, i dont post any question on any website but this time, i get STUCK !!

the IDEA...
i am working on a project based on image processing.
simply, i want to compare my new image with other images in my database to find the most similar images.

technically...
i am using (SURF) in (EMGU) warping library of OpenCV using this code:

// convert images to Gray images for the SURF

Image imgg1 = Image.FromFile("input_1.png");
Image<Gray, Byte> g_image_1 = new Image<Gray, byte>((Bitmap)imgg1);
Image imgg2 = Image.FromFile("input_0.png");
Image<Gray, Byte> g_image_2 = new Image<Gray, byte>((Bitmap)imgg2);
 
// prepare detection parameter 
 
MCvSURFParams image_param = new MCvSURFParams(300, false);
SURFDetector detect1 = new SURFDetector(image_param);
 
ImageFeature<float>[] image_feacher_1 = detect1.DetectFeatures(g_image_1, null);
ImageFeature<float>[] image_feacher_2 = detect1.DetectFeatures(g_image_2, null);
 
Features2DTracker<float> traker = new Features2DTracker<float>(image_feacher_1);
Features2DTracker<float>.MatchedImageFeature[] matching = traker.MatchFeature(image_feacher_2, 2);
 
matching = Features2DTracker<float>.VoteForUniqueness(matching ,0.8);
 
matching = Features2DTracker<float>.VoteForSizeAndOrientation(matching , 1.5, 20);
 
Image<Gray, Byte> res = g_image_1.ConcateVertical(g_image_2);
 
// drow matching lines
foreach (Features2DTracker<float>.MatchedImageFeature matchedFeature in matching )
            {
                PointF p = matchedFeature.ObservedFeature.KeyPoint.Point;
 
                p.Y += g_image_1.Height;
 
                res.Draw(new mLineSegment2DF(matchedFeature.SimilarFeatures[0].Feature.KeyPoint.Point, p), new Gray(0), 1);
            }
 
// showing the result image
ImageViewer Imagee = new ImageViewer(res);
Imagee.ShowDialog();



after this...
the result for images will be as matched points from both of the images...
and from 4570 point from image 1 and 4700 from image 2....
it matched 400 point and that.

now...
i am looking around to find the percentage of similarity between these images
but i can find it... i found something similar to my question...
http://www.ipol.im/pub/pre/H2/[^]

but it is in C++ and the code hard to convert !!!

any help please !!!!!?!?!?
Posted 16-Sep-12 11:20am
MOUDDY317
Updated 3-Mar-17 7:35am

1 solution

Rate this: bad
 
good
Please Sign up or sign in to vote.

Solution 1

Hi
Please can you send me this source code I need to make SURF detection in my project
hhmmoe83@gmail.com
Regards
  Permalink  
Comments
NotPolitcallyCorrect 3-Mar-17 13:37pm
   
How rude it is that you would resurrect a FIVE year old question for no other reason that to beg for source code?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

    Print Answers RSS
Top Experts
Last 24hrsThis month
OriginalGriff 6,869
CHill60 3,550
Maciej Los 3,243
ppolymorphe 2,070
Jochen Arndt 1,973


Advertise | Privacy | Mobile
Web02 | 2.8.170525.1 | Last Updated 3 Mar 2017
Copyright © CodeProject, 1999-2017
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100