Merge pull request #1965 from MagnusAagaard/develop

Fix BilinearAngleTranslationFactor part of TranslationFactor
release/4.3a0
Frank Dellaert 2025-01-08 08:58:37 -05:00 committed by GitHub
commit 8315ea75d8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with 1 additions and 1 deletions

View File

@ -134,7 +134,7 @@ class BilinearAngleTranslationFactor
OptionalMatrixType H1, OptionalMatrixType H2, OptionalMatrixType H1, OptionalMatrixType H2,
OptionalMatrixType H3) const override { OptionalMatrixType H3) const override {
// Ideally we should use a positive real valued scalar datatype for scale. // Ideally we should use a positive real valued scalar datatype for scale.
const double abs_scale = abs(scale[0]); const double abs_scale = std::abs(scale[0]);
const Point3 predicted = (Tb - Ta) * abs_scale; const Point3 predicted = (Tb - Ta) * abs_scale;
if (H1) { if (H1) {
*H1 = -Matrix3::Identity() * abs_scale; *H1 = -Matrix3::Identity() * abs_scale;