From 00b4b3c3ac898b09d3e48cf96c2af78ab3515690 Mon Sep 17 00:00:00 2001 From: Ian Henriksen Date: Thu, 20 Aug 2020 08:18:56 -0500 Subject: [PATCH 1/2] Disable Louvain partitioning test in CI. --- lonestar/analytics/cpu/louvain-partitioning/CMakeLists.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lonestar/analytics/cpu/louvain-partitioning/CMakeLists.txt b/lonestar/analytics/cpu/louvain-partitioning/CMakeLists.txt index c6c48d160d..516a19a18d 100644 --- a/lonestar/analytics/cpu/louvain-partitioning/CMakeLists.txt +++ b/lonestar/analytics/cpu/louvain-partitioning/CMakeLists.txt @@ -2,4 +2,4 @@ add_executable(louvain-partitioning-cpu louvain-partitioning.cpp serial-partitio add_dependencies(apps louvain-partitioning-cpu) target_link_libraries(louvain-partitioning-cpu PRIVATE Galois::shmem lonestar) install(TARGETS louvain-partitioning-cpu DESTINATION "${CMAKE_INSTALL_BINDIR}" COMPONENT apps EXCLUDE_FROM_ALL) -add_test_scale(small1 louvain-partitioning-cpu -symmetricGraph "${BASEINPUT}/scalefree/symmetric/rmat10.sgr") +add_test_scale(small1 louvain-partitioning-cpu -symmetricGraph "${BASEINPUT}/scalefree/symmetric/rmat10.sgr" NOT_QUICK) From dbaf827dc6e7e957b5a7fa2f89a29e96ef05a58f Mon Sep 17 00:00:00 2001 From: Ian Henriksen Date: Thu, 20 Aug 2020 09:17:48 -0500 Subject: [PATCH 2/2] Fix format broken by others. --- lonestar/analytics/cpu/bipart/Coarsening.cpp | 21 +++++++++---------- .../louvain-partitioning.h | 5 ++--- lonestar/libdistbench/src/Input.cpp | 4 ++-- 3 files changed, 14 insertions(+), 16 deletions(-) diff --git a/lonestar/analytics/cpu/bipart/Coarsening.cpp b/lonestar/analytics/cpu/bipart/Coarsening.cpp index cb42539971..cd4f37daf7 100644 --- a/lonestar/analytics/cpu/bipart/Coarsening.cpp +++ b/lonestar/analytics/cpu/bipart/Coarsening.cpp @@ -177,7 +177,7 @@ void parallelHMatchAndCreateNodes(MetisGraph* graph, int iter, GNodeBag& bag, galois::GAccumulator hedge; // hyperedge coarsening - galois::InsertBag hedge_bag; + galois::InsertBag hedge_bag; galois::do_all( galois::iterate(size_t{0}, fineGGraph->hedges), @@ -215,8 +215,8 @@ void parallelHMatchAndCreateNodes(MetisGraph* graph, int iter, GNodeBag& bag, return; fineGGraph->getData(item).setMatched(); if (flag) - hedge_bag.push(item); - // hedges[item] = true; + hedge_bag.push(item); + // hedges[item] = true; bag.push(nodeid); unsigned ww = 0; for (auto pp : edges) { @@ -230,8 +230,8 @@ void parallelHMatchAndCreateNodes(MetisGraph* graph, int iter, GNodeBag& bag, }, galois::loopname("phaseI")); - for(auto item: hedge_bag) - hedges[item] = true; + for (auto item : hedge_bag) + hedges[item] = true; } void moreCoarse(MetisGraph* graph, std::vector& weight) { @@ -346,13 +346,13 @@ void coarsePhaseII(MetisGraph* graph, std::vector& hedges, } else { hedge_bag.push(item); - fineGGraph->getData(item).setMatched(); + fineGGraph->getData(item).setMatched(); } }, galois::loopname("count # Hyperedges")); - for(auto item: hedge_bag) - hedges[item] = true; + for (auto item : hedge_bag) + hedges[item] = true; } void parallelCreateEdges(MetisGraph* graph, GNodeBag& bag, @@ -383,7 +383,7 @@ void parallelCreateEdges(MetisGraph* graph, GNodeBag& bag, }, galois::steal(), galois::loopname("noedgebag match")); unsigned hnum = hg.reduce(); - unsigned nodes = std::distance(bag.begin(), bag.end()); + unsigned nodes = std::distance(bag.begin(), bag.end()); unsigned newval = hnum; std::vector idmap(fineGGraph->hnodes); std::vector newrand(nodes); @@ -469,8 +469,7 @@ void parallelCreateEdges(MetisGraph* graph, GNodeBag& bag, coarseGGraph->getData(ii).netval = INT_MAX; coarseGGraph->getData(ii).netnum = INT_MAX; coarseGGraph->getData(ii).netrand = INT_MAX; - coarseGGraph->getData(ii).nodeid = - ii; + coarseGGraph->getData(ii).nodeid = ii; coarseGGraph->getData(ii).setWeight( newWeight[ii - coarseGGraph->hedges]); } diff --git a/lonestar/analytics/cpu/louvain-partitioning/louvain-partitioning.h b/lonestar/analytics/cpu/louvain-partitioning/louvain-partitioning.h index a449df11cd..70698076b4 100644 --- a/lonestar/analytics/cpu/louvain-partitioning/louvain-partitioning.h +++ b/lonestar/analytics/cpu/louvain-partitioning/louvain-partitioning.h @@ -202,9 +202,8 @@ double calModularityDelay(GraphTy& graph, double& e_xx, } }); - galois::do_all(galois::iterate(graph), [&](GNode n) { - acc_e_xx += cluster_wt_internal[n]; - }); + galois::do_all(galois::iterate(graph), + [&](GNode n) { acc_e_xx += cluster_wt_internal[n]; }); e_xx = acc_e_xx.reduce(); diff --git a/lonestar/libdistbench/src/Input.cpp b/lonestar/libdistbench/src/Input.cpp index e6f61dc6ff..495f68c0c5 100644 --- a/lonestar/libdistbench/src/Input.cpp +++ b/lonestar/libdistbench/src/Input.cpp @@ -37,8 +37,8 @@ cll::opt inputFileTranspose("graphTranspose", cll::init("")); cll::opt symmetricGraph("symmetricGraph", - cll::desc("Specify that the input graph is symmetric"), - cll::init(false)); + cll::desc("Specify that the input graph is symmetric"), + cll::init(false)); cll::opt partitionScheme( "partition", cll::desc("Type of partitioning."),