本文整理匯總了Python中nearpy.Engine.delete_vector方法的典型用法代碼示例。如果您正苦於以下問題:Python Engine.delete_vector方法的具體用法?Python Engine.delete_vector怎麽用?Python Engine.delete_vector使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類nearpy.Engine
的用法示例。
在下文中一共展示了Engine.delete_vector方法的3個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Python代碼示例。
示例1: test_delete_vector_multiple_hash
# 需要導入模塊: from nearpy import Engine [as 別名]
# 或者: from nearpy.Engine import delete_vector [as 別名]
def test_delete_vector_multiple_hash(self):
hashes = [UniBucket('name_hash_%d' % k) for k in range(10)]
engine = Engine(self.dim, lshashes=hashes)
self.fill_engine(engine)
engine.delete_vector(self.removed_value)
self.check_delete(engine)
示例2: test_delete_vector_with_provided_value
# 需要導入模塊: from nearpy import Engine [as 別名]
# 或者: from nearpy.Engine import delete_vector [as 別名]
def test_delete_vector_with_provided_value(self):
engine = Engine(self.dim, lshashes=[UniBucket('testHash')])
self.fill_engine(engine)
engine.delete_vector(self.removed_value, self.removed_vector)
self.check_delete(engine)
示例3: test_delete_vector_single_hash
# 需要導入模塊: from nearpy import Engine [as 別名]
# 或者: from nearpy.Engine import delete_vector [as 別名]
def test_delete_vector_single_hash(self):
engine = Engine(self.dim, lshashes=[UniBucket('testHash')])
self.fill_engine(engine)
engine.delete_vector(self.removed_value)
self.check_delete(engine)