Skip to main content

Library providing functions to calculate Levenshtein distance, Optimal String Alignment distance, and Damerau-Levenshtein distance, where the cost of each operation can be weighted by letter.

Project description

Codebase forked from https://github.com/infoscout/weighted-levenshtein

Install

pip3 install weighted-levenshtein-substring

Usage

Use

from weighted_levenshtein import mod_lev

distance: float = mod_lev(string, pattern)

To find the lowest edit distance between pattern and any substring of string.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

weighted_levenshtein-substring-0.0.3.tar.gz (135.0 kB view hashes)

Uploaded Source

Built Distribution

weighted_levenshtein_substring-0.0.3-cp37-cp37m-macosx_10_9_x86_64.whl (89.1 kB view hashes)

Uploaded CPython 3.7m macOS 10.9+ x86-64

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page