diff options
author | Ulrich Bauer <ulrich.bauer@tum.de> | 2015-11-13 01:27:32 -0500 |
---|---|---|
committer | Ulrich Bauer <ulrich.bauer@tum.de> | 2015-11-13 01:27:32 -0500 |
commit | fb72e5364eca5112f0239a467d02d37f43063491 (patch) | |
tree | 80f965bf5fd29e85b8e604a6bec7431d439c5040 | |
parent | 59db7fbc7f8e21657dcc6866ad668514c118c48f (diff) |
reserve correct size for pivot lookup hash table
-rw-r--r-- | ripser.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
@@ -1223,6 +1223,7 @@ int main( int argc, char** argv ) { #endif std::unordered_map<index_t, index_t> pivot_column_index; + pivot_column_index.reserve(columns_to_reduce.size()); compute_pairs( columns_to_reduce, @@ -1258,6 +1259,7 @@ int main( int argc, char** argv ) { rips_filtration_comparator<decltype(dist)> comp(dist, dim + 1, binomial_coeff); std::unordered_map<index_t, index_t> pivot_column_index; + pivot_column_index.reserve(columns_to_reduce.size()); compute_pairs( columns_to_reduce, |