Added exception handling code but has not yet been exercised! Chris will do so...
parent
e56b6ff392
commit
0e3b96db60
|
@ -323,7 +323,15 @@ namespace gtsam {
|
||||||
// some untouched non-zeros that should be zero. We zero them while
|
// some untouched non-zeros that should be zero. We zero them while
|
||||||
// extracting submatrices next.
|
// extracting submatrices next.
|
||||||
tic(4, "partial Cholesky");
|
tic(4, "partial Cholesky");
|
||||||
combinedFactor->partialCholesky(nrFrontals);
|
try {
|
||||||
|
combinedFactor->partialCholesky(nrFrontals);
|
||||||
|
} catch
|
||||||
|
(std::exception &ex) { // catch exception from Cholesky
|
||||||
|
combinedFactor->print("combinedFactor");
|
||||||
|
string reason = "EliminateCholesky failed while trying to eliminate the combined factor";
|
||||||
|
throw invalid_argument(reason);
|
||||||
|
}
|
||||||
|
|
||||||
toc(4, "partial Cholesky");
|
toc(4, "partial Cholesky");
|
||||||
|
|
||||||
// Extract conditionals and fill in details of the remaining factor
|
// Extract conditionals and fill in details of the remaining factor
|
||||||
|
|
Loading…
Reference in New Issue