From 08c20aeaacc81433975a0cf5064e7438e85698a7 Mon Sep 17 00:00:00 2001 From: Tobias Heuer Date: Mon, 24 Jul 2023 10:51:18 +0200 Subject: [PATCH] minor --- mt-kahypar/datastructures/delta_partitioned_graph.h | 1 - mt-kahypar/partition/partitioner.cpp | 7 +++---- mt-kahypar/partition/refinement/fm/multitry_kway_fm.cpp | 2 +- 3 files changed, 4 insertions(+), 6 deletions(-) diff --git a/mt-kahypar/datastructures/delta_partitioned_graph.h b/mt-kahypar/datastructures/delta_partitioned_graph.h index cf11372c6..3fc9fdde1 100644 --- a/mt-kahypar/datastructures/delta_partitioned_graph.h +++ b/mt-kahypar/datastructures/delta_partitioned_graph.h @@ -200,7 +200,6 @@ class DeltaPartitionedGraph { sync_update.edge_size = _pg->edgeSize(edge); sync_update.pin_count_in_from_part_after = target_part == from ? 1 : 0; sync_update.pin_count_in_to_part_after = target_part == to ? 2 : 1; - // TODO: deep copy of connectivity set required here delta_func(sync_update); } return true; diff --git a/mt-kahypar/partition/partitioner.cpp b/mt-kahypar/partition/partitioner.cpp index 1b7b96ceb..e5ee71a79 100644 --- a/mt-kahypar/partition/partitioner.cpp +++ b/mt-kahypar/partition/partitioner.cpp @@ -234,7 +234,7 @@ namespace mt_kahypar { } template - void preprocess(Hypergraph& hypergraph, Context& context, TargetGraph* target_graph, const bool is_vcycle) { + void preprocess(Hypergraph& hypergraph, Context& context, TargetGraph* target_graph) { bool use_community_detection = context.preprocessing.use_community_detection; bool is_graph = false; @@ -248,7 +248,7 @@ namespace mt_kahypar { timer.stop_timer("detect_graph_structure"); } - if ( use_community_detection && !is_vcycle ) { + if ( use_community_detection ) { io::printTopLevelPreprocessingBanner(context); timer.start_timer("community_detection", "Community Detection"); @@ -301,7 +301,7 @@ namespace mt_kahypar { timer.start_timer("preprocessing", "Preprocessing"); DegreeZeroHypernodeRemover degree_zero_hn_remover(context); LargeHyperedgeRemover large_he_remover(context); - preprocess(hypergraph, context, target_graph, false); + preprocess(hypergraph, context, target_graph); sanitize(hypergraph, context, degree_zero_hn_remover, large_he_remover); timer.stop_timer("preprocessing"); @@ -368,7 +368,6 @@ namespace mt_kahypar { timer.start_timer("preprocessing", "Preprocessing"); DegreeZeroHypernodeRemover degree_zero_hn_remover(context); LargeHyperedgeRemover large_he_remover(context); - preprocess(hypergraph, context, target_graph, true); sanitize(hypergraph, context, degree_zero_hn_remover, large_he_remover); timer.stop_timer("preprocessing"); diff --git a/mt-kahypar/partition/refinement/fm/multitry_kway_fm.cpp b/mt-kahypar/partition/refinement/fm/multitry_kway_fm.cpp index a68f5930c..f2e81a831 100644 --- a/mt-kahypar/partition/refinement/fm/multitry_kway_fm.cpp +++ b/mt-kahypar/partition/refinement/fm/multitry_kway_fm.cpp @@ -154,7 +154,7 @@ namespace mt_kahypar { metrics.quality -= overall_improvement; metrics.imbalance = metrics::imbalance(phg, context); - ASSERT(phg.checkTrackedPartitionInformation(gain_cache)); + HEAVY_REFINEMENT_ASSERT(phg.checkTrackedPartitionInformation(gain_cache)); ASSERT(metrics.quality == metrics::quality(phg, context), V(metrics.quality) << V(metrics::quality(phg, context))); return overall_improvement > 0;