by tmalsburg2 · 11y ago · 0 comments
d(a, c) <= d(a, b) + d(b, c) (triangle inequality)
d(a, b) = d(b, a) (symmetry)
d(a, a) = 0 (reflexivity)
Many efficient algorithms operating on distances need the distance measure to be metric in this sense, otherwise they don't work (e.g., [1]). There is also a lot of really useful math that can’t be applied if a distance measure is not a metric. One important question therefore is whether Sift4 is a metric or not. I haven’t looked at the definition of the algorithm but the author acknowledges that the measure is not symmetric, so it can't be a metric. Despite its speed the Sift4 can therefore often not be used as a drop-in replacement for the Levenshtein distance. There is a reason for why we’re are still using the Levenshtein distance despite its somewhat poor scaling properties.Unless there're clever compilation algorithms to calculate edit distance really fast, that fall apart without a metric...?