mirror of
https://github.com/introlab/rtabmap.git
synced 2026-10-06 18:17:47 +08:00
CI: use ubuntu arm runners instead of QEMU (#1771)
* CI: use ubuntu arm runners instead of QEMU * removed focal deps docker image ci * run tests in docker ci * revert temporary test * trigger ci jobs with modified files * ldconfig * arm64 ldconfig order * No response filtering here: cv::goodFeaturesToTrack() already applies GFTT/QualityLevel, relative to the best corner's measure. Re-applying it as an absolute floor on KeyPoint::response double-filtered (~86% of keypoints ropped on OpenCV 4.5), and dropped *every* keypoint on OpenCV < 4.5, whose GFTTDetector leaves response at 0. * fixing ExtractXYZCorrespondencesRANSAC ci error * increased windows timeout (probably caused by gftt fix now extracting more features)
This commit is contained in:
@@ -2282,20 +2282,6 @@ std::vector<cv::KeyPoint> GFTT::generateKeypointsImpl(const cv::Mat & image, con
|
||||
_gftt->detect(imgRoi, keypoints, maskRoi); // Opencv keypoints
|
||||
}
|
||||
|
||||
if(!_useHarrisDetector && _qualityLevel>0.0)
|
||||
{
|
||||
std::vector<cv::KeyPoint> bestKeypoints;
|
||||
bestKeypoints.reserve(keypoints.size());
|
||||
for(size_t i=0; i<keypoints.size(); ++i)
|
||||
{
|
||||
if(keypoints[i].response > _qualityLevel)
|
||||
{
|
||||
bestKeypoints.push_back(keypoints[i]);
|
||||
}
|
||||
}
|
||||
|
||||
return bestKeypoints;
|
||||
}
|
||||
return keypoints;
|
||||
}
|
||||
|
||||
|
||||
@@ -598,6 +598,30 @@ float StereoCameraModel::computeDisparity(unsigned short depth) const
|
||||
return baseline() * left().fx() / (float(depth)/1000.0f) - right().cx() + left().cx();
|
||||
}
|
||||
|
||||
void StereoCameraModel::reproject(float x, float y, float z, float & uLeft, float & vLeft, float & uRight, float & vRight) const
|
||||
{
|
||||
UASSERT(z!=0.0f);
|
||||
float invZ = 1.0f/z;
|
||||
// CameraModel::reproject() doesn't apply Tx, as a camera model with a Tx set is
|
||||
// also used to tag a left camera having stereo observations (see the stereo edges
|
||||
// of the BA optimizers). Here Tx is the baseline of the rectified projection
|
||||
// matrices (0 for the left camera, -fx*baseline for the right one), so that
|
||||
// (uLeft-uRight) is the disparity of the point.
|
||||
uLeft = (left_.fx()*x + left_.Tx())*invZ + left_.cx();
|
||||
vLeft = (left_.fy()*y)*invZ + left_.cy();
|
||||
uRight = (right_.fx()*x + right_.Tx())*invZ + right_.cx();
|
||||
vRight = (right_.fy()*y)*invZ + right_.cy();
|
||||
}
|
||||
void StereoCameraModel::reproject(float x, float y, float z, int & uLeft, int & vLeft, int & uRight, int & vRight) const
|
||||
{
|
||||
float uLeftF, vLeftF, uRightF, vRightF;
|
||||
this->reproject(x, y, z, uLeftF, vLeftF, uRightF, vRightF);
|
||||
uLeft = uLeftF;
|
||||
vLeft = vLeftF;
|
||||
uRight = uRightF;
|
||||
vRight = vRightF;
|
||||
}
|
||||
|
||||
Transform StereoCameraModel::stereoTransform() const
|
||||
{
|
||||
if(!R_.empty() && !T_.empty())
|
||||
|
||||
Reference in New Issue
Block a user