MCPcopy Create free account
hub / github.com/BIT-DataLab/LakeBench / insert

Method insert

join/LSH/datasketch/lsh.py:368–379  ·  view source on GitHub ↗

Insert a unique key to the index, together with a MinHash (or weighted MinHash) of the set referenced by the key. Args: key (hashable): The unique identifier of the set. minhash (datasketch.MinHash): The MinHash of the set.

(self, key, minhash, check_duplication=True)

Source from the content-addressed store, hash-verified

366 hashtable.empty_buffer()
367
368 def insert(self, key, minhash, check_duplication=True):
369 '''
370 Insert a unique key to the index, together
371 with a MinHash (or weighted MinHash) of the set referenced by
372 the key.
373
374 Args:
375 key (hashable): The unique identifier of the set.
376 minhash (datasketch.MinHash): The MinHash of the set.
377 '''
378 self.lsh._insert(key, minhash, check_duplication=check_duplication,
379 buffer=True)

Callers

nothing calls this directly

Calls 1

_insertMethod · 0.45

Tested by

no test coverage detected