Skip to content
This repository has been archived by the owner on Apr 20, 2020. It is now read-only.

SpaCy package broken #21

Closed
oersoy1 opened this issue Jun 26, 2018 · 2 comments
Closed

SpaCy package broken #21

oersoy1 opened this issue Jun 26, 2018 · 2 comments

Comments

@oersoy1
Copy link

oersoy1 commented Jun 26, 2018

Getting an error while trying to load the basic English Model (module)

nlp = spacy.load('en')

Output:

---------------------------------------------------------------------------
OSError                                   Traceback (most recent call last)
<ipython-input-21-76abff010c5f> in <module>()
----> 1 nlp = spacy.load('en')

/usr/local/lib/python3.5/dist-packages/spacy/__init__.py in load(name, **overrides)
     13     if depr_path not in (True, False, None):
     14         deprecation_warning(Warnings.W001.format(path=depr_path))
---> 15     return util.load_model(name, **overrides)
     16 
     17 

/usr/local/lib/python3.5/dist-packages/spacy/util.py in load_model(name, **overrides)
    117     elif hasattr(name, 'exists'):  # Path or Path-like to model data
    118         return load_model_from_path(name, **overrides)
--> 119     raise IOError(Errors.E050.format(name=name))
    120 
    121 

OSError: [E050] Can't find model 'en'. It doesn't seem to be a shortcut link, a Python package or a valid path to a data directory.

Seems like

python -m spacy download en

will solve the problem.

See:
explosion/spaCy#1721
or similar github issues

@jdimeo
Copy link

jdimeo commented Jun 26, 2018

Ha! I just ran into this when trying to run Tom's Glyphic model using spacy. The key for me was (1) running with admin privs and (2) actually installing to the right location. For whatever reason, when I did python -m spacy download en it went to the wrong virtualenv and wasn't until I installed it through R did it start working (the R piece is not relevant for this, just to give an example of installing in the wrong location).

@RZachLamberty
Copy link

resolved in 2cea0b8

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants