Skip to content

Commit

Permalink
clean up code
Browse files Browse the repository at this point in the history
  • Loading branch information
gaotianyu1350 committed Aug 29, 2022
1 parent f7c433a commit 8f3ef2f
Showing 1 changed file with 0 additions and 1 deletion.
1 change: 0 additions & 1 deletion simcse/tool.py
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,6 @@ def build_index(self, sentences_or_file_path: Union[str, List[str]],
quantizer = faiss.IndexFlatIP(embeddings.shape[1])
if faiss_fast:
index = faiss.IndexIVFFlat(quantizer, embeddings.shape[1], min(self.num_cells, len(sentences_or_file_path)), faiss.METRIC_INNER_PRODUCT)
# index.metric_type = faiss.METRIC_INNER_PRODUCT
else:
index = quantizer

Expand Down

0 comments on commit 8f3ef2f

Please sign in to comment.