RGBD/LinearUpdate and RGBD/AngularUpdate: updated description and now require both to be 0 to skip motion check.

This commit is contained in:
matlabbe
2025-10-28 20:56:54 -07:00
parent 1def668578
commit 210aadb92b
7 changed files with 18 additions and 11 deletions

View File

@@ -1544,9 +1544,10 @@ bool Rtabmap::process(
{
float x,y,z, roll,pitch,yaw;
t.getTranslationAndEulerAngles(x,y,z, roll,pitch,yaw);
bool isMoving = fabs(x) > _rgbdLinearUpdate ||
fabs(y) > _rgbdLinearUpdate ||
fabs(z) > _rgbdLinearUpdate ||
bool isMoving = (_rgbdLinearUpdate > 0.0f) && (
fabs(x) > _rgbdLinearUpdate ||
fabs(y) > _rgbdLinearUpdate ||
fabs(z) > _rgbdLinearUpdate) ||
(_rgbdAngularUpdate>0.0f && (
fabs(roll) > _rgbdAngularUpdate ||
fabs(pitch) > _rgbdAngularUpdate ||

View File

@@ -216,7 +216,7 @@ std::map<int, Transform> OptimizerG2O::optimize(
outputCovariance = cv::Mat::eye(6,6,CV_64FC1);
std::map<int, Transform> optimizedPoses;
#ifdef RTABMAP_G2O
UDEBUG("Optimizing graph...");
UDEBUG("Optimizing graph... (rootId=%d)", rootId);
#ifndef RTABMAP_VERTIGO
if(this->isRobust())
@@ -348,6 +348,9 @@ std::map<int, Transform> OptimizerG2O::optimize(
{
if(!priorsIgnored() && iter->second.type() == Link::kPosePrior)
{
if(rootId!=0) {
UDEBUG("Removed rootId=%d because there are priors.");
}
rootId = 0;
break;
}