Skip to content

rpstac/pybloomfiltermmap

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

40 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pybloomfiltermmap

The goal of pybloomfiltermmap is simple: to provide a fast, simple, scalable, correct library for Bloom Filters in Python.

This fork of the project fixes some issues when using a lot of these objects and/or an erroneous error message ;).

Docs

You should probably read the original docs online at http://mike.axiak.net/python-bloom-filter/docs/html/

Overview

After you install, the interface to use is a cross between a file interface and a ste interface. As an example:

>>> fruit = pybloomfilter.BloomFilter(100000, 0.1, '/tmp/words.bloom')
>>> fruit.extend(('apple', 'pear', 'orange', 'apple'))
>>> len(bf)
3
>>> 'mike' in fruit
False

Install

You may or may not want to use Cython. If you have it installed, the setup file will build the C file from the pyx file. Otherwise, it will skip that step automatically and build from the packaged C file.

To install:

$ sudo python setup.py install

and you should be set.

License

See the LICENSE file. It's under the MIT License.

About

Fast Python Bloom Filter using Mmap - Original project docs linked below.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • C 89.5%
  • JavaScript 7.4%
  • Python 3.1%