Skip to content

Commit

Permalink
Merge pull request #85 from Aquila-Network/develop
Browse files Browse the repository at this point in the history
changed sim.metric to inner product (dot)
  • Loading branch information
admin-adb authored Sep 5, 2021
2 parents 6ce5bcc + 8111329 commit 939f3f0
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions src/DB_config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ faiss:
bpsv: 8 # bytes per sub vector
annoy:
init:
smetric: "angular" # similarity metric to be used
ntrees: 10 # no. of trees
smetric: "dot" # similarity metric to be used
ntrees: 500 # no. of trees
search_k: -1 # search_k is provided in runtime and affects the search performance. A larger value will give more accurate results, but will take longer time to return.
queue:
qlen: 100000 # length limit for quesues used
Expand Down
2 changes: 1 addition & 1 deletion src/vec_index/hfaiss.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ def spawn (self):
def init_faiss(self, matrix):
self.train_data = np.matrix(matrix).astype('float32')
logging.debug('FAISS init quantizer')
self.f_quantizer = faiss.IndexFlatL2(self.dim)
self.f_quantizer = faiss.IndexFlatIP(self.dim)
# Lock index read / wtite until it is built
with self._lock:
logging.debug('FAISS init index')
Expand Down

0 comments on commit 939f3f0

Please sign in to comment.