Open
Description
A typically use case of metric learning is to use the learned metric to predict whether two examples match or not (as in facial verification applications). This can be the case even though the metric has not been learned from pairwise supervision (positive/negative pairs) but from quadruplet or even fully supervised (e.g., LMNN).
Therefore it would potentially be useful to give a simple way for users to do that for metric learners that are not PairsClassifierMixin
.
I see two possible options:
- add a
predict_pairs
method and copy the methods to set/calibrate the decision threshold fromPairsClassifierMixin
introduced in [MRG+1] Threshold for pairs learners #168
drawback: not compatible with sklearn which expectspredict
- add a new instance of
PairsClassifierMixin
which takes as input a predefined metric instead of fitting on data, see point 3/ in [MRG+1] Threshold for pairs learners #168 (review)
drawback: user needs to instantiate a new object after fitting the metric