Skip to main content

[![Build Status](https://travis-ci.org/crankycoder/hydra.svg?branch=master)](https://travis-ci.org/crankycoder/hydra)

Hydra: The Python Bloom Filter.

Compile with Cython 0.24 or higher.

—

Hydra is a high performance bloom filter. It’s basically a port of the Cassandra bloom filter with some fun Cython hackery.

1) It’s persistent using memory mapped io. On Linux, the mmap uses the MAP_POPULATE flag so the entire file is loaded into kernel space virtual memory. In other words - fast.

2) The hash function uses the MurmurHash3 algorithm, so it should be fast and have excellent key distribution and avalanche properties.

3) The filter exports a set-like interface. Use .add(..), .contains() or use the “in” operator.

  1. Tests. OMG what is wrong with people with no tests?

The filter supports periodic forced synchronization to disk using fdatasync(), or you can just let the deallocator flush everything to disk when your filter goes out of scope, or your process terminates.

Hydras are snakes with multiple heads. They’re also bad dudes with snake logos on their chest who regularly try to beat on Nick Fury. Now it’s a bloom filter.

Mostly, I couldn’t bear to make this yet another PySomeLibraryName library.

Build, install a dev build and test:

$ pip install -r requirements.txt $ cythonize src/_hydra.pyx $ python setup.py develop $ python setup.py test

Metadata

Release files for Hydra 2.5

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for Hydra 2.5
File Size Uploaded Provenance Actions
Hydra-2.5.tar.gz 82.4 kB Without provenance Details for Hydra-2.5.tar.gz

Release files / Hydra-2.5.tar.gz

Download URL Hydra-2.5.tar.gz
Size 82.4 kB
Tags Source
SHA-256 checksum
How to use checksums
247091b9c279c77686ea995f0f07070a28870c1942959b1474ad57076074384a
BLAKE2b-256 checksum
How to use checksums
6eac7a7596cb752fe807be2f6fa11ed561e39efa86f556214733fc7df0e985d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for Hydra 2.5

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page