You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When selecting the negative triplet, right now, you are picking the sample furthest away from the anchor.
for i in range(self.triplet):
negative_feature = bottom[0].data[i+self.triplet2]
a_n = archor_feature - negative_feature
an = np.dot(a_n,a_n)
ans[i+self.triplet2] = an
ans = sorted(ans.items(), key = lambda d: d[1], reverse = True)
top_negative.append(bottom[0].data[ans[i][0]])
If we are mining the hardest negative sample, shouldn,'t we consider the closest negative sample to the anchor? Correct me if I'm wrong. Thanks!
The text was updated successfully, but these errors were encountered:
Hello,
When selecting the negative triplet, right now, you are picking the sample furthest away from the anchor.
for i in range(self.triplet):
negative_feature = bottom[0].data[i+self.triplet2]
a_n = archor_feature - negative_feature
an = np.dot(a_n,a_n)
ans[i+self.triplet2] = an
ans = sorted(ans.items(), key = lambda d: d[1], reverse = True)
top_negative.append(bottom[0].data[ans[i][0]])
If we are mining the hardest negative sample, shouldn,'t we consider the closest negative sample to the anchor? Correct me if I'm wrong. Thanks!
The text was updated successfully, but these errors were encountered: