- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for optimalNumOfBits (0.07 sec)
-
guava-tests/test/com/google/common/hash/BloomFilterTest.java
for (double fpp = Double.MIN_VALUE; fpp < 1.0; fpp += 0.001) { assertThat(BloomFilter.optimalNumOfBits(n, fpp)).isAtLeast(0); } } // some random values Random random = new Random(0); for (int repeats = 0; repeats < 10000; repeats++) { assertThat(BloomFilter.optimalNumOfBits(random.nextInt(1 << 16), random.nextDouble())) .isAtLeast(0); }
Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Oct 28 18:19:59 UTC 2025 - 22.1K bytes - Viewed (0) -
android/guava/src/com/google/common/hash/BloomFilter.java
* is proportional to -log(p), but there is not much of a point after all, e.g. * optimalM(1000, 0.0000000000000001) = 76680 which is less than 10kb. Who cares! */ long numBits = optimalNumOfBits(expectedInsertions, fpp); int numHashFunctions = optimalNumOfHashFunctions(fpp); try { return new BloomFilter<>(new LockFreeBitArray(numBits), numHashFunctions, funnel, strategy);Registered: Fri Dec 26 12:43:10 UTC 2025 - Last Modified: Tue Sep 23 19:23:59 UTC 2025 - 26.9K bytes - Viewed (0)