Bug fix in debug checks - don't check lower triangle of Hessian because only the upper triangle is used
parent
790599799c
commit
7e901f4fad
|
|
@ -58,7 +58,7 @@ namespace gtsam {
|
||||||
#ifndef NDEBUG
|
#ifndef NDEBUG
|
||||||
// Check for non-finite values
|
// Check for non-finite values
|
||||||
for(size_t i=0; i<matrix_.size1(); ++i)
|
for(size_t i=0; i<matrix_.size1(); ++i)
|
||||||
for(size_t j=0; j<matrix_.size2(); ++j)
|
for(size_t j=i; j<matrix_.size2(); ++j)
|
||||||
if(!isfinite(matrix_(i,j)))
|
if(!isfinite(matrix_(i,j)))
|
||||||
throw invalid_argument("HessianFactor contains non-finite matrix entries.");
|
throw invalid_argument("HessianFactor contains non-finite matrix entries.");
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue