Skip to content
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

Installing models in Anaconda in Windows 7 fails with a linking error #1941

Closed
jganseman opened this issue Feb 6, 2018 · 4 comments
Closed
Labels
docs Documentation and website install Installation issues windows Issues related to Windows

Comments

@jganseman
Copy link
Contributor

Installing models for RASA in a conda environment in Windows, according to the docs that can be found on https://spacy.io/usage/models and http://nlu.rasa.ai/installation.html#setting-up-rasa-nlu , fails with a linking error:

`
(rasatests) C:\Users\jg>python -m spacy download en_core_web_md
Collecting https://github.com/explosion/spacy-models/releases/download/en_core_web_md-2.0.0/en_core_web_md-2.0.0.tar.gz
Downloading https://github.com/explosion/spacy-models/releases/download/en_core_web_md-2.0.0/en_core_web_md-2.0.0.tar.gz (120.8MB)
100% |¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦¦| 120.9MB 11.4MB/s
Requirement already satisfied (use --upgrade to upgrade): en-core-web-md==2.0.0 from https://github.com/explosion/spacy-models/releases/download/en_core_web_md-2.0.0/en_core_web_md-2.0.0.tar.gz in c:\users\jg\appdata\local\continuum\anaconda3\envs\rasatests\lib\site-packages

Error: Couldn't link model to 'en_core_web_md'
Creating a symlink in spacy/data failed. Make sure you have the required
permissions and try re-running the command as admin, or use a
virtualenv. You can still import the model as a module and call its
load() method, or create the symlink manually.

C:\Users\jg\AppData\Local\Continuum\anaconda3\envs\rasatests\lib\site-packages\en_core_web_md
-->
C:\Users\jg\AppData\Local\Continuum\anaconda3\envs\rasatests\lib\site-packages\spacy\data\en_core_web_md

Download successful but linking failed
Creating a shortcut link for 'en' didn't work (maybe you don't have
admin permissions?), but you can still load the model via its full
package name:

nlp = spacy.load('en_core_web_md')

`

Maybe the documentation should include a few lines about how to run as administrator? I'll see if I can figure it out and maybe contribute!

Your Environment

  • Operating System: Windows-7-6.1.7601-SP1
  • Python Version Used: 3.6.4
  • spaCy Version Used: 2.0.7
  • Environment Information: using Anaconda (conda 4.4.8, Anaconda Navigator 1.6.12)
@ines
Copy link
Member

ines commented Feb 6, 2018

I don't use Windows much, but I usually just right-click on the terminal app and select "Run as administrator", as described here. But maybe there's a more elegant way? In any case, I agree, I think the docs could at least link to a solution or thread on the topic, both on the models page and the troubleshooting guide.

@ines ines added docs Documentation and website install Installation issues windows Issues related to Windows labels Feb 6, 2018
@jganseman
Copy link
Contributor Author

jganseman commented Feb 6, 2018

It turns out that the solution here is to run Anaconda Navigator/Shell as admin (rightclick, ''Run As Administrator''). From within non-admin Anaconda I see no easy way to fire up an environment with admin credentials.

It also seems that care needs to be taken to only do the model download and linking in the admin environment (i.e. don't redo pip install rasa_core in admin mode). The rest of the tutorial can be completed in non-admin mode (albeit that a few deprecation warnings about sklearn and tensorflow pop up too, see image below:)

moodbot_test

@ines ines closed this as completed in ab33e27 Feb 9, 2018
@ines
Copy link
Member

ines commented Feb 9, 2018

Thanks for updating! I've added more details on this to the model download documentation (see ab33e27).

@lock
Copy link

lock bot commented May 7, 2018

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators May 7, 2018
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
docs Documentation and website install Installation issues windows Issues related to Windows
Projects
None yet
Development

No branches or pull requests

2 participants