Theta base builder.
More...
#include <theta_update_sketch_base.hpp>
|
| theta_base_builder (const Allocator &allocator) |
| Creates and instance of the builder with default parameters.
|
|
Derived & | set_lg_k (uint8_t lg_k) |
| Set log2(k), where k is a nominal number of entries in the sketch.
|
|
Derived & | set_resize_factor (resize_factor rf) |
| Set resize factor for the internal hash table (defaults to 8)
|
|
Derived & | set_p (float p) |
| Set sampling probability (initial theta).
|
|
Derived & | set_seed (uint64_t seed) |
| Set the seed for the hash function.
|
|
template<typename Derived, typename Allocator>
class datasketches::theta_base_builder< Derived, Allocator >
Theta base builder.
◆ theta_base_builder()
template<typename Derived , typename Allocator >
Creates and instance of the builder with default parameters.
- Parameters
-
allocator | instance of an Allocator to pass to created sketches |
◆ set_lg_k()
template<typename Derived , typename Allocator >
Derived & set_lg_k |
( |
uint8_t |
lg_k | ) |
|
Set log2(k), where k is a nominal number of entries in the sketch.
- Parameters
-
lg_k | base 2 logarithm of nominal number of entries |
- Returns
- this builder
◆ set_resize_factor()
template<typename Derived , typename Allocator >
Derived & set_resize_factor |
( |
resize_factor |
rf | ) |
|
Set resize factor for the internal hash table (defaults to 8)
- Parameters
-
- Returns
- this builder
◆ set_p()
template<typename Derived , typename Allocator >
Derived & set_p |
( |
float |
p | ) |
|
Set sampling probability (initial theta).
The default is 1, so the sketch retains all entries until it reaches the limit, at which point it goes into the estimation mode and reduces the effective sampling probability (theta) as necessary.
- Parameters
-
- Returns
- this builder
◆ set_seed()
template<typename Derived , typename Allocator >
Derived & set_seed |
( |
uint64_t |
seed | ) |
|
Set the seed for the hash function.
Should be used carefully if needed. Sketches produced with different seed are not compatible and cannot be mixed in set operations.
- Parameters
-
- Returns
- this builder
The documentation for this class was generated from the following files: