38 template <
class GRAPH_MATRIX,
typename num_t =
typename GRAPH_MATRIX::Scalar>
71 GRAPH_MATRIX& in_A, std::vector<std::vector<uint32_t>>& out_parts,
72 num_t threshold_Ncut = 1,
bool forceSimetry =
true,
73 bool useSpectralBisection =
true,
bool recursive =
true,
74 unsigned minSizeClusters = 1,
const bool verbose =
false);
101 GRAPH_MATRIX& in_A, std::vector<uint32_t>& out_part1,
102 std::vector<uint32_t>& out_part2, num_t& out_cut_value,
103 bool forceSimetry =
true);
130 GRAPH_MATRIX& in_A, std::vector<uint32_t>& out_part1,
131 std::vector<uint32_t>& out_part2, num_t& out_cut_value,
132 bool forceSimetry =
true);
138 const GRAPH_MATRIX& in_A,
const std::vector<uint32_t>& in_part1,
139 const std::vector<uint32_t>& in_part2);
static num_t nCut(const GRAPH_MATRIX &in_A, const std::vector< uint32_t > &in_part1, const std::vector< uint32_t > &in_part2)
Returns the normaliced cut of a graph, given its adjacency matrix A and a bisection: ...
static void exactBisection(GRAPH_MATRIX &in_A, std::vector< uint32_t > &out_part1, std::vector< uint32_t > &out_part2, num_t &out_cut_value, bool forceSimetry=true)
Performs an EXACT minimum n-Cut graph bisection, (Use CGraphPartitioner::SpectralBisection for a fast...
This is the global namespace for all Mobile Robot Programming Toolkit (MRPT) libraries.
static void RecursiveSpectralPartition(GRAPH_MATRIX &in_A, std::vector< std::vector< uint32_t >> &out_parts, num_t threshold_Ncut=1, bool forceSimetry=true, bool useSpectralBisection=true, bool recursive=true, unsigned minSizeClusters=1, const bool verbose=false)
Performs the spectral recursive partition into K-parts for a given graph.
static void SpectralBisection(GRAPH_MATRIX &in_A, std::vector< uint32_t > &out_part1, std::vector< uint32_t > &out_part2, num_t &out_cut_value, bool forceSimetry=true)
Performs the spectral bisection of a graph.
Finds the min-normalized-cut of a weighted undirected graph.