chartbeat-labs / textacy

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

Model not found #242

Closed Phlam54 closed 5 years ago

Phlam54 commented 5 years ago

Hello, Trying to make a doc with Textacy ( doc = textacy.make_spacy_doc(text) ), I have this message : [E050] Can't find model 'fr'. It doesn't seem to be a shortcut link, a Python package or a valid path to a data directory. I don't understand why, could you help please ?

bdewilde commented 5 years ago

Hi @Phlam54 , if you're relying on textacy to auto-detect text language then load the appropriate spacy language pipeline, you'll need to have the spacy models installed or linked to the language name. You have two French models installed, but neither has been linked to "fr", so when textacy tries to load the "fr" model, it can't find it. That's what the error message is trying to convey. To resolve this, just run $ python -m spacy link fr_core_news_{sm|md} fr in your terminal (choosing either sm or md to link).

I mention this in the docs — https://chartbeat-labs.github.io/textacy/getting_started/installation.html#downloading-data — but will make it more prominent.

Phlam54 commented 5 years ago

Dear Burton, Thank you so much for your quick answer.All the best,Philip Le vendredi 24 mai 2019 à 15:58:31 UTC+2, Burton DeWilde notifications@github.com a écrit :

Hi @Phlam54 , if you're relying on textacy to auto-detect text language then load the appropriate spacy language pipeline, you'll need to have the spacy models installed or linked to the language name. You have two French models installed, but neither has been linked to "fr", so when textacy tries to load the "fr" model, it can't find it. That's what the error message is trying to convey. To resolve this, just run $ python -m spacy link fr_corenews{sm|md} fr in your terminal (choosing either sm or md to link).

I mention this in the docs — https://chartbeat-labs.github.io/textacy/getting_started/installation.html#downloading-data — but will make it more prominent.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.