13 #include <gtsam/nonlinear/Ordering.h> 15 namespace gtsam {
namespace partition {
20 template <
class NLG,
class SubNLG,
class GenericGraph>
39 NestedDissection(
const NLG& fg,
const Ordering& ordering,
const std::shared_ptr<Cuts>& cuts,
const bool verbose =
false);
43 sharedSubNLG
makeSubNLG(
const NLG& fg,
const std::vector<size_t>& frontals,
const std::vector<size_t>&
sep,
const std::shared_ptr<SubNLG>& parent)
const;
45 void processFactor(
const typename GenericGraph::value_type& factor,
const std::vector<int>& partitionTable,
46 std::vector<GenericGraph>& frontalFactors, NLG& sepFactors, std::vector<std::set<size_t> >& childSeps,
47 typename SubNLG::Weeklinks& weeklinks)
const;
52 const std::vector<size_t>&
keys,
const std::vector<int>& partitionTable,
const int numSubmaps,
53 std::vector<GenericGraph>& frontalFactors, vector<GenericUnaryGraph>& frontalUnaryFactors, NLG& sepFactors,
54 std::vector<std::vector<size_t> >& childFrontals, std::vector<std::vector<size_t> >& childSeps, std::vector<size_t>& localFrontals,
55 typename SubNLG::Weeklinks& weeklinks)
const;
61 const int numNodeStopPartition,
const int minNodesPerMap,
const std::shared_ptr<SubNLG>& parent,
WorkSpace& workspace,
const bool verbose)
const;
65 const std::shared_ptr<Cuts>& cuts,
const std::shared_ptr<SubNLG>& parent,
WorkSpace& workspace,
const bool verbose)
const;
NLG collectOriginalFactors(const GenericGraph &gfg, const GenericUnaryGraph &unaryFactors) const
std::vector< sharedGenericUnaryFactor > GenericUnaryGraph
static enum @1107 ordering
void processFactor(const typename GenericGraph::value_type &factor, const std::vector< int > &partitionTable, std::vector< GenericGraph > &frontalFactors, NLG &sepFactors, std::vector< std::set< size_t > > &childSeps, typename SubNLG::Weeklinks &weeklinks) const
void partitionFactorsAndVariables(const GenericGraph &fg, const GenericUnaryGraph &unaryFactors, const std::vector< size_t > &keys, const std::vector< int > &partitionTable, const int numSubmaps, std::vector< GenericGraph > &frontalFactors, vector< GenericUnaryGraph > &frontalUnaryFactors, NLG &sepFactors, std::vector< std::vector< size_t > > &childFrontals, std::vector< std::vector< size_t > > &childSeps, std::vector< size_t > &localFrontals, typename SubNLG::Weeklinks &weeklinks) const
sharedSubNLG root() const
sharedSubNLG recursivePartition(const GenericGraph &gfg, const GenericUnaryGraph &unaryFactors, const std::vector< size_t > &frontals, const std::vector< size_t > &sep, const int numNodeStopPartition, const int minNodesPerMap, const std::shared_ptr< SubNLG > &parent, WorkSpace &workspace, const bool verbose) const
std::shared_ptr< SubNLG > sharedSubNLG
std::vector< Symbol > int2symbol_
NestedDissection(const NLG &fg, const Ordering &ordering, const int numNodeStopPartition, const int minNodesPerMap, const bool verbose=false)
sharedSubNLG makeSubNLG(const NLG &fg, const std::vector< size_t > &frontals, const std::vector< size_t > &sep, const std::shared_ptr< SubNLG > &parent) const