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

ImportError: libmkl_intel_lp64.so: cannot open shared object file #1621

Closed
zhanghang1989 opened this issue May 23, 2017 · 4 comments
Closed

Comments

@zhanghang1989
Copy link

I have the following error when import torch in iPython. But I can still run the program using terminal. Any thoughts about this error? Thanks!

Python 2.7.12 (default, Nov 19 2016, 06:48:10) 
Type "copyright", "credits" or "license" for more information.

IPython 5.3.0 -- An enhanced Interactive Python.
?         -> Introduction and overview of IPython's features.
%quickref -> Quick reference.
help      -> Python's own help system.
object?   -> Details about 'object', use 'object??' for extra details.

In [1]: import torch
---------------------------------------------------------------------------
ImportError                               Traceback (most recent call last)
<ipython-input-1-c031d3dd82fc> in <module>()
----> 1 import torch
/home/hangzhang/pytorch/torch/__init__.pyc in <module>()
     51 sys.setdlopenflags(_dl_flags.RTLD_GLOBAL | _dl_flags.RTLD_NOW)
     52 
---> 53 from torch._C import *
     54 
     55 __all__ += [name for name in dir(_C)

ImportError: libmkl_intel_lp64.so: cannot open shared object file: No such file or directory
@apaszke
Copy link
Contributor

apaszke commented May 23, 2017

Did you compile it from source or is it a binary install?

@zhanghang1989
Copy link
Author

I got the problem. It was a mistake. I recently uninstalled conda 2 and installed conda 3, but haven't reinstalled IPython. Now it is working fine. Thanks for the help!

@Deepayan137
Copy link

hey, even I am facing the same issue.
from torch._C import * ImportError: libmkl_intel_lp64.so: cannot open shared object file: No such file or directory
I compiled it from source. Can anyone suggest as to where I am going wrong?

@zhanghang1989
Copy link
Author

Try a clean re-install.

rm -rf build
rm -rf torch/lib/build

Then install again

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