reprocess: fixed crash when odometry returns empty covariance. Also added more checks about that in the code in general.

This commit is contained in:
matlabbe
2025-10-09 14:44:13 -07:00
parent d60c15593d
commit 059cda85dc
7 changed files with 18 additions and 14 deletions
+1 -1
View File
@@ -858,7 +858,7 @@ SensorData DBReader::getNextData(SensorCaptureInfo * info)
info->odomPose = pose;
info->odomCovariance = infMatrix.inv();
info->odomVelocity = s->getVelocity();
UDEBUG("odom variance = %f/%f", info->odomCovariance.at<double>(0,0), info->odomCovariance.at<double>(5,5));
UDEBUG("odom variance = %f/%f", info->odomCovariance.empty()?0:info->odomCovariance.at<double>(0,0), info->odomCovariance.empty()?0:info->odomCovariance.at<double>(5,5));
}
}
delete s;