For my third project in CSE 327 Image Processing, I build a panorama. I did this by adapting MatLab code provided by Prof Alex Berg.
The first step in building the panorama is to find associated points in images.
The given code comes with 1 element feature vectors. It just compares the average intensity at a point. It works OK.
I started by adding another element to the feature vector. The second element in my feature vectors is the vertical gradient.
My corresponder (My program for find associated points in two images) is now able to better associate points. It always associates horizonal edges with horizontal edges.
The approach I use is nearest neighbor. Partitioning the space with a decision boundary seems confusing when each class contains only one point. The benefit is unclear.
I continued by adding all the features Prof. Berg told us about in class. I replaced the horizontal gradient with the full gradient (well direction not magnitude). Atan2 helped. This works better.
I added color matching using hue. The hue is a kind of color angle. I used Atan2 again to calculate this color angle.
I then added a feature of my own: vertical position. Sky is usually up. Interesting things are near the middle. And so on.
With these 4d features I can pick out foliage, bars, and other things.
To compare all 3 classifiers, I checked if the classifiers could identify the Antenna which is in both pictures. The error rate for the 1D classifier was 2/3. The 2D was also 2/3. The 4D was perfect: 0/3.