omoindrot / tensorflow-triplet-loss

Implementation of triplet loss in TensorFlow
https://omoindrot.github.io/triplet-loss
MIT License
1.12k stars 283 forks source link

Bug reply #3

Closed ymcasky closed 6 years ago

ymcasky commented 6 years ago

In test_triplet_mask

distinct = (i != j and i != j and j != k) should be distinct = (i != j and i != k and j != k)

Thanks for your contribution!

omoindrot commented 6 years ago

You are right, the mistake is also in other test functions. It still works because we make sure that i and k have different labels so they must be distinct.

Could you correct this in a pull request?

omoindrot commented 6 years ago

Solved in #4