docwmd-0.0.6
توضیحات
A small package using wmd to get closet doc to a chosen doc
| ویژگی | مقدار |
|---|---|
| سیستم عامل | OS Independent |
| نام فایل | docwmd-0.0.6 |
| نام | docwmd |
| نسخه کتابخانه | 0.0.6 |
| نگهدارنده | [] |
| ایمیل نگهدارنده | [] |
| نویسنده | Alice Petit, Nolwenn Sourice |
| ایمیل نویسنده | - |
| آدرس صفحه اصلی | https://gitlab.com/guillaume.burgaud.name/smd |
| آدرس اینترنتی | https://pypi.org/project/docwmd/ |
| مجوز | - |
# Word Mover's Distance using Fast Word Mover's Distance
Calculates Word Mover's Distance using [Fast Word Mover's Distance](https://github.com/src-d/wmd-relax).
**Installation**
Before installing the package, check that you have already installed :
> [Numpy](https://pypi.org/project/numpy/)
>
> [wmd](https://pypi.org/project/wmd/)
>
> [NLTK](https://pypi.org/project/nltk/)
>
> [Spacy](https://pypi.org/project/spacy/)
>
> [en_core_web_lg](https://spacy.io/usage/models)
```
pip install numpy
pip install wmd
pip install nltk
pip install spacy
python -m spacy download en_core_web_lg
```
Then
```
pip install docwmd
```
Tested on Linux and macOS.
**Usage**
You must have the document you want to find the closest document as a string and the other documents as a list of strings.
```python
from docwmd import docWMD
calc = docWMD("Politician speaks to the media in Illinois.", ["The president greets the press in Chicago.", "The President delivers his inaugural address."])
print(calc.get_closest())
```
This returns the number of the nearest document and its distance.
زبان مورد نیاز
| مقدار | نام |
|---|---|
| >=3.6 | Python |
نحوه نصب
نصب پکیج whl docwmd-0.0.6:
pip install docwmd-0.0.6.whl
نصب پکیج tar.gz docwmd-0.0.6:
pip install docwmd-0.0.6.tar.gz