Cannot generate op.h when build with mkl

  • os : windows 10 64bits
  • compiler : vc2015 64bits update 3
  • mxnet : 1.3.1

I write down the steps of building at stackoverflow, please read it until step 14 if you want to know the details.

I use python download from here to generate op.h, but it throw error message

2>  "Running:"
2>  Traceback (most recent call last):
2>    File "", line 432, in <module>
2>      raise(e)
2>    File "", line 426, in <module>
2>      f.write(patternStr % ParseAllOps())
2>    File "", line 320, in ParseAllOps
2>      cdll.libmxnet = cdll.LoadLibrary(sys.argv[1])
2>    File "C:\Users\yyyy\AppData\Local\Programs\Python\Python37-32\lib\ctypes\", line 434, in LoadLibrary
2>      return self._dlltype(name)
2>    File "C:\Users\yyyy\AppData\Local\Programs\Python\Python37-32\lib\ctypes\", line 356, in __init__
2>      self._handle = _dlopen(self._name, mode)
2>  OSError: [WinError 193] %1 is not a valid Win32 application

Dependency of libmxnet.dll(by dumpbin)


Dependency of mkl_rt.dll(by dumpbin)


I put both of the dll, mkl_rt.dll and libmxnet.dll into a folder could be found by the os, try to generate op.h again, but it still give me the same error, how could I solve this issue? Thanks

ps : Use Anaconda3 can generate op.h, but it cause another issue " Intel MKL FATAL ERROR: Cannot load mkl_intel_thread.dll."

Solve this issue, the reason is I am using python with 32 bits, unfortunately using another version of python do not solve another issue " Intel MKL FATAL ERROR: Cannot load mkl_intel_thread.dll. "