Sunday, August 19, 2012

Week #13


I have completed correlator — Detection feature points and searching corresponding points on different images.
This week I finished documentation for my code, performed refactoring and cleaning up.
I implemeted in GDALCorrelator file 2 main external methods for searching and matching feature points. Methods provide simple and seamless usage of my internal classes.
My mentor is going to implement GCP producing based on my realization, adapt and migrate correlator to GDAL.
I'll devote my remaining time to refining documentation and helping in porting correlator.

I participate in GSoC program for the first time, and it's an unforgettable and priceless experience for me :)

Saturday, August 11, 2012

Week #12

This week I've sucessfully ported code for searching corresponding points to C/C++, so it's possible to use algorithm in GDAL now.
https://github.com/migal-drew/GDAL-correlator
Method uses RGB values to prepare grayscale image as 2-dimensional array of pixels brightness, than finds feature points and matches their. User should provide threshold values and octave numbers. Octave affects on the size of detected points. So, for small images you should use small octave numbers, and vice versa. For example, octaves 2-3 are good for 640x480 and 1024x768 images.

I recommend to use the small number of octave ranges (one-two), for instance numbers 2-2, 4-4, 2-3, but not 1-6 or 2-8, besause it slows down computation speed in several times. Also I don't recommend use high resolution photos. In future I'm going to fix this computation issues. In this project I concentrated on reliable results more than speed.
Another important thing that algorithm is scale and rotation sensitive. The images should have similar size and angle (difference up to 10-15 degrees).
The results are better than shown in my previous post, because I implemented simple false matching detection, and algorithm tends to find more robust matches.
I'm planning to spend remaining time cleaning up code (improving readability) and working on documentation, and I need to discuss with my mentor about current situation and specify completed goals.

*UPDATED 
Actually algorithm is scale invariant. I perfomed a test using images with different resolutions. Octave range - 1-3 for both images. Left picture - 512x512, right - 300x300.


 
Right - 640x480, left - 400x300


Here you can see how many robust matches algorithm is able to find. It's near perfect, wrong detections are possible very rarely (I was planning to implement good technique for false detetions pruning - RANSAC, but project has lagged because of his complexity, so I decided to make another simple, but still admissible method. I'm very excited of that I implemented, and it works as I've planned in the begin.


Saturday, August 4, 2012

Week #11

This week I implemented descriptors and method for matching points (based on euclidean distance and bruteforce comparison). Matching requires value of threshold. If threshold is low - number of coressponding points is small, but results are robust, and conversely.
https://github.com/migal-drew/SimpleSURF_csharp

Next week I'm planning to port my code in GDAL, test algorithm and work on documentation.

Examples:


Here is result in case if threshold is too high (false detections intersect other "true" matches)


 Test with "sunflower field" image


And test with "standard" image in computer vision ("lenna image")






Saturday, July 28, 2012

Week #10

This week I implemented working version of algorithm for searching feature points in image (based on SURF algorithm, but I omitted some tricky details - original is faster, I'll improve computation speed later).
Code:  https://github.com/migal-drew/SimpleSURF_csharp

Next week I'm planning to write code for finding descriptors and matching of identical points. If I don't come across problems, I'll begin to port methods in GDAL.




Saturday, July 21, 2012

Week #9

This week I didn't have enough free time, so results aren't great.
I tried to improve intial orientation of photos using GPS, but task turned up slightly more complicated than I expected, and I couldn't finish in time for weekly report.
Next week I'm planning continue my previous week goals and achieve more progress.

Sunday, July 15, 2012

Week #8

This week I tried to apply code for initial positioning of photos based on GPS information
Program creates .jgw and .prj files for every input image.
(I use this sample of telemetric information -
But for now I couldn't figure out appropriate camera parameters, so photos aren't aligned properly.
Next week I'm planning solve this ussue and continue work on searching feature points.

 This is current results. As you can see, positions and angles look good, but images don't match with each other (I think that is due to wrong scaling - wrong pixel size).



P.S. In this year I with my friends participate in ICFP contest for the second time. I hope we will reach some good results :)

Saturday, July 7, 2012

Week #7

This week I started to work on SURF algorithm
Also I started to implement initial orientation and geographical positioning using GPS information (C++ with GDAL library). Unfortunately, I've encountered some problems with with GDAL functions and with my programming environment - CodeBlocks and Eclipse CDT.
 I made another example of stitching. The photos are from my proposal, but now with my optimization code (in proposal - Opencv built-in transformer). 

Before and after

For more details read my previous posts.