After pip install panns, i try run the code from panns import *
create an index of Euclidean distance
p = PannsIndex(dimension=100, metric='euclidean')
generate a 1000 x 100 dataset
for i in xrange(1000):
v = gaussian_vector(100)
p.add_vector(v)
build an index of 50 trees and save to a file
p.build(50)
p.save('test.idx')
after run this code, there are 1 idx and a npy, that' ok, but when i run the code repeat, all the things are deleted, and the directory is deleted also, what's the problem?
After pip install panns, i try run the code from panns import *
create an index of Euclidean distance
p = PannsIndex(dimension=100, metric='euclidean')
generate a 1000 x 100 dataset
for i in xrange(1000):
v = gaussian_vector(100)
p.add_vector(v)
build an index of 50 trees and save to a file
p.build(50)
p.save('test.idx')
after run this code, there are 1 idx and a npy, that' ok, but when i run the code repeat, all the things are deleted, and the directory is deleted also, what's the problem?