ztane / python-Levenshtein

The Levenshtein Python C extension module contains functions for fast computation of Levenshtein distance and string similarity
GNU General Public License v2.0
1.26k stars 155 forks source link

Result seems incorrect #56

Closed RuABraun closed 4 years ago

RuABraun commented 4 years ago
>>> import Levenshtein as levd
>>> a='MOZILLA'
>>> b='MUSIAL'
>>> levd.distance(a, b)
4

This makes sense if one allows transpositions (the errors are O-U, Z-S, ins L, swap LA), but this is not documented anywhere (AFAIK) and means this package is actually implementing Damerau-Levenshtein distance?

RuABraun commented 4 years ago

Lol, I was wrong. Nevermind.