chartbeat-labs / textacy

NLP, before and after spaCy
https://textacy.readthedocs.io
Other
2.21k stars 249 forks source link

AttributeError: module 'textacy' has no attribute 'vsm' #333

Closed teodor-g closed 3 years ago

teodor-g commented 3 years ago

I have just installed textacy using pip, hoping to produce a word frequency matrix. Following an online tutorial, I went looking for the Vectorizer attribute. Unfortunately, that is nowhere to be found. I will provide my machine specifications, as well as results of running the dir(textacy) command below.

OS: Linux-5.4.0-72-generic-x86_64-with-glibc2.29 textacy verson: 0.11.0 spacy version: 3.0.5 Pipelines: nl_core_news_lg (3.0.0), en_core_web_lg (3.0.0) Python version: 3.8.5

dir(textacy) yields: ['Corpus', 'DEFAULT_DATA_DIR', 'builtins', 'cached', 'doc', 'file', 'loader', 'name', 'package', 'path', 'spec', 'version', '_version', 'cache', 'constants', 'corpus', 'errors', 'extensions', 'extract', 'get_doc_extensions', 'identify_lang', 'io', 'lang_id', ‘load_spacy_lang', 'logger', 'logging', 'make_spacy_doc', 'remove_doc_extensions', 'representations', 'set_doc_extensions', 'similarity', 'spacier', 'types', 'utils']

Do you have any idea what I might be missing? Let me know if you need me to provide anything else.

Thanks in advance!

bdewilde commented 3 years ago

Hi @teodor-g , that functionality has moved as of v0.11 — instead of textacy.vsm.vectorizers, it's now found at textacy.representations.vectorizers.

Here are the release notes describing the change: https://github.com/chartbeat-labs/textacy/releases/tag/0.11.0

And here are official docs describing the vectorizer API: https://textacy.readthedocs.io/en/latest/api_reference/representations.html#vectorizers

teodor-g commented 3 years ago

Thank you! I'll get down to reading.

Have a nice evening.

Cheers, Teo

On Tue, Apr 20, 2021 at 8:52 PM Burton DeWilde @.***> wrote:

Hi @teodor-g https://github.com/teodor-g , that functionality has moved as of v0.11 — instead of textacy.vsm.vectorizers, this functionality is now found at textacy.representations.vectorizers.

Here are the release notes describing the change: https://github.com/chartbeat-labs/textacy/releases/tag/0.11.0

And here are official docs describing the vectorizer API: https://textacy.readthedocs.io/en/latest/api_reference/representations.html#vectorizers

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/chartbeat-labs/textacy/issues/333#issuecomment-823521301, or unsubscribe https://github.com/notifications/unsubscribe-auth/ANO3P35E26SBAQ4S6TFYP33TJXEPVANCNFSM43IZNVJQ .