Mabinogiysk opened a new issue #10005: Where should I put my dll after building 
from source?
URL: https://github.com/apache/incubator-mxnet/issues/10005
 
 
   ## Description
   I have built mxnet from source and I got error when I import mxnet in python:
   ```
   D:\Anaconda3\lib\ctypes\__init__.py in __init__(self, name, mode, handle, 
use_errno, use_last_error)
          347         if handle is None:
   --> 348             self._handle = _dlopen(self._name, mode)
         349         else:
         350             self._handle = handle
   
   OSError: [WinError 126] ?????????(can not find module)
   ```
   I have used dumpbin.exe to check libmxnet.dll:
   ```
   Dump of file .\libmxnet.dll
   
   File Type: DLL
   
     Image has the following dependencies:
   
       libopenblas.dll
       opencv_world341.dll
       cublas64_80.dll
       cufft64_80.dll
       cusolver64_80.dll
       curand64_80.dll
       nvrtc64_80.dll
       nvcuda.dll
       KERNEL32.dll
       VCOMP140.DLL
   ```
   I checked every directories in `$Path`. It seems that `opencv_world341.dll` 
and `libopenblas.dll` are missing. But I don't know where I should put them. I 
have tried directories such as 
`D:\Anaconda3\lib\site-packages\mxnet-1.2.0-py3.6.egg\mxnet`, 
`C:\Windows\system32` and restarted computer, but still got the same error.
   Those are all directories in $Path and dependencies:
   ```
   D:\Anaconda3\Library\bin
   C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\bin
   cublas64_80.dll
   cufft64_80.dll
   curand64_80.dll
   cusolver64_80.dll
   nvrtc64_80.dll
   C:\Program Files\NVIDIA GPU Computing Toolkit\CUDA\v8.0\libnvvp
   C:\Windows\system32
   kernel32.dll
   libopenblas.dll
   nvcuda.dll
   opencv_world341.dll
   C:\Windows
   C:\Windows\System32\Wbem
   C:\Windows\System32\WindowsPowerShell\v1.0\
   C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common
   C:\Program Files (x86)\Windows Kits\8.1\Windows Performance Toolkit\
   D:\UltraEdit
   D:\CMake\bin
   C:\Users\Lenovo\AppData\Local\Microsoft\WindowsApps
   ```
   What should I do?
   
   ## Environment info (Required)
   ```
   ----------Python Info----------
   Version      : 3.6.4
   Compiler     : MSC v.1900 64 bit (AMD64)
   Build        : ('default', 'Jan 16 2018 10:22:32')
   Arch         : ('64bit', 'WindowsPE')
   ------------Pip Info-----------
   Version      : 9.0.1
   Directory    : D:\Anaconda3\lib\site-packages\pip
   ----------MXNet Info-----------
   Hashtag not found. Not installed from pre-built package.
   ----------System Info----------
   Platform     : Windows-10-10.0.15063-SP0
   system       : Windows
   node         : DESKTOP-G2Q55BC
   release      : 10
   version      : 10.0.15063
   ----------Hardware Info----------
   machine      : AMD64
   processor    : Intel64 Family 6 Model 158 Stepping 9, GenuineIntel
   Name
   Intel(R) Core(TM) i3-7100 CPU @ 3.90GHz
   
   ```
   
   Package used (Python/R/Scala/Julia):
   I'm using Python
   
   ## Build info (Required if built from source)
   Compiler: visual studio 2015
   
   ## Error Message:
   ```
   OSError                                   Traceback (most recent call last)
   <ipython-input-1-1eadd2d362f9> in <module>()
   ----> 1 import mxnet
   
   D:\Anaconda3\lib\site-packages\mxnet-1.2.0-py3.6.egg\mxnet\__init__.py in 
<module>()
        23 
        24 from .context import Context, current_context, cpu, gpu
   ---> 25 from . import engine
        26 from .base import MXNetError
        27 from . import base
   
   D:\Anaconda3\lib\site-packages\mxnet-1.2.0-py3.6.egg\mxnet\engine.py in 
<module>()
        21 
        22 import ctypes
   ---> 23 from .base import _LIB, check_call
        24 
        25 
   
   D:\Anaconda3\lib\site-packages\mxnet-1.2.0-py3.6.egg\mxnet\base.py in 
<module>()
       111 __version__ = libinfo.__version__
       112 # library instance of mxnet
   --> 113 _LIB = _load_lib()
       114 
       115 # type definitions
   
   D:\Anaconda3\lib\site-packages\mxnet-1.2.0-py3.6.egg\mxnet\base.py in 
_load_lib()
       103     """Load library by searching possible path."""
       104     lib_path = libinfo.find_lib_path()
   --> 105     lib = ctypes.CDLL(lib_path[0], ctypes.RTLD_LOCAL)
       106     # DMatrix functions
       107     lib.MXGetLastError.restype = ctypes.c_char_p
   
   D:\Anaconda3\lib\ctypes\__init__.py in __init__(self, name, mode, handle, 
use_errno, use_last_error)
       346 
       347         if handle is None:
   --> 348             self._handle = _dlopen(self._name, mode)
       349         else:
       350             self._handle = handle
   
   OSError: [WinError 126] ?????????
   ```

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to