Ask Your Question

enllauna's profile - activity

2017-06-27 02:06:29 -0500 asked a question How to get Weak Responses from Boosting in OpenCV 3.2.0

Dear all,

in OpenCV's 2.4.X, CvBoost's predict method gave the possibility of returning weak_responses. However, in OpenCV 3.2.0 I can't find the means of doing that. Any ideas?

Thanks in advance!

2017-06-12 05:32:33 -0500 commented answer MotionEstimatorRansacL2 no behaving as expected

Thanks! I really missed that detail. Now it works as expected! ;)

2017-06-12 05:31:03 -0500 received badge  Supporter (source)
2017-06-12 05:31:01 -0500 received badge  Scholar (source)
2017-06-12 04:21:17 -0500 asked a question MotionEstimatorRansacL2 no behaving as expected

Dear all,

I would like to estimate the motion between 2 sets of keypoints using the method estimate of MotionEstimatorRansacL2. However it always returns the identity. I've created a toy code to figure it out:

// Create toy keypoints
int nKeypoints = 10;
int dx = 25;
std::vector<cv::KeyPoint> KP0, KP1;
for (int n = 0; n < nKeypoints; n++) {

    cv::KeyPoint kp = cv::KeyPoint((float)n, (float)n, 2);
    KP0.push_back(kp);
    kp.pt.x += dx;
    KP1.push_back(kp);
}

cv::videostab::MotionModel model = cv::videostab::MM_TRANSLATION;
cv::Ptr<cv::videostab::MotionEstimatorRansacL2> MotionEstimator = cv::makePtr<cv::videostab::MotionEstimatorRansacL2>(model);

bool estimationOK;
cv::Mat M = MotionEstimator->estimate(KP1, KP0, &estimationOK);

Any ideas and/or comments would be of great help.

Thanks!!