You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm working on a problem that involves carrying out many k-NN searches over different coordinate subsets of an index set X.
Concretely, imagine an array of vectors X; I would like to perform a k-NN search on X[:,I] for many (i.e. hundreds of) different choices of I.
Currently I am simply loading X[:,I] to an index each time. On GPU, the overhead incurred by copying many index sets to GPU memory more than cancels out the speedup that comes with using GPU.
Obviously repeatedly copying X[:,I] to memory is wasteful, and in my case the entire X is not too big to fit entirely in memory.
Ideally, I would like to be able to get rid of this overhead by writing something like this:
index.add(X)
index.search(xq, k, coords = I) # find the k-NNs of xq in X[:,I]
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
I'm working on a problem that involves carrying out many k-NN searches over different coordinate subsets of an index set
X
.Concretely, imagine an array of vectors
X
; I would like to perform a k-NN search onX[:,I]
for many (i.e. hundreds of) different choices ofI
.Currently I am simply loading
X[:,I]
to an index each time. On GPU, the overhead incurred by copying many index sets to GPU memory more than cancels out the speedup that comes with using GPU.Obviously repeatedly copying
X[:,I]
to memory is wasteful, and in my case the entireX
is not too big to fit entirely in memory.Ideally, I would like to be able to get rid of this overhead by writing something like this:
Is something like this possible with FAISS?
Many thanks.
Beta Was this translation helpful? Give feedback.
All reactions