alpha
Login
or
Join now
urschrei.eurosky.social
/
cvmcount
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Rust implementation of the CVM algorithm for counting distinct elements in a stream
Star
0
Fork
0
Atom
Configure Feed
Issues
Pull Requests
Commits
Tags
Feed URL
Select the types of activity you want to include in your feed.
Overview
Issues
Pulls
Pipelines
Update version, edition, and MSRV
author
Stephan Hügel
date
1 year ago
(Jun 29, 2025, 10:58 PM +0100)
commit
52b6a128
52b6a128300cfcaf7e22e0694d8a8b1d847e6d45
parent
95f466f2
95f466f2a9f0de9b2d6dd6056ef2c3caaff1f27a
change-id
proktvpx
proktvpxvozqlyvwnpostlpzmmkvprpx
+4
-3
2 changed files
Expand all
Collapse all
Unified
Split
Cargo.toml
src
treap.rs
+3
-2
Cargo.toml
Reviewed
···
7
7
documentation = "https://docs.rs/cvmcount"
8
8
keywords = ["CVM", "count-distinct", "estimation", "treap"]
9
9
categories = ["algorithms", ]
10
10
+
rust-version = "1.85"
10
11
11
11
-
version = "0.3.1"
12
12
-
edition = "2021"
12
12
+
version = "0.4.0"
13
13
+
edition = "2024"
13
14
14
15
[dependencies]
15
16
rand = "0.8.5"
+1
-1
src/treap.rs
Reviewed
···
84
84
85
85
/// Insert a key with a random priority
86
86
pub fn insert<R: Rng>(&mut self, key: T, rng: &mut R) {
87
87
-
let priority = rng.gen();
87
87
+
let priority = rng.r#gen();
88
88
self.root = Self::insert_node(self.root.take(), key, priority);
89
89
self.size += 1;
90
90
}