Skip to content

Commit 664cb92

Browse files
committed
fix: relax orthonormality tolerance to 1e-3
The 1e-5 tolerance was too tight and rejected rotation matrices constructed from rounded values (e.g. Matlab output with 4 decimal places), causing testSimilarity3 failures.
1 parent e86e2bf commit 664cb92

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

gtsam/geometry/Rot3.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ namespace gtsam {
3434
/* ************************************************************************* */
3535
void Rot3::IsValid(const Matrix3& R) {
3636
// Check R'R ≈ I (orthonormality)
37-
if ((R.transpose() * R - Matrix3::Identity()).norm() > 1e-5) {
37+
if ((R.transpose() * R - Matrix3::Identity()).norm() > 1e-3) {
3838
throw std::invalid_argument(
3939
"Rot3 constructor: matrix is not orthonormal. "
4040
"Use Rot3::ClosestTo() to find the closest valid rotation.");

0 commit comments

Comments
 (0)