Skip to content

Commit 78f970f

Browse files
martindevanscsris
authored andcommitted
Fixed typo
Fixed a type in `cos_sim_2d(x, y)`
1 parent cd0f1c9 commit 78f970f

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

retrieval/wikipedia.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ def mean_pooling(token_embeddings, mask):
2020

2121
def cos_sim_2d(x, y):
2222
norm_x = x / np.linalg.norm(x, axis=1, keepdims=True)
23-
norm_y = y / np.linalg.norm(x, axis=1, keepdims=True)
23+
norm_y = y / np.linalg.norm(y, axis=1, keepdims=True)
2424
return np.matmul(norm_x, norm_y.T)
2525

2626

0 commit comments

Comments
 (0)