Added Feature SubPixel refining and OpticalFlow homography refining

This commit is contained in:
matlabbe
2015-05-19 21:23:24 -04:00
parent b3b25b905b
commit 4b2ab25cb7
5 changed files with 241 additions and 121 deletions
+1
View File
@@ -42,6 +42,7 @@ public:
enum TimeStamp{
kTimeKeypointDetection,
kTimeDescriptorExtraction,
kTimeSubPixelRefining,
kTimeSkewAffine,
kTimeIndexing,
kTimeMatching,
+9
View File
@@ -120,6 +120,10 @@ class FINDOBJECT_EXP Settings
PARAMETER(Feature2D, 3MaxFeatures, int, 0, "Maximum features per image. If the number of features extracted is over this threshold, only X features with the highest response are kept. 0 means all features are kept.");
PARAMETER(Feature2D, 4Affine, bool, false, "(ASIFT) Extract features on multiple affine transformations of the image.");
PARAMETER(Feature2D, 5AffineCount, int, 6, "(ASIFT) Higher the value, more affine transformations will be done.");
PARAMETER(Feature2D, 6SubPix, bool, FINDOBJECT_NONFREE != 1, "Refines the corner locations. With SIFT/SURF, features are already subpixel, so no need to activate this.");
PARAMETER(Feature2D, 7SubPixWinSize, int, 3, "Half of the side length of the search window. For example, if winSize=Size(5,5) , then a 5*2+1 x 5*2+1 = 11 x 11 search window is used.");
PARAMETER(Feature2D, 8SubPixIterations, int, 30, "The process of corner position refinement stops after X iterations.");
PARAMETER(Feature2D, 9SubPixEps, float, 0.02, "The process of corner position refinement stops when the corner position moves by less than epsilon on some iteration.");
PARAMETER(Feature2D, Brief_bytes, int, 32, "Bytes is a length of descriptor in bytes. It can be equal 16, 32 or 64 bytes.");
@@ -255,6 +259,11 @@ class FINDOBJECT_EXP Settings
PARAMETER(Homography, rectBorderWidth, int, 4, "Homography rectangle border width.");
PARAMETER(Homography, allCornersVisible, bool, false, "All corners of the detected object must be visible in the scene.");
PARAMETER(Homography, minAngle, int, 0, "(Degrees) Homography minimum angle. Set 0 to disable. When the angle is very small, this is a good indication that the homography is wrong. A good value is over 60 degrees.");
PARAMETER(Homography, opticalFlow, bool, false, "Activate optical flow to refine matched features before computing the homography.");
PARAMETER(Homography, opticalFlowWinSize, int, 16, "Size of the search window at each pyramid level.");
PARAMETER(Homography, opticalFlowMaxLevel, int, 3, "0-based maximal pyramid level number; if set to 0, pyramids are not used (single level), if set to 1, two levels are used, and so on; if pyramids are passed to input then algorithm will use as many levels as pyramids have but no more than maxLevel.");
PARAMETER(Homography, opticalFlowIterations, int, 30, "Specifying the termination criteria of the iterative search algorithm (after the specified maximum number of iterations).");
PARAMETER(Homography, opticalFlowEps, float, 0.01, "Specifying the termination criteria of the iterative search algorithm (when the search window moves by less than epsilon).");
public:
virtual ~Settings(){}