aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/hyperloglog/hyperloglog.cpp
diff options
context:
space:
mode:
authorIvan Blinkov <ivan@blinkov.ru>2022-02-10 16:47:11 +0300
committerDaniil Cherednik <dcherednik@yandex-team.ru>2022-02-10 16:47:11 +0300
commit5b283123c882433dafbaf6b338adeea16c1a0ea0 (patch)
tree339adc63bce23800021202ae4a8328a843dc447a /library/cpp/hyperloglog/hyperloglog.cpp
parent1aeb9a455974457866f78722ad98114bafc84e8a (diff)
downloadydb-5b283123c882433dafbaf6b338adeea16c1a0ea0.tar.gz
Restoring authorship annotation for Ivan Blinkov <ivan@blinkov.ru>. Commit 2 of 2.
Diffstat (limited to 'library/cpp/hyperloglog/hyperloglog.cpp')
-rw-r--r--library/cpp/hyperloglog/hyperloglog.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/library/cpp/hyperloglog/hyperloglog.cpp b/library/cpp/hyperloglog/hyperloglog.cpp
index 35cae80268..ec8352abe1 100644
--- a/library/cpp/hyperloglog/hyperloglog.cpp
+++ b/library/cpp/hyperloglog/hyperloglog.cpp
@@ -1,4 +1,4 @@
-#include "hyperloglog.h"
+#include "hyperloglog.h"
#include <util/generic/bitops.h>
#include <util/generic/yexception.h>
@@ -39,18 +39,18 @@ namespace {
};
double EstimateBias(double e, unsigned precision) {
- static const TCorrection CORRECTIONS[1 + THyperLogLog::PRECISION_MAX - THyperLogLog::PRECISION_MIN] = {
+ static const TCorrection CORRECTIONS[1 + THyperLogLog::PRECISION_MAX - THyperLogLog::PRECISION_MIN] = {
#include "hyperloglog_corrections.inc"
};
- if (precision < THyperLogLog::PRECISION_MIN || precision > THyperLogLog::PRECISION_MAX) {
+ if (precision < THyperLogLog::PRECISION_MIN || precision > THyperLogLog::PRECISION_MAX) {
return 0.;
}
- return CORRECTIONS[precision - THyperLogLog::PRECISION_MIN].GetBias(e);
+ return CORRECTIONS[precision - THyperLogLog::PRECISION_MIN].GetBias(e);
}
double GetThreshold(unsigned precision) {
- static const double THRESHOLD_DATA[1 + THyperLogLog::PRECISION_MAX - THyperLogLog::PRECISION_MIN] = {
+ static const double THRESHOLD_DATA[1 + THyperLogLog::PRECISION_MAX - THyperLogLog::PRECISION_MIN] = {
10, // Precision 4
20, // Precision 5
40, // Precision 6
@@ -67,11 +67,11 @@ namespace {
120000, // Precision 17
350000 // Precision 18
};
- if (precision < THyperLogLog::PRECISION_MIN || precision > THyperLogLog::PRECISION_MAX) {
+ if (precision < THyperLogLog::PRECISION_MIN || precision > THyperLogLog::PRECISION_MAX) {
return 0.;
}
- return THRESHOLD_DATA[precision - THyperLogLog::PRECISION_MIN];
+ return THRESHOLD_DATA[precision - THyperLogLog::PRECISION_MIN];
}
double EmpiricAlpha(size_t m) {