Skip to main content

Efficient representations of large sets of integers

Project description

IntSets are an efficient immutable representation of sets of unsigned 64-bit integers with fast boolean operations and fast indexing of the set in sorted order. They are designed to be particularly efficient for representing sets with large contiguous ranges, so for example representing the set of all 64-bit integers takes only a handful of bytes.

Their behaviour and API are somehwere in between that of frozenset and that of a sorted list of deduplicated integers.

The implementation is heavily based on Fast Mergeable Integer Maps by Okasaki and Gill, but it has been adapted to support a somewhat different feature set and a more compact representation for certain usage patterns.

For usage, see the API documentation.

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

intset-1.0.0.tar.gz (7.6 kB view hashes)

Uploaded source

Built Distributions

intset-1.0.0-py3-none-any.whl (9.8 kB view hashes)

Uploaded py3

intset-1.0.0-py2-none-any.whl (9.8 kB view hashes)

Uploaded py2

Supported by

AWS AWS Cloud computing Datadog Datadog Monitoring Facebook / Instagram Facebook / Instagram PSF Sponsor Fastly Fastly CDN Google Google Object Storage and Download Analytics Huawei Huawei PSF Sponsor Microsoft Microsoft PSF Sponsor NVIDIA NVIDIA PSF Sponsor Pingdom Pingdom Monitoring Salesforce Salesforce PSF Sponsor Sentry Sentry Error logging StatusPage StatusPage Status page