1. organize project folder structure 2. add faiss_wrapper interface

pull/3/head
xj.lin 2019-03-20 12:00:49 +08:00
parent 3818ea20a7
commit cdc28432e3
4 changed files with 28 additions and 0 deletions

View File

@ -0,0 +1,28 @@
import faiss
import numpy as np
class FaissSearch():
def __init__(self, index, id_to_vector_map):
pass
# def search_by_ids(self, id_list, k):
# pass
def search_by_vectors(self, vector_list, k):
# return both id and vector
pass
def __search__(self, id_list, vector_list, k):
pass
class FaissIndex():
def build_index(self, vector_list, dimension):
# return index
pass
# def build_index_cpu(self):
# pass
# def build_index_gpu(self):
# pass

View File