How to use the mmh3.hash_from_buffer function in mmh3

To help you get started, we’ve selected a few mmh3 examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github hajimes / mmh3 / test_mmh3.py View on Github external
def test_hash_from_buffer():
    mview = memoryview('foo'.encode('utf8'))
    assert mmh3.hash_from_buffer(mview) == -156908512
    assert mmh3.hash_from_buffer(mview, signed = False) == 4138058784
github hajimes / mmh3 / test_mmh3.py View on Github external
def test_hash_from_buffer():
    mview = memoryview('foo'.encode('utf8'))
    assert mmh3.hash_from_buffer(mview) == -156908512
    assert mmh3.hash_from_buffer(mview, signed = False) == 4138058784

mmh3

Python extension for MurmurHash (MurmurHash3), a set of fast and robust hash functions.

MIT
Latest version published 3 months ago

Package Health Score

88 / 100
Full package analysis