Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when using edit_distance on list and tuple. #1

Open
HOZHENWAI opened this issue Apr 15, 2024 · 1 comment
Open

Error when using edit_distance on list and tuple. #1

HOZHENWAI opened this issue Apr 15, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@HOZHENWAI
Copy link

One of the advantage of the Levenshtein library is that the distance function works on any iterable like list and tuple.

from Levenshtein import distance

distance([0,1,2,3,4,5], [5,4,1,2,3])

versus

from fast_edit_distance import edit_distance

edit_distance([0,1,2,3,4,5], [5,4,1,2,3])
@HOZHENWAI
Copy link
Author

HOZHENWAI commented Apr 15, 2024

Obvious workaround would simply be to convert the iterable into string but we would have to check on the efficiency of the conversion.

@youyupei youyupei added the enhancement New feature or request label Apr 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants