You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datasketches.apache.org by al...@apache.org on 2020/06/22 21:52:19 UTC
[incubator-datasketches-cpp] branch tuple_sketch updated: fixed
initial size
This is an automated email from the ASF dual-hosted git repository.
alsay pushed a commit to branch tuple_sketch
in repository https://gitbox.apache.org/repos/asf/incubator-datasketches-cpp.git
The following commit(s) were added to refs/heads/tuple_sketch by this push:
new eed2eb9 fixed initial size
eed2eb9 is described below
commit eed2eb9c6caad1ee4fd445d1a55c4d9aa04639cf
Author: AlexanderSaydakov <Al...@users.noreply.github.com>
AuthorDate: Mon Jun 22 14:52:08 2020 -0700
fixed initial size
---
tuple/include/theta_update_sketch_base_impl.hpp | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/tuple/include/theta_update_sketch_base_impl.hpp b/tuple/include/theta_update_sketch_base_impl.hpp
index f65f3e9..ff4492d 100644
--- a/tuple/include/theta_update_sketch_base_impl.hpp
+++ b/tuple/include/theta_update_sketch_base_impl.hpp
@@ -35,7 +35,7 @@ theta_(theta_constants::MAX_THETA),
seed_(seed),
entries_(nullptr)
{
- const size_t size = 1 << (lg_cur_size + 1);
+ const size_t size = 1 << lg_cur_size;
entries_ = A().allocate(size);
for (size_t i = 0; i < size; ++i) EK()(entries_[i]) = 0;
if (p < 1) this->theta_ *= p;
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datasketches.apache.org
For additional commands, e-mail: commits-help@datasketches.apache.org