diff options
author | fgodi <fgodi@636b058d-ea47-450e-bf9e-a15bfbe3eedb> | 2018-05-23 12:49:36 +0000 |
---|---|---|
committer | fgodi <fgodi@636b058d-ea47-450e-bf9e-a15bfbe3eedb> | 2018-05-23 12:49:36 +0000 |
commit | 68443280388d3a83adc3f927b3252b2debafb11c (patch) | |
tree | b37f4308f6c0fa67377f04ae05102dae6a66f1cc /src/Toplex_map/include/gudhi/Lazy_Toplex_map.h | |
parent | db4d235b9f7995351f3d4559a132dfe15f30b655 (diff) |
strange
git-svn-id: svn+ssh://scm.gforge.inria.fr/svnroot/gudhi/branches/toplex_map@3454 636b058d-ea47-450e-bf9e-a15bfbe3eedb
Former-commit-id: 9860c0af5c014faeb5d16b81e1fafa8a4eb27786
Diffstat (limited to 'src/Toplex_map/include/gudhi/Lazy_Toplex_map.h')
-rw-r--r-- | src/Toplex_map/include/gudhi/Lazy_Toplex_map.h | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/Toplex_map/include/gudhi/Lazy_Toplex_map.h b/src/Toplex_map/include/gudhi/Lazy_Toplex_map.h index 396961fe..31f3da4b 100644 --- a/src/Toplex_map/include/gudhi/Lazy_Toplex_map.h +++ b/src/Toplex_map/include/gudhi/Lazy_Toplex_map.h @@ -175,7 +175,7 @@ inline void Lazy_Toplex_map::erase_max(const Input_vertex_range &vertex_range){ Simplex sigma(vertex_range.begin(),vertex_range.end()); empty_toplex = false; Simplex_ptr sptr = std::make_shared<Simplex>(sigma); - bool erased; + bool erased=false; for(const Vertex& v : sigma){ erased = t0.at(v).erase(sptr) > 0; if(t0.at(v).size()==0) @@ -206,17 +206,17 @@ std::size_t Lazy_Toplex_map::get_gamma0_lbound(const Vertex v) const{ void Lazy_Toplex_map::clean(const Vertex v){ Toplex_map toplices; std::unordered_map<int, std::vector<Simplex>> dsorted_simplices; - int max_dim = 0; + std::size_t max_dim = 0; for(const Simplex_ptr& sptr : Simplex_ptr_set(t0.at(v))){ if(sptr->size() > max_dim){ - for(int d = max_dim+1; d<=sptr->size(); d++) + for(std::size_t d = max_dim+1; d<=sptr->size(); d++) dsorted_simplices.emplace(d, std::vector<Simplex>()); max_dim = sptr->size(); } dsorted_simplices[sptr->size()].emplace_back(*sptr); erase_max(*sptr); } - for(int d = max_dim; d>=1; d--) + for(std::size_t d = max_dim; d>=1; d--) for(const Simplex &s : dsorted_simplices.at(d)) if(!toplices.membership(s)) toplices.insert_independent_simplex(s); |