Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Where can the documentation for python-Levenshtein be found online? [closed]

I've found a great python library implementing Levenshtein functions (distance, ratio, etc.) at http://code.google.com/p/pylevenshtein/ but the project seems inactive and the documentation is nowhere to be found. I was wondering if anyone knows better than me and can point me to the documentation.

like image 360
Phil B Avatar asked Aug 08 '13 19:08

Phil B


People also ask

What is Python levenshtein?

Levenshtein is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version. See the file COPYING for the full text of GNU General Public License version 2.

What is levenshtein ratio?

The python-Levenshtein ratio is computed as follows (in ratio_py): return (lensum - ldist) / lensum. ldist is the Levenshtein distance, lensum is the sum of the two string lengths. If lensum is zero (two empty strings), ratio_py returns 1.0 as a special case.


3 Answers

Here is an example:

# install with: pip install python-Levenshtein  from Levenshtein import distance edit_dist = distance("ah", "aho") 
like image 181
Renaud Avatar answered Sep 25 '22 01:09

Renaud


You won't have to generate the docs yourself. There's an online copy of the original Python Levenshtein API: http://www.coli.uni-saarland.de/courses/LT1/2011/slides/Python-Levenshtein.html

like image 29
lecodesportif Avatar answered Sep 25 '22 01:09

lecodesportif


Follow instructions at the updated version: https://github.com/joncasdam/python-Levenshtein

To get a generated documentation. This was updated 3 months back.

like image 29
sihrc Avatar answered Sep 24 '22 01:09

sihrc