minhashsketch.py 文件源码

python
阅读 16 收藏 0 点赞 0 评论 0

项目:mashing-pumpkins 作者: lgautier 项目源码 文件源码
def _replace(self, h, elt):
        """
        insert/replace an element

        - h: a hash value
        - elt: an object as returned by the method `make_elt()` 
        """
        heapset = self._heapset
        heapset.add(h)
        out = heapreplace(self._heap, elt)
        heapset.remove(self._extracthash(out))
        return out
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号