Incubator-mxnet: import mxnet error

Created on 3 Jul 2016  路  5Comments  路  Source: apache/incubator-mxnet

I wanna test a faster rcnn demo and re-compiled a MXNet for detection version. I have compiled out the libs and dlls, but I set the python interface and meet the following error:

import mxnet
Traceback (most recent call last):
File "", line 1, in
File "D:\Anaconda2\lib\site-packages\mxnet-0.7.0-py2.7.egg\mxnet__init__.py", line 7, in
from .base import MXNetError
File "D:\Anaconda2\lib\site-packages\mxnet-0.7.0-py2.7.egg\mxnet\base.py", line 43, in
_LIB = _load_lib()
File "D:\Anaconda2\lib\site-packages\mxnet-0.7.0-py2.7.egg\mxnet\base.py", line 35, in _load_lib
lib = ctypes.cdll.LoadLibrary(lib_path[0])
File "D:\Anaconda2\lib\ctypes__init__.py", line 443, in LoadLibrary
return self._dlltype(name)
File "D:\Anaconda2\lib\ctypes__init__.py", line 365, in init
self._handle = _dlopen(self._name, mode)
WindowsError: [Error 126]

I think it's a environment-path error but i don't know how to fix it. The official instructor is only for linux.

Most helpful comment

WindowsError: [Error 126]
This is usually because the dependent dll not find.So, you can:
1.use the 'Depends' tools open the libmxnet.dll, see which dll is missing.
2.make sure the u have the dll in your machine, and add the environment-path.

All 5 comments

@hjk41

Sometimes it's caused by OpenCV. Remember to add the OpenCV library to the environment variable.

WindowsError: [Error 126]
This is usually because the dependent dll not find.So, you can:
1.use the 'Depends' tools open the libmxnet.dll, see which dll is missing.
2.make sure the u have the dll in your machine, and add the environment-path.

Thank you for solving my trouble @cjfan

I have same problem, actually, my project is work yesterday,and I can't find the reason.

Was this page helpful?
0 / 5 - 0 ratings