This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Optimal bloom filter size and number of hashes | |
# Tips: | |
# 1. One byte per item in the input set gives about a 2% false positive rate. | |
# 2. The optimal number of hash functions is ~0.7x the number of bits per item. | |
# 3. The number of hashes dominates performance. | |
# Expected number of items in the collection | |
# n = (m * ln(2))/k; | |
n = 300_000 |