corelay.io.hashing

Persistent, non-cryptographic hashing of python objects.

Functions

ext_hash

Extended non-cryptographic Hashing using Pickle and MetroHash

Classes

HashPickler

Pickler for computing Hashes

Hasher

Hasher object with a write function for file-like updates

Tensor

Dummy Tensor

class corelay.io.hashing.HashPickler(file, protocol=None, fix_imports=True, buffer_callback=None)[source]

Bases: Pickler

Pickler for computing Hashes

static numpy_id(obj)[source]

Persistent id for numpy arrays

persistent_id(obj)[source]

Persistent ids for persistent pickles

class corelay.io.hashing.Hasher[source]

Bases: MetroHash128

Hasher object with a write function for file-like updates

write(data)[source]

Update using write for file-like behaviour

class corelay.io.hashing.Tensor[source]

Bases: object

Dummy Tensor

corelay.io.hashing.ext_hash(data)[source]

Extended non-cryptographic Hashing using Pickle and MetroHash