Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

mxnet installs but fails on import

I need mxnet for a linalg notebook. It installed successfully, but when I try to import it I get this error. Tbe final error is OSError: Exec format error

OSError Traceback (most recent call last) <ipython-input-10-1eadd2d362f9> in <module>() ----> 1 import mxnet

/opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/__init__.py in <module>() 22 from __future__ import absolute_import 23 ---> 24 from .context import Context, current_context, cpu, gpu, cpu_pinned 25 from . import engine 26 from .base import MXNetError

/opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/context.py in <module>() 22 import warnings 23 import ctypes ---> 24 from .base import classproperty, with_metaclass, _MXClassPropertyMetaClass 25 from .base import _LIB 26 from .base import check_call

/opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/base.py in <module>() 212 __version__ = libinfo.__version__ 213 # library instance of mxnet --> 214 _LIB = _load_lib() 215 216 # type definitions

/opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/base.py in _load_lib() 203 """Load library by searching possible path.""" 204 lib_path = libinfo.find_lib_path() --> 205 lib = ctypes.CDLL(lib_path[0], ctypes.RTLD_LOCAL) 206 # DMatrix functions 207 lib.MXGetLastError.restype = ctypes.c_char_p

/opt/sagemath-9.0/local/lib/python3.7/ctypes/__init__.py in __init__(self, name, mode, handle, use_errno, use_last_error) 354 355 if handle is None: --> 356 self._handle = _dlopen(self._name, mode) 357 else: 358 self._handle = handle

OSError: Exec format error

mxnet installs but fails on import

I need mxnet for a linalg notebook. It installed successfully, but when I try to import it I get this error. Tbe The final error is OSError: Exec format error.

OSError                                   Traceback (most recent call last)
<ipython-input-10-1eadd2d362f9> in <module>()
----> 1 import mxnet

mxnet /opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/__init__.py in <module>() 22 from __future__ import absolute_import 23 ---> 24 from .context import Context, current_context, cpu, gpu, cpu_pinned 25 from . import engine 26 from .base import MXNetError

MXNetError /opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/context.py in <module>() 22 import warnings 23 import ctypes ---> 24 from .base import classproperty, with_metaclass, _MXClassPropertyMetaClass 25 from .base import _LIB 26 from .base import check_call

check_call /opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/base.py in <module>() 212 __version__ = libinfo.__version__ 213 # library instance of mxnet --> 214 _LIB = _load_lib() 215 216 # type definitions

definitions /opt/sagemath-9.0/local/lib/python3.7/site-packages/mxnet/base.py in _load_lib() 203 """Load library by searching possible path.""" 204 lib_path = libinfo.find_lib_path() --> 205 lib = ctypes.CDLL(lib_path[0], ctypes.RTLD_LOCAL) 206 # DMatrix functions 207 lib.MXGetLastError.restype = ctypes.c_char_p

ctypes.c_char_p /opt/sagemath-9.0/local/lib/python3.7/ctypes/__init__.py in __init__(self, name, mode, handle, use_errno, use_last_error) 354 355 if handle is None: --> 356 self._handle = _dlopen(self._name, mode) 357 else: 358 self._handle = handle

handle OSError: Exec format error

error