Implements Compressed Node Based Graph (De-)Serialization Skeleton

Implements parallel recursion for the partitioner
Fixes osrm-extract's -dump-partition-graph: accept no further tokens

References:
- http://www.boost.org/doc/libs/1_55_0/doc/html/boost/program_options/bool_switch.html

Pulls parameters through to make them configurable from the outside

Defaults are equivalent to:

    ./osrm-partition \
      berlin-latest.osrm \
      --max-cell-size 4096 \
      --balance 1.2 \
      --boundary 0.25 \
      --optimizing-cuts 10

Fixes parallel_do call for Intel TBB 4.2 (Trusty): no range-based overload
This commit is contained in:
Daniel J. Hofmann
2017-01-26 17:53:19 +01:00
committed by Patrick Niklaus
parent 786be6f570
commit b9ed20bb9b
10 changed files with 327 additions and 85 deletions
+7
View File
@@ -31,15 +31,22 @@ struct PartitionConfig
}
edge_based_graph_path = basepath + ".osrm.ebg";
compressed_node_based_graph_path = basepath + ".osrm.cnbg";
partition_path = basepath + ".osrm.partition";
}
// might be changed to the node based graph at some point
boost::filesystem::path base_path;
boost::filesystem::path edge_based_graph_path;
boost::filesystem::path compressed_node_based_graph_path;
boost::filesystem::path partition_path;
unsigned requested_num_threads;
std::size_t maximum_cell_size;
double balance;
double boundary_factor;
std::size_t num_optimizing_cuts;
};
}
}
+1 -1
View File
@@ -125,7 +125,7 @@ template <typename NodeEntryT, typename EdgeEntryT> class RemappableGraph
const auto remaining_edges = std::distance(BeginEdges(node), center);
node.edges_end = node.edges_begin + remaining_edges;
return center;
};
}
protected:
std::vector<NodeT> nodes;
@@ -19,6 +19,7 @@ class RecursiveBisection
RecursiveBisection(std::size_t maximum_cell_size,
double balance,
double boundary_factor,
std::size_t num_optimizing_cuts,
BisectionGraph &bisection_graph);
private: