-
-
Notifications
You must be signed in to change notification settings - Fork 12
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Problems installing models on SpaCy 2.3.2 #8
Comments
Hi @ckmaresca, For the models not showing up in the output of For the second issue, the user warning, the specific model version For the third problem, the serialisation, it has been pointed out also in #6. Are you using the docs in a multi-process environment? If you have experience with spaCy maybe you could give some directions. Serialisation is a big issue I'm looking forward to solving. Martino |
Re: multi-process - not sure, I'm using whatever the default is (I don't know if SpaCy uses this natively or not) as I have not changed any of those settings and am not using multi-process currently. Also not using Re: serialization - I'm no SpaCy expert, but I also had issues with serialization (none of the methods in the SpaCy docs work), although in a different context. I need to serialize NLP Docs to a DB to avoid processing things in realtime. Serialization of SpaCy Doc objects took me a long time to figure out as traditional Pyton serialization doesn't work. I finally figured out out thanks to a few pointers from others. To serialize, I use the following:
To un-serialize:
Couple of notes:
Original solutions from https://stackoverflow.com/questions/49618917/what-is-the-recommended-way-to-serialize-a-collection-of-spacy-docs and https://stackoverflow.com/questions/30469575/how-to-pickle-and-unpickle-to-portable-string-in-python-3 |
I installed the models as per the directions in the README but they are not showing up in Spacy:
I'm installing using:
pip install https://github.com/MartinoMensio/spacy-universal-sentence-encoder/releases/download/v0.3.1/en_use_md-0.3.1.tar.gz#en_use_md-0.3.1
and
pip install https://github.com/MartinoMensio/spacy-universal-sentence-encoder/releases/download/v0.3.1/en_use_lg-0.3.1.tar.gz#en_use_lg-0.3.1
both of which complete successfully.
But calling
nlp = spacy.load('en_use_md')
results in the following error:/Users/username/.pyenv/versions/3.7.5/lib/python3.7/site-packages/spacy/util.py:275: UserWarning: [W031] Model 'en_use_md' (0.3.1) requires spaCy v2.1,<2 and is incompatible with the current spaCy version (2.3.2). This may lead to unexpected results or runtime errors. To resolve this, download a newer compatible model or retrain your custom model with the current spaCy version. For more details and available updates, run: python -m spacy validate
It then downloads what seems to be an updated version:
Downloaded https://tfhub.dev/google/universal-sentence-encoder/4, Total size: 987.47MB
But, as soon as any data is loading, I get the following error:
(traceback removed for shortness)
Not sure where to go from here...
The text was updated successfully, but these errors were encountered: