Closed rfeinman closed 3 years ago
Correct, the intention was to compute similarity. I think you're right, the implementation in the repo is wrong :sob: . Would you care to submit a PR?
Sure thing! It's submitted. See https://github.com/ixaxaar/pytorch-dnc/pull/57
I believe there's a bug in the function from
dnc.util
for computing cosine distance. First, I think you are trying to compute cosine similarity, not distance (sim = 1 - dist). Second, I think the current function implements neither cosine similarity nor distance. Here's a modified variant that returns the correct output for cosine similarity.