@@ -35,9 +35,7 @@ int main(int argc, char *argv[]) {
3535 }
3636
3737 std::string graph_file = argv[1 ];
38- std::string graph_name = graph_file.substr (graph_file.rfind (" /" ) + 1 ,
39- graph_file.rfind (" ." ) - graph_file.rfind (" /" ) - 1 );
40-
38+ std::string graph_name = graph_file.substr (graph_file.rfind (" /" ) + 1 , graph_file.rfind (" ." ) - graph_file.rfind (" /" ) - 1 );
4139
4240 Graph_t graph;
4341 bool status = file_reader::readGraph (graph_file, graph);
@@ -46,8 +44,7 @@ int main(int argc, char *argv[]) {
4644 return 1 ;
4745 }
4846
49-
50- SarkarParams::MulParameters< v_workw_t <Graph_t> > params;
47+ SarkarParams::MulParameters<v_workw_t <Graph_t>> params;
5148 params.commCostVec = std::vector<v_workw_t <Graph_t>>({1 , 2 , 5 , 10 , 20 , 50 , 100 , 200 , 500 , 1000 });
5249 params.max_num_iteration_without_changes = 3 ;
5350 params.leniency = 0.005 ;
@@ -63,7 +60,7 @@ int main(int argc, char *argv[]) {
6360
6461 Graph_t graph_copy = graph;
6562 bool ignore_vertex_types = false ;
66-
63+
6764 if (ignore_vertex_types) {
6865 for (const auto &vert : graph_copy.vertices ()) {
6966 graph_copy.set_vertex_type (vert, 0 );
@@ -74,7 +71,7 @@ int main(int argc, char *argv[]) {
7471
7572 std::vector<unsigned > colours (contraction_map.size ());
7673 for (std::size_t i = 0 ; i < contraction_map.size (); ++i) {
77- colours[i] = static_cast <unsigned >( contraction_map[i] );
74+ colours[i] = static_cast <unsigned >(contraction_map[i]);
7875 }
7976
8077 std::ofstream out_dot (argv[2 ]);
@@ -86,7 +83,7 @@ int main(int argc, char *argv[]) {
8683 DotFileWriter writer;
8784 writer.write_colored_graph (out_dot, graph, colours);
8885
89- if (argc >=4 ) {
86+ if (argc >= 4 ) {
9087 std::ofstream coarse_out_dot (argv[3 ]);
9188 if (!coarse_out_dot.is_open ()) {
9289 std::cout << " Unable to write/open output file.\n " ;
@@ -100,4 +97,4 @@ int main(int argc, char *argv[]) {
10097 }
10198
10299 return 0 ;
103- }
100+ }
0 commit comments