首页 > 解决方案 > MXNET 重塑调用 ctypes

问题描述

在这里尝试使用“The Straight Dope”学习 MXNET。在线性代数 - 张量上,运行时出现 ctypes 错误,

X = nd.arange(24).reshape((2, 3, 4))

错误是,

C:\Anaconda2\lib\site-packages\mxnet\ndarray\ndarray.pyc in reshape(self, *shape, **kwargs)
   1060                                            c_array(ctypes.c_int64, shape),
   1061                                            reverse,
-> 1062                                            ctypes.byref(handle)))
   1063         return NDArray(handle=handle, writable=self.writable)
   1064

WindowsError: exception: access violation writing 0x00007FFB00000000

为什么会发生这种情况,我该如何解决?

标签: pythonmachine-learningneural-networkctypesmxnet

解决方案


在这里讨论了解决方案:https ://discuss.mxnet.io/t/reshape-error-calling-ctypes/1245/3

有帮助的是降级到 mxnet 1.2.0 并升级到 Python 2.7.15。


推荐阅读