Commit 82abe988 authored by 赵威's avatar 赵威

update printer

parent e7173113
......@@ -67,6 +67,9 @@ if __name__ == "__main__":
print("trained: " + str(index2.is_trained))
print("total index: " + str(index2.ntotal))
D, I = index2.search(np.array(answer_embeddings[tmp_tuple[0]]).astype("float32"))
id = tmp_tuple[0]
emb = np.array(answer_embeddings[id]).astype("float32")
print(emb)
D, I = index2.search(emb)
res = I.tolist()
print(res, "\n")
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment