How is your laptop spec ? please
Intel Core i7-4980HQ
How to write a Bloom filter in C++
11–20 of 21 posts
Re: How to write a Bloom filter in C++
#12Re: How to write a Bloom filter in C++
#13[0] - https://github.com/EricLagergren/bloom [1] - https://github.com/EricLagergren/bloom-c
Re: How to write a Bloom filter in C++
#14The Bitcoin codebase has a simple Bloom filter implementation you can take a look at that has been in use for some time
https://github.com/bitcoin/bitcoin/blob/master/src/bloom.h
https://github.com/bitcoin/bitcoin/blob/master/src/bloom.cpp
Re: How to write a Bloom filter in C++
#15Minor nit: it will save readers time if you call out that "p is the false positive error rate". (You reference the error rate, but don't attach a variable name to it.) I had to go to an external reference to figure that out, which meant I learned something else of course.
Re: How to write a Bloom filter in C++
#16I feel the use of vector is an iffy choice. The Bitcoin codebase has a simple Bloom filter implementation you can take a look at that has been in use for some time https://github.com/bitcoin/bitcoin/blob/master/src/bloom.h https://github.com/bitcoin/bitcoin/blob/master/src/bloom.cpp
Re: How to write a Bloom filter in C++
#17Re: How to write a Bloom filter in C++
#18I feel the use of vector is an iffy choice. The Bitcoin codebase has a simple Bloom filter implementation you can take a look at that has been in use for some time https://github.com/bitcoin/bitcoin/blob/master/src/bloom.h https://github.com/bitcoin/bitcoin/blob/master/src/bloom.cpp
Re: How to write a Bloom filter in C++
#19Learned something today. Thanks for the article. Minor nit: it will save readers time if you call out that "p is the false positive error rate". (You reference the error rate, but don't attach a variable name to it.) I had to go to an external reference to figure that out, which meant I learned something else of course.
Re: How to write a Bloom filter in C++
#20I feel the use of vector is an iffy choice. The Bitcoin codebase has a simple Bloom filter implementation you can take a look at that has been in use for some time https://github.com/bitcoin/bitcoin/blob/master/src/bloom.h https://github.com/bitcoin/bitcoin/blob/master/src/bloom.cpp
std::bitset is also a good choice if the number of desired bits is known at compile time