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

Python (SPYDER) Import modules #41

Open
loooo94 opened this issue Jun 17, 2020 · 3 comments
Open

Python (SPYDER) Import modules #41

loooo94 opened this issue Jun 17, 2020 · 3 comments

Comments

@loooo94
Copy link

loooo94 commented Jun 17, 2020

Hi, I've just tried to import numpy or matplotlib in grasshopper with GH_CPython.
I have Spyder 3 (ANACONDA), Python standalone, Microsoft Visual studio.
My operating system is Windows 10.

It gives me a long errors messages and gives me some advise like:

  1. D:\anaconda3\lib\site-packages\numpy_init_.py:140: UserWarning: mkl-service package failed to import, therefore Intel(R) MKL initialization ensuring its correct out-of-the box operation under condition when Gnu OpenMP had already been loaded by Python process is not assured. Please install mkl-service package, see http://github.com/IntelPython/mkl-service
    "

from . import distributor_init
Traceback (most recent call last):
File "D:\anaconda3\lib\site-packages\numpy\core_init
.py", line 24, in
from . import multiarray
File "D:\anaconda3\lib\site-packages\numpy\core\multiarray.py", line 14, in
from . import overrides
File "D:\anaconda3\lib\site-packages\numpy\core\overrides.py", line 7, in
from numpy.core._multiarray_umath import (
ImportError: DLL load failed: The specified module could not be found.

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "C:\GH_CPython\PythonFileWritten_6.py", line 24, in
import numpy as np
File "D:\anaconda3\lib\site-packages\numpy_init_.py", line 142, in
from . import core
File "D:\anaconda3\lib\site-packages\numpy\core_init_.py", line 54, in
raise ImportError(msg)
ImportError:

"

So, I don't knwo how can I figure out this issue! My goal is be able to use the whole python libraries on Grasshopper.

Thanks!

@MahmoudAbdelRahman
Copy link
Owner

MahmoudAbdelRahman commented Jun 17, 2020

Hi @loooo94 ,
Are you able to import numpy and matplotlib using D:\anaconda3\Python.exe ?

@loooo94
Copy link
Author

loooo94 commented Jun 17, 2020

Yes I use it in Anaconda3.
Maybe should be this: mkl-service but I don't understand where I need to check for this.

@chirth
Copy link

chirth commented Nov 10, 2021

Hi, is this resolved yet?
I had a similar problem when trying to use the interpreter from a conda environment. Seems like the environment's interpreter was used but outside the environment.

Is there a way to run GH_CPython within a specific environment?

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

No branches or pull requests

3 participants