1
$\begingroup$

I compute Euclidian distances between a point I want to analyze and a set of points I have. I want to sort my points by decreasing "similarity".

I used to compute a "score" by inverting the distance ($s=1/d$), and use the $\cfrac{s_i}{\sum_k s_k}$ as a similarity that varies between $0$ and $1$.

I have seen that the $softmax$ function can also be used, the difference being that it uses $e^d$ as the score.

Which function would be closer to computing a kind of "probability"? I should apologize for probably mixing terms...

$\endgroup$
  • 2
    $\begingroup$ Probability of what? Both give nonnegative scores that sum to one. Neither is particularly anything like a probability. Softmax will decay quickly beyond the closest point, while the sum one will distribute scores more widely. $\endgroup$ – Dougal Feb 4 '17 at 1:40
  • $\begingroup$ If you're not familiar, you might want to look at kernels. $\endgroup$ – Dougal Feb 4 '17 at 1:42
  • $\begingroup$ @Dougal, thank you, your first comment answers my question ... and your second one gives me homework ;) If you add that as an answer I'll accept it. $\endgroup$ – Matthieu Feb 4 '17 at 11:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.