Skip to content

Commit 5a2f1f8

Browse files
committed
Get rid of scale
1 parent 6457937 commit 5a2f1f8

File tree

2 files changed

+3
-5
lines changed

2 files changed

+3
-5
lines changed

gtsam/geometry/FundamentalMatrix.cpp

+2-2
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ FundamentalMatrix::FundamentalMatrix(const Matrix3& F) {
5959

6060
void FundamentalMatrix::initialize(const Matrix3& U, double s,
6161
const Matrix3& V) {
62-
s_ = s / kScale;
62+
s_ = s;
6363
sign_ = 1.0;
6464

6565
// Check if U is a reflection and flip U and sign_ if so
@@ -82,7 +82,7 @@ void FundamentalMatrix::initialize(const Matrix3& U, double s,
8282
}
8383

8484
Matrix3 FundamentalMatrix::matrix() const {
85-
return sign_ * U_.matrix() * Vector3(1.0, s_ * kScale, 0).asDiagonal() *
85+
return sign_ * U_.matrix() * Vector3(1.0, s_, 0).asDiagonal() *
8686
V_.transpose().matrix();
8787
}
8888

gtsam/geometry/FundamentalMatrix.h

+1-3
Original file line numberDiff line numberDiff line change
@@ -34,11 +34,9 @@ class GTSAM_EXPORT FundamentalMatrix {
3434
double s_; ///< Scalar parameter for S
3535
Rot3 V_; ///< Right rotation
3636

37-
static constexpr double kScale = 1000; // s is stored in s_ as s/kScale
38-
3937
public:
4038
/// Default constructor
41-
FundamentalMatrix() : U_(Rot3()), sign_(1.0), s_(1.0 / kScale), V_(Rot3()) {}
39+
FundamentalMatrix() : U_(Rot3()), sign_(1.0), s_(1.0), V_(Rot3()) {}
4240

4341
/**
4442
* @brief Construct from U, V, and scalar s

0 commit comments

Comments
 (0)