pyhyperminhash 0.1.5__tar.gz → 0.2.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/Cargo.lock +78 -116
- pyhyperminhash-0.2.0/Cargo.toml +46 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/PKG-INFO +33 -6
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/README.md +32 -5
- pyhyperminhash-0.2.0/examples/bench.py +268 -0
- pyhyperminhash-0.2.0/pyhyperminhash.pyi +59 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/pyproject.toml +3 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/src/lib.rs +117 -31
- pyhyperminhash-0.2.0/tests/test_pyhyperminhash.py +323 -0
- pyhyperminhash-0.1.5/.github/workflows/CI.yml +0 -285
- pyhyperminhash-0.1.5/.github/workflows/check.yml +0 -68
- pyhyperminhash-0.1.5/.gitignore +0 -3
- pyhyperminhash-0.1.5/Cargo.toml +0 -25
- pyhyperminhash-0.1.5/pyhyperminhash.pyi +0 -38
- pyhyperminhash-0.1.5/tests/test_pyhyperminhash.py +0 -197
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/LICENSE +0 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/build.rs +0 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/examples/large_file.py +0 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/examples/simple.py +0 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/examples/sqlite_agg.py +0 -0
- {pyhyperminhash-0.1.5 → pyhyperminhash-0.2.0}/examples/unique_files.py +0 -0
|
@@ -2,12 +2,6 @@
|
|
|
2
2
|
# It is not intended for manual editing.
|
|
3
3
|
version = 4
|
|
4
4
|
|
|
5
|
-
[[package]]
|
|
6
|
-
name = "autocfg"
|
|
7
|
-
version = "1.5.0"
|
|
8
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
9
|
-
checksum = "c08606f8c3cbf4ce6ec8e28fb0014a2c086708fe954eaa885384a6165172e7e8"
|
|
10
|
-
|
|
11
5
|
[[package]]
|
|
12
6
|
name = "built"
|
|
13
7
|
version = "0.8.0"
|
|
@@ -64,9 +58,9 @@ dependencies = [
|
|
|
64
58
|
|
|
65
59
|
[[package]]
|
|
66
60
|
name = "hashbrown"
|
|
67
|
-
version = "0.
|
|
61
|
+
version = "0.17.0"
|
|
68
62
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
69
|
-
checksum = "
|
|
63
|
+
checksum = "4f467dd6dccf739c208452f8014c75c18bb8301b050ad1cfb27153803edb0f51"
|
|
70
64
|
|
|
71
65
|
[[package]]
|
|
72
66
|
name = "heck"
|
|
@@ -76,21 +70,22 @@ checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea"
|
|
|
76
70
|
|
|
77
71
|
[[package]]
|
|
78
72
|
name = "hyperminhash"
|
|
79
|
-
version = "0.2.
|
|
73
|
+
version = "0.2.3"
|
|
80
74
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
81
|
-
checksum = "
|
|
75
|
+
checksum = "74b6fd2ffa7fbb0fa4cb305f751e01c9eb474330be931bdc77a917e3f28d1f80"
|
|
82
76
|
dependencies = [
|
|
83
77
|
"xxhash-rust",
|
|
84
78
|
]
|
|
85
79
|
|
|
86
80
|
[[package]]
|
|
87
81
|
name = "icu_collections"
|
|
88
|
-
version = "2.
|
|
82
|
+
version = "2.2.0"
|
|
89
83
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
90
|
-
checksum = "
|
|
84
|
+
checksum = "2984d1cd16c883d7935b9e07e44071dca8d917fd52ecc02c04d5fa0b5a3f191c"
|
|
91
85
|
dependencies = [
|
|
92
86
|
"displaydoc",
|
|
93
87
|
"potential_utf",
|
|
88
|
+
"utf8_iter",
|
|
94
89
|
"yoke",
|
|
95
90
|
"zerofrom",
|
|
96
91
|
"zerovec",
|
|
@@ -98,9 +93,9 @@ dependencies = [
|
|
|
98
93
|
|
|
99
94
|
[[package]]
|
|
100
95
|
name = "icu_locale_core"
|
|
101
|
-
version = "2.
|
|
96
|
+
version = "2.2.0"
|
|
102
97
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
103
|
-
checksum = "
|
|
98
|
+
checksum = "92219b62b3e2b4d88ac5119f8904c10f8f61bf7e95b640d25ba3075e6cac2c29"
|
|
104
99
|
dependencies = [
|
|
105
100
|
"displaydoc",
|
|
106
101
|
"litemap",
|
|
@@ -111,9 +106,9 @@ dependencies = [
|
|
|
111
106
|
|
|
112
107
|
[[package]]
|
|
113
108
|
name = "icu_normalizer"
|
|
114
|
-
version = "2.
|
|
109
|
+
version = "2.2.0"
|
|
115
110
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
116
|
-
checksum = "
|
|
111
|
+
checksum = "c56e5ee99d6e3d33bd91c5d85458b6005a22140021cc324cea84dd0e72cff3b4"
|
|
117
112
|
dependencies = [
|
|
118
113
|
"icu_collections",
|
|
119
114
|
"icu_normalizer_data",
|
|
@@ -125,15 +120,15 @@ dependencies = [
|
|
|
125
120
|
|
|
126
121
|
[[package]]
|
|
127
122
|
name = "icu_normalizer_data"
|
|
128
|
-
version = "2.
|
|
123
|
+
version = "2.2.0"
|
|
129
124
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
130
|
-
checksum = "
|
|
125
|
+
checksum = "da3be0ae77ea334f4da67c12f149704f19f81d1adf7c51cf482943e84a2bad38"
|
|
131
126
|
|
|
132
127
|
[[package]]
|
|
133
128
|
name = "icu_properties"
|
|
134
|
-
version = "2.
|
|
129
|
+
version = "2.2.0"
|
|
135
130
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
136
|
-
checksum = "
|
|
131
|
+
checksum = "bee3b67d0ea5c2cca5003417989af8996f8604e34fb9ddf96208a033901e70de"
|
|
137
132
|
dependencies = [
|
|
138
133
|
"icu_collections",
|
|
139
134
|
"icu_locale_core",
|
|
@@ -145,15 +140,15 @@ dependencies = [
|
|
|
145
140
|
|
|
146
141
|
[[package]]
|
|
147
142
|
name = "icu_properties_data"
|
|
148
|
-
version = "2.
|
|
143
|
+
version = "2.2.0"
|
|
149
144
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
150
|
-
checksum = "
|
|
145
|
+
checksum = "8e2bbb201e0c04f7b4b3e14382af113e17ba4f63e2c9d2ee626b720cbce54a14"
|
|
151
146
|
|
|
152
147
|
[[package]]
|
|
153
148
|
name = "icu_provider"
|
|
154
|
-
version = "2.
|
|
149
|
+
version = "2.2.0"
|
|
155
150
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
156
|
-
checksum = "
|
|
151
|
+
checksum = "139c4cf31c8b5f33d7e199446eff9c1e02decfc2f0eec2c8d71f65befa45b421"
|
|
157
152
|
dependencies = [
|
|
158
153
|
"displaydoc",
|
|
159
154
|
"icu_locale_core",
|
|
@@ -187,55 +182,37 @@ dependencies = [
|
|
|
187
182
|
|
|
188
183
|
[[package]]
|
|
189
184
|
name = "indexmap"
|
|
190
|
-
version = "2.
|
|
185
|
+
version = "2.14.0"
|
|
191
186
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
192
|
-
checksum = "
|
|
187
|
+
checksum = "d466e9454f08e4a911e14806c24e16fba1b4c121d1ea474396f396069cf949d9"
|
|
193
188
|
dependencies = [
|
|
194
189
|
"equivalent",
|
|
195
190
|
"hashbrown",
|
|
196
191
|
]
|
|
197
192
|
|
|
198
|
-
[[package]]
|
|
199
|
-
name = "indoc"
|
|
200
|
-
version = "2.0.7"
|
|
201
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
202
|
-
checksum = "79cf5c93f93228cf8efb3ba362535fb11199ac548a09ce117c9b1adc3030d706"
|
|
203
|
-
dependencies = [
|
|
204
|
-
"rustversion",
|
|
205
|
-
]
|
|
206
|
-
|
|
207
193
|
[[package]]
|
|
208
194
|
name = "libc"
|
|
209
|
-
version = "0.2.
|
|
195
|
+
version = "0.2.185"
|
|
210
196
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
211
|
-
checksum = "
|
|
197
|
+
checksum = "52ff2c0fe9bc6cb6b14a0592c2ff4fa9ceb83eea9db979b0487cd054946a2b8f"
|
|
212
198
|
|
|
213
199
|
[[package]]
|
|
214
200
|
name = "litemap"
|
|
215
|
-
version = "0.8.
|
|
201
|
+
version = "0.8.2"
|
|
216
202
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
217
|
-
checksum = "
|
|
203
|
+
checksum = "92daf443525c4cce67b150400bc2316076100ce0b3686209eb8cf3c31612e6f0"
|
|
218
204
|
|
|
219
205
|
[[package]]
|
|
220
206
|
name = "memchr"
|
|
221
|
-
version = "2.
|
|
207
|
+
version = "2.8.0"
|
|
222
208
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
223
|
-
checksum = "
|
|
224
|
-
|
|
225
|
-
[[package]]
|
|
226
|
-
name = "memoffset"
|
|
227
|
-
version = "0.9.1"
|
|
228
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
229
|
-
checksum = "488016bfae457b036d996092f6cb448677611ce4449e970ceaf42695203f218a"
|
|
230
|
-
dependencies = [
|
|
231
|
-
"autocfg",
|
|
232
|
-
]
|
|
209
|
+
checksum = "f8ca58f447f06ed17d5fc4043ce1b10dd205e060fb3ce5b979b8ed8e59ff3f79"
|
|
233
210
|
|
|
234
211
|
[[package]]
|
|
235
212
|
name = "once_cell"
|
|
236
|
-
version = "1.21.
|
|
213
|
+
version = "1.21.4"
|
|
237
214
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
238
|
-
checksum = "
|
|
215
|
+
checksum = "9f7c3e4beb33f85d45ae3e3a1792185706c8e16d043238c593331cc7cd313b50"
|
|
239
216
|
|
|
240
217
|
[[package]]
|
|
241
218
|
name = "percent-encoding"
|
|
@@ -255,31 +232,31 @@ dependencies = [
|
|
|
255
232
|
|
|
256
233
|
[[package]]
|
|
257
234
|
name = "portable-atomic"
|
|
258
|
-
version = "1.
|
|
235
|
+
version = "1.13.1"
|
|
259
236
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
260
|
-
checksum = "
|
|
237
|
+
checksum = "c33a9471896f1c69cecef8d20cbe2f7accd12527ce60845ff44c153bb2a21b49"
|
|
261
238
|
|
|
262
239
|
[[package]]
|
|
263
240
|
name = "potential_utf"
|
|
264
|
-
version = "0.1.
|
|
241
|
+
version = "0.1.5"
|
|
265
242
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
266
|
-
checksum = "
|
|
243
|
+
checksum = "0103b1cef7ec0cf76490e969665504990193874ea05c85ff9bab8b911d0a0564"
|
|
267
244
|
dependencies = [
|
|
268
245
|
"zerovec",
|
|
269
246
|
]
|
|
270
247
|
|
|
271
248
|
[[package]]
|
|
272
249
|
name = "proc-macro2"
|
|
273
|
-
version = "1.0.
|
|
250
|
+
version = "1.0.106"
|
|
274
251
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
275
|
-
checksum = "
|
|
252
|
+
checksum = "8fd00f0bb2e90d81d1044c2b32617f68fcb9fa3bb7640c23e9c748e53fb30934"
|
|
276
253
|
dependencies = [
|
|
277
254
|
"unicode-ident",
|
|
278
255
|
]
|
|
279
256
|
|
|
280
257
|
[[package]]
|
|
281
258
|
name = "pyhyperminhash"
|
|
282
|
-
version = "0.
|
|
259
|
+
version = "0.2.0"
|
|
283
260
|
dependencies = [
|
|
284
261
|
"built",
|
|
285
262
|
"hyperminhash",
|
|
@@ -288,35 +265,32 @@ dependencies = [
|
|
|
288
265
|
|
|
289
266
|
[[package]]
|
|
290
267
|
name = "pyo3"
|
|
291
|
-
version = "0.
|
|
268
|
+
version = "0.28.3"
|
|
292
269
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
293
|
-
checksum = "
|
|
270
|
+
checksum = "91fd8e38a3b50ed1167fb981cd6fd60147e091784c427b8f7183a7ee32c31c12"
|
|
294
271
|
dependencies = [
|
|
295
|
-
"indoc",
|
|
296
272
|
"libc",
|
|
297
|
-
"memoffset",
|
|
298
273
|
"once_cell",
|
|
299
274
|
"portable-atomic",
|
|
300
275
|
"pyo3-build-config",
|
|
301
276
|
"pyo3-ffi",
|
|
302
277
|
"pyo3-macros",
|
|
303
|
-
"unindent",
|
|
304
278
|
]
|
|
305
279
|
|
|
306
280
|
[[package]]
|
|
307
281
|
name = "pyo3-build-config"
|
|
308
|
-
version = "0.
|
|
282
|
+
version = "0.28.3"
|
|
309
283
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
310
|
-
checksum = "
|
|
284
|
+
checksum = "e368e7ddfdeb98c9bca7f8383be1648fd84ab466bf2bc015e94008db6d35611e"
|
|
311
285
|
dependencies = [
|
|
312
286
|
"target-lexicon",
|
|
313
287
|
]
|
|
314
288
|
|
|
315
289
|
[[package]]
|
|
316
290
|
name = "pyo3-ffi"
|
|
317
|
-
version = "0.
|
|
291
|
+
version = "0.28.3"
|
|
318
292
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
319
|
-
checksum = "
|
|
293
|
+
checksum = "7f29e10af80b1f7ccaf7f69eace800a03ecd13e883acfacc1e5d0988605f651e"
|
|
320
294
|
dependencies = [
|
|
321
295
|
"libc",
|
|
322
296
|
"pyo3-build-config",
|
|
@@ -324,9 +298,9 @@ dependencies = [
|
|
|
324
298
|
|
|
325
299
|
[[package]]
|
|
326
300
|
name = "pyo3-macros"
|
|
327
|
-
version = "0.
|
|
301
|
+
version = "0.28.3"
|
|
328
302
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
329
|
-
checksum = "
|
|
303
|
+
checksum = "df6e520eff47c45997d2fc7dd8214b25dd1310918bbb2642156ef66a67f29813"
|
|
330
304
|
dependencies = [
|
|
331
305
|
"proc-macro2",
|
|
332
306
|
"pyo3-macros-backend",
|
|
@@ -336,9 +310,9 @@ dependencies = [
|
|
|
336
310
|
|
|
337
311
|
[[package]]
|
|
338
312
|
name = "pyo3-macros-backend"
|
|
339
|
-
version = "0.
|
|
313
|
+
version = "0.28.3"
|
|
340
314
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
341
|
-
checksum = "
|
|
315
|
+
checksum = "c4cdc218d835738f81c2338f822078af45b4afdf8b2e33cbb5916f108b813acb"
|
|
342
316
|
dependencies = [
|
|
343
317
|
"heck",
|
|
344
318
|
"proc-macro2",
|
|
@@ -349,24 +323,18 @@ dependencies = [
|
|
|
349
323
|
|
|
350
324
|
[[package]]
|
|
351
325
|
name = "quote"
|
|
352
|
-
version = "1.0.
|
|
326
|
+
version = "1.0.45"
|
|
353
327
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
354
|
-
checksum = "
|
|
328
|
+
checksum = "41f2619966050689382d2b44f664f4bc593e129785a36d6ee376ddf37259b924"
|
|
355
329
|
dependencies = [
|
|
356
330
|
"proc-macro2",
|
|
357
331
|
]
|
|
358
332
|
|
|
359
|
-
[[package]]
|
|
360
|
-
name = "rustversion"
|
|
361
|
-
version = "1.0.22"
|
|
362
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
363
|
-
checksum = "b39cdef0fa800fc44525c84ccb54a029961a8215f9619753635a9c0d2538d46d"
|
|
364
|
-
|
|
365
333
|
[[package]]
|
|
366
334
|
name = "semver"
|
|
367
|
-
version = "1.0.
|
|
335
|
+
version = "1.0.28"
|
|
368
336
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
369
|
-
checksum = "
|
|
337
|
+
checksum = "8a7852d02fc848982e0c167ef163aaff9cd91dc640ba85e263cb1ce46fae51cd"
|
|
370
338
|
dependencies = [
|
|
371
339
|
"serde",
|
|
372
340
|
"serde_core",
|
|
@@ -425,9 +393,9 @@ checksum = "6ce2be8dc25455e1f91df71bfa12ad37d7af1092ae736f3a6cd0e37bc7810596"
|
|
|
425
393
|
|
|
426
394
|
[[package]]
|
|
427
395
|
name = "syn"
|
|
428
|
-
version = "2.0.
|
|
396
|
+
version = "2.0.117"
|
|
429
397
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
430
|
-
checksum = "
|
|
398
|
+
checksum = "e665b8803e7b1d2a727f4023456bbbbe74da67099c585258af0ad9c5013b9b99"
|
|
431
399
|
dependencies = [
|
|
432
400
|
"proc-macro2",
|
|
433
401
|
"quote",
|
|
@@ -447,15 +415,15 @@ dependencies = [
|
|
|
447
415
|
|
|
448
416
|
[[package]]
|
|
449
417
|
name = "target-lexicon"
|
|
450
|
-
version = "0.13.
|
|
418
|
+
version = "0.13.5"
|
|
451
419
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
452
|
-
checksum = "
|
|
420
|
+
checksum = "adb6935a6f5c20170eeceb1a3835a49e12e19d792f6dd344ccc76a985ca5a6ca"
|
|
453
421
|
|
|
454
422
|
[[package]]
|
|
455
423
|
name = "tinystr"
|
|
456
|
-
version = "0.8.
|
|
424
|
+
version = "0.8.3"
|
|
457
425
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
458
|
-
checksum = "
|
|
426
|
+
checksum = "c8323304221c2a851516f22236c5722a72eaa19749016521d6dff0824447d96d"
|
|
459
427
|
dependencies = [
|
|
460
428
|
"displaydoc",
|
|
461
429
|
"zerovec",
|
|
@@ -504,21 +472,15 @@ checksum = "5d99f8c9a7727884afe522e9bd5edbfc91a3312b36a77b5fb8926e4c31a41801"
|
|
|
504
472
|
|
|
505
473
|
[[package]]
|
|
506
474
|
name = "unicode-ident"
|
|
507
|
-
version = "1.0.
|
|
475
|
+
version = "1.0.24"
|
|
508
476
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
509
|
-
checksum = "
|
|
510
|
-
|
|
511
|
-
[[package]]
|
|
512
|
-
name = "unindent"
|
|
513
|
-
version = "0.2.4"
|
|
514
|
-
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
515
|
-
checksum = "7264e107f553ccae879d21fbea1d6724ac785e8c3bfc762137959b5802826ef3"
|
|
477
|
+
checksum = "e6e4313cd5fcd3dad5cafa179702e2b244f760991f45397d14d4ebf38247da75"
|
|
516
478
|
|
|
517
479
|
[[package]]
|
|
518
480
|
name = "url"
|
|
519
|
-
version = "2.5.
|
|
481
|
+
version = "2.5.8"
|
|
520
482
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
521
|
-
checksum = "
|
|
483
|
+
checksum = "ff67a8a4397373c3ef660812acab3268222035010ab8680ec4215f38ba3d0eed"
|
|
522
484
|
dependencies = [
|
|
523
485
|
"form_urlencoded",
|
|
524
486
|
"idna",
|
|
@@ -534,18 +496,18 @@ checksum = "b6c140620e7ffbb22c2dee59cafe6084a59b5ffc27a8859a5f0d494b5d52b6be"
|
|
|
534
496
|
|
|
535
497
|
[[package]]
|
|
536
498
|
name = "winnow"
|
|
537
|
-
version = "0.7.
|
|
499
|
+
version = "0.7.15"
|
|
538
500
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
539
|
-
checksum = "
|
|
501
|
+
checksum = "df79d97927682d2fd8adb29682d1140b343be4ac0f08fd68b7765d9c059d3945"
|
|
540
502
|
dependencies = [
|
|
541
503
|
"memchr",
|
|
542
504
|
]
|
|
543
505
|
|
|
544
506
|
[[package]]
|
|
545
507
|
name = "writeable"
|
|
546
|
-
version = "0.6.
|
|
508
|
+
version = "0.6.3"
|
|
547
509
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
548
|
-
checksum = "
|
|
510
|
+
checksum = "1ffae5123b2d3fc086436f8834ae3ab053a283cfac8fe0a0b8eaae044768a4c4"
|
|
549
511
|
|
|
550
512
|
[[package]]
|
|
551
513
|
name = "xxhash-rust"
|
|
@@ -555,9 +517,9 @@ checksum = "fdd20c5420375476fbd4394763288da7eb0cc0b8c11deed431a91562af7335d3"
|
|
|
555
517
|
|
|
556
518
|
[[package]]
|
|
557
519
|
name = "yoke"
|
|
558
|
-
version = "0.8.
|
|
520
|
+
version = "0.8.2"
|
|
559
521
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
560
|
-
checksum = "
|
|
522
|
+
checksum = "abe8c5fda708d9ca3df187cae8bfb9ceda00dd96231bed36e445a1a48e66f9ca"
|
|
561
523
|
dependencies = [
|
|
562
524
|
"stable_deref_trait",
|
|
563
525
|
"yoke-derive",
|
|
@@ -566,9 +528,9 @@ dependencies = [
|
|
|
566
528
|
|
|
567
529
|
[[package]]
|
|
568
530
|
name = "yoke-derive"
|
|
569
|
-
version = "0.8.
|
|
531
|
+
version = "0.8.2"
|
|
570
532
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
571
|
-
checksum = "
|
|
533
|
+
checksum = "de844c262c8848816172cef550288e7dc6c7b7814b4ee56b3e1553f275f1858e"
|
|
572
534
|
dependencies = [
|
|
573
535
|
"proc-macro2",
|
|
574
536
|
"quote",
|
|
@@ -578,18 +540,18 @@ dependencies = [
|
|
|
578
540
|
|
|
579
541
|
[[package]]
|
|
580
542
|
name = "zerofrom"
|
|
581
|
-
version = "0.1.
|
|
543
|
+
version = "0.1.7"
|
|
582
544
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
583
|
-
checksum = "
|
|
545
|
+
checksum = "69faa1f2a1ea75661980b013019ed6687ed0e83d069bc1114e2cc74c6c04c4df"
|
|
584
546
|
dependencies = [
|
|
585
547
|
"zerofrom-derive",
|
|
586
548
|
]
|
|
587
549
|
|
|
588
550
|
[[package]]
|
|
589
551
|
name = "zerofrom-derive"
|
|
590
|
-
version = "0.1.
|
|
552
|
+
version = "0.1.7"
|
|
591
553
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
592
|
-
checksum = "
|
|
554
|
+
checksum = "11532158c46691caf0f2593ea8358fed6bbf68a0315e80aae9bd41fbade684a1"
|
|
593
555
|
dependencies = [
|
|
594
556
|
"proc-macro2",
|
|
595
557
|
"quote",
|
|
@@ -599,9 +561,9 @@ dependencies = [
|
|
|
599
561
|
|
|
600
562
|
[[package]]
|
|
601
563
|
name = "zerotrie"
|
|
602
|
-
version = "0.2.
|
|
564
|
+
version = "0.2.4"
|
|
603
565
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
604
|
-
checksum = "
|
|
566
|
+
checksum = "0f9152d31db0792fa83f70fb2f83148effb5c1f5b8c7686c3459e361d9bc20bf"
|
|
605
567
|
dependencies = [
|
|
606
568
|
"displaydoc",
|
|
607
569
|
"yoke",
|
|
@@ -610,9 +572,9 @@ dependencies = [
|
|
|
610
572
|
|
|
611
573
|
[[package]]
|
|
612
574
|
name = "zerovec"
|
|
613
|
-
version = "0.11.
|
|
575
|
+
version = "0.11.6"
|
|
614
576
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
615
|
-
checksum = "
|
|
577
|
+
checksum = "90f911cbc359ab6af17377d242225f4d75119aec87ea711a880987b18cd7b239"
|
|
616
578
|
dependencies = [
|
|
617
579
|
"yoke",
|
|
618
580
|
"zerofrom",
|
|
@@ -621,9 +583,9 @@ dependencies = [
|
|
|
621
583
|
|
|
622
584
|
[[package]]
|
|
623
585
|
name = "zerovec-derive"
|
|
624
|
-
version = "0.11.
|
|
586
|
+
version = "0.11.3"
|
|
625
587
|
source = "registry+https://github.com/rust-lang/crates.io-index"
|
|
626
|
-
checksum = "
|
|
588
|
+
checksum = "625dc425cab0dca6dc3c3319506e6593dcb08a9f387ea3b284dbd52a92c40555"
|
|
627
589
|
dependencies = [
|
|
628
590
|
"proc-macro2",
|
|
629
591
|
"quote",
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
[package]
|
|
2
|
+
name = "pyhyperminhash"
|
|
3
|
+
version = "0.2.0"
|
|
4
|
+
edition = "2024"
|
|
5
|
+
authors = ["Lukas Lueg <lukas.lueg@gmail.com>"]
|
|
6
|
+
repository = "https://github.com/lukaslueg/pyhyperminhash"
|
|
7
|
+
description = "Fast, constant-memory cardinality approximation"
|
|
8
|
+
readme = "README.md"
|
|
9
|
+
license = "MIT"
|
|
10
|
+
publish = false
|
|
11
|
+
include = [
|
|
12
|
+
"/Cargo.toml",
|
|
13
|
+
"/Cargo.lock",
|
|
14
|
+
"/LICENSE",
|
|
15
|
+
"/README.md",
|
|
16
|
+
"/build.rs",
|
|
17
|
+
"/pyproject.toml",
|
|
18
|
+
"/pyhyperminhash.pyi",
|
|
19
|
+
"/src/**",
|
|
20
|
+
"/tests/**",
|
|
21
|
+
"/examples/**",
|
|
22
|
+
"!**/__pycache__/",
|
|
23
|
+
"!**/__pycache__/**",
|
|
24
|
+
"!**/*.py[cod]",
|
|
25
|
+
]
|
|
26
|
+
|
|
27
|
+
[lib]
|
|
28
|
+
name = "pyhyperminhash"
|
|
29
|
+
crate-type = ["cdylib"]
|
|
30
|
+
|
|
31
|
+
[dependencies]
|
|
32
|
+
hyperminhash = "0.2.3"
|
|
33
|
+
pyo3 = { version = "0.28", default-features = false, features = ["extension-module", "macros"] }
|
|
34
|
+
|
|
35
|
+
[build-dependencies]
|
|
36
|
+
built = { version = "0.8", features = ["cargo-lock", "dependency-tree"] }
|
|
37
|
+
|
|
38
|
+
[features]
|
|
39
|
+
default = ["abi3", "abi3-py39"]
|
|
40
|
+
abi3 = ["pyo3/abi3"]
|
|
41
|
+
abi3-py39 = ["pyo3/abi3-py39"]
|
|
42
|
+
abi3-py310 = ["pyo3/abi3-py310"]
|
|
43
|
+
abi3-py311 = ["pyo3/abi3-py311"]
|
|
44
|
+
abi3-py312 = ["pyo3/abi3-py312"]
|
|
45
|
+
abi3-py313 = ["pyo3/abi3-py313"]
|
|
46
|
+
abi3-py314 = ["pyo3/abi3-py314"]
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: pyhyperminhash
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.2.0
|
|
4
4
|
Classifier: Programming Language :: Rust
|
|
5
5
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
6
6
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
@@ -25,9 +25,15 @@ the instance's lifetime. Unlike e.g. when using a `set`, the memory consumed by
|
|
|
25
25
|
`Sketch`-instance does _not_ grow as elements are added; each `Sketch`-instance
|
|
26
26
|
consumes approximately 32kb of memory, independent of the number of elements.
|
|
27
27
|
|
|
28
|
-
|
|
29
|
-
|
|
28
|
+
### Installation
|
|
29
|
+
|
|
30
|
+
```bash
|
|
31
|
+
pip install pyhyperminhash
|
|
32
|
+
```
|
|
30
33
|
|
|
34
|
+
### Basic usage
|
|
35
|
+
|
|
36
|
+
```python
|
|
31
37
|
# Construct an empty Sketch
|
|
32
38
|
sk = pyhyperminhash.Sketch()
|
|
33
39
|
assert not sk # The Sketch is empty
|
|
@@ -44,12 +50,22 @@ assert int(sk) == len(sk) # Approximately 3
|
|
|
44
50
|
|
|
45
51
|
sk2 = pyhyperminhash.Sketch()
|
|
46
52
|
sk2.add('Foobar')
|
|
47
|
-
sk2
|
|
53
|
+
sk2 |= sk # sk2 now holds all elements that were in `sk` or `sk2`
|
|
48
54
|
|
|
49
55
|
sk3 = pyhyperminhash.Sketch()
|
|
50
56
|
sk3.add(42)
|
|
51
57
|
sk3.add('Foo')
|
|
52
|
-
assert sk3.intersection(
|
|
58
|
+
assert sk3.intersection(sk2) > 0.0 # Approximately 1.0, due to `Foo`
|
|
59
|
+
|
|
60
|
+
# `fast=True` uses the faster upstream estimate with a slightly looser
|
|
61
|
+
# correction model; for most inputs the difference is tiny.
|
|
62
|
+
assert sk3.intersection(sk2, fast=True) > 0.0
|
|
63
|
+
assert sk3.similarity(sk2, fast=True) > 0.0
|
|
64
|
+
|
|
65
|
+
# Compare one Sketch against many others
|
|
66
|
+
others = [sk, sk2, sk3]
|
|
67
|
+
assert sk3.intersection_many(others) == [sk3.intersection(other) for other in others]
|
|
68
|
+
assert sk3.similarity_many(others) == [sk3.similarity(other) for other in others]
|
|
53
69
|
```
|
|
54
70
|
|
|
55
71
|
```python
|
|
@@ -87,7 +103,8 @@ with open('complaints.txt', 'rb') as f:
|
|
|
87
103
|
e.add(f.read(4096))
|
|
88
104
|
sk.add_entry(e) # This counts as one object
|
|
89
105
|
|
|
90
|
-
|
|
106
|
+
sk2 = pyhyperminhash.Sketch()
|
|
107
|
+
sk2.add_entry(e) # Entry-objects can be added to multiple Sketches
|
|
91
108
|
|
|
92
109
|
# Entry-objects can be "forked" at the state they are currently at
|
|
93
110
|
e2 = e.fork()
|
|
@@ -150,6 +167,16 @@ Count lines | 2.3 seconds | _nil_ | 50,000,000 |
|
|
|
150
167
|
`set()` | 14.99 seconds | ~144 megabytes | 1,048,576 |
|
|
151
168
|
`Sketch.from_iter()` | 1.8 seconds | ~32 kilobytes | 1,041,936 |
|
|
152
169
|
|
|
170
|
+
For repeatable local benchmarks of the Python-facing API, use the `pyperf` suite:
|
|
171
|
+
|
|
172
|
+
```bash
|
|
173
|
+
python3 -m venv .venv
|
|
174
|
+
source .venv/bin/activate
|
|
175
|
+
maturin develop -r
|
|
176
|
+
pip install pyperf
|
|
177
|
+
python3 examples/bench.py
|
|
178
|
+
```
|
|
179
|
+
|
|
153
180
|
### FAQ
|
|
154
181
|
|
|
155
182
|
* Can I extract an element that was previously added from a `Sketch`?
|
|
@@ -11,9 +11,15 @@ the instance's lifetime. Unlike e.g. when using a `set`, the memory consumed by
|
|
|
11
11
|
`Sketch`-instance does _not_ grow as elements are added; each `Sketch`-instance
|
|
12
12
|
consumes approximately 32kb of memory, independent of the number of elements.
|
|
13
13
|
|
|
14
|
-
|
|
15
|
-
|
|
14
|
+
### Installation
|
|
15
|
+
|
|
16
|
+
```bash
|
|
17
|
+
pip install pyhyperminhash
|
|
18
|
+
```
|
|
16
19
|
|
|
20
|
+
### Basic usage
|
|
21
|
+
|
|
22
|
+
```python
|
|
17
23
|
# Construct an empty Sketch
|
|
18
24
|
sk = pyhyperminhash.Sketch()
|
|
19
25
|
assert not sk # The Sketch is empty
|
|
@@ -30,12 +36,22 @@ assert int(sk) == len(sk) # Approximately 3
|
|
|
30
36
|
|
|
31
37
|
sk2 = pyhyperminhash.Sketch()
|
|
32
38
|
sk2.add('Foobar')
|
|
33
|
-
sk2
|
|
39
|
+
sk2 |= sk # sk2 now holds all elements that were in `sk` or `sk2`
|
|
34
40
|
|
|
35
41
|
sk3 = pyhyperminhash.Sketch()
|
|
36
42
|
sk3.add(42)
|
|
37
43
|
sk3.add('Foo')
|
|
38
|
-
assert sk3.intersection(
|
|
44
|
+
assert sk3.intersection(sk2) > 0.0 # Approximately 1.0, due to `Foo`
|
|
45
|
+
|
|
46
|
+
# `fast=True` uses the faster upstream estimate with a slightly looser
|
|
47
|
+
# correction model; for most inputs the difference is tiny.
|
|
48
|
+
assert sk3.intersection(sk2, fast=True) > 0.0
|
|
49
|
+
assert sk3.similarity(sk2, fast=True) > 0.0
|
|
50
|
+
|
|
51
|
+
# Compare one Sketch against many others
|
|
52
|
+
others = [sk, sk2, sk3]
|
|
53
|
+
assert sk3.intersection_many(others) == [sk3.intersection(other) for other in others]
|
|
54
|
+
assert sk3.similarity_many(others) == [sk3.similarity(other) for other in others]
|
|
39
55
|
```
|
|
40
56
|
|
|
41
57
|
```python
|
|
@@ -73,7 +89,8 @@ with open('complaints.txt', 'rb') as f:
|
|
|
73
89
|
e.add(f.read(4096))
|
|
74
90
|
sk.add_entry(e) # This counts as one object
|
|
75
91
|
|
|
76
|
-
|
|
92
|
+
sk2 = pyhyperminhash.Sketch()
|
|
93
|
+
sk2.add_entry(e) # Entry-objects can be added to multiple Sketches
|
|
77
94
|
|
|
78
95
|
# Entry-objects can be "forked" at the state they are currently at
|
|
79
96
|
e2 = e.fork()
|
|
@@ -136,6 +153,16 @@ Count lines | 2.3 seconds | _nil_ | 50,000,000 |
|
|
|
136
153
|
`set()` | 14.99 seconds | ~144 megabytes | 1,048,576 |
|
|
137
154
|
`Sketch.from_iter()` | 1.8 seconds | ~32 kilobytes | 1,041,936 |
|
|
138
155
|
|
|
156
|
+
For repeatable local benchmarks of the Python-facing API, use the `pyperf` suite:
|
|
157
|
+
|
|
158
|
+
```bash
|
|
159
|
+
python3 -m venv .venv
|
|
160
|
+
source .venv/bin/activate
|
|
161
|
+
maturin develop -r
|
|
162
|
+
pip install pyperf
|
|
163
|
+
python3 examples/bench.py
|
|
164
|
+
```
|
|
165
|
+
|
|
139
166
|
### FAQ
|
|
140
167
|
|
|
141
168
|
* Can I extract an element that was previously added from a `Sketch`?
|