mvasil / fashion-compatibility

Learning Type-Aware Embeddings for Fashion Compatibility
BSD 3-Clause "New" or "Revised" License
152 stars 42 forks source link

Some problem about parameter learned_metric. #17

Open zuoxiang95 opened 4 years ago

zuoxiang95 commented 4 years ago

Hello @mvasil , Thanks for your excellent work. There is a problem with parameter learned_metric. I had trained a model with learned_metric=True. But when I run my inference code, I find the distance calculated by the model is a negative number.

BryanPlummer commented 4 years ago

The code itself isn't setup to learn a proper metric. However, you can do this kind of conversion fairly easily by using a sigmoid if it is necessary for your application.

zuoxiang95 commented 4 years ago

@BryanPlummer, thanks for your explanation, I will try it. And another thing I found is that the model will give a high score with the same or similar color items(especially using European distance), but sometimes two different colors are better than the two same colors. For example, black is more compatible with green than green.