(in branch) disabled key ordering checks for ISAM2

release/4.3a0
Richard Roberts 2011-08-18 15:45:20 +00:00
parent 32a0146722
commit 1936f34f22
2 changed files with 7 additions and 7 deletions

View File

@ -47,11 +47,11 @@ namespace gtsam {
void BayesTree<CONDITIONAL>::Clique::assertInvariants() const { void BayesTree<CONDITIONAL>::Clique::assertInvariants() const {
#ifndef NDEBUG #ifndef NDEBUG
// We rely on the keys being sorted // We rely on the keys being sorted
FastVector<Index> sortedUniqueKeys(conditional_->begin(), conditional_->end()); // FastVector<Index> sortedUniqueKeys(conditional_->begin(), conditional_->end());
std::sort(sortedUniqueKeys.begin(), sortedUniqueKeys.end()); // std::sort(sortedUniqueKeys.begin(), sortedUniqueKeys.end());
std::unique(sortedUniqueKeys.begin(), sortedUniqueKeys.end()); // std::unique(sortedUniqueKeys.begin(), sortedUniqueKeys.end());
assert(sortedUniqueKeys.size() == conditional_->size() && // assert(sortedUniqueKeys.size() == conditional_->size() &&
std::equal(sortedUniqueKeys.begin(), sortedUniqueKeys.end(), conditional_->begin())); // std::equal(sortedUniqueKeys.begin(), sortedUniqueKeys.end(), conditional_->begin()));
#endif #endif
} }

View File

@ -36,8 +36,8 @@ namespace gtsam {
FastSet<Index> uniquesorted(beginFrontals(), endFrontals()); FastSet<Index> uniquesorted(beginFrontals(), endFrontals());
assert(uniquesorted.size() == nrFrontals() && std::equal(uniquesorted.begin(), uniquesorted.end(), beginFrontals())); assert(uniquesorted.size() == nrFrontals() && std::equal(uniquesorted.begin(), uniquesorted.end(), beginFrontals()));
// Check that separator keys are less than parent keys // Check that separator keys are less than parent keys
BOOST_FOREACH(Index j, frontals()) { //BOOST_FOREACH(Index j, frontals()) {
assert(find_if(beginParents(), endParents(), _1 < j) == endParents()); } // assert(find_if(beginParents(), endParents(), _1 < j) == endParents()); }
#endif #endif
} }