我正在运行这个简单的示例:
import theano
x = theano.tensor.dscalar()
f = theano.function([x], 2*x)
f(4)
Run Code Online (Sandbox Code Playgroud)
我得到:
AttributeError: ('The following error happened while compiling the node', Elemwise{mul,no_inplace}(TensorConstant{2.0}, <TensorType(float64, scalar)>), '\n', "module 'numpy.core.multiarray' has no attribute '_get_ndarray_c_version'")
Run Code Online (Sandbox Code Playgroud)
我虽然一定是一个小错误,所以我尝试更新,但据我所知我拥有最新版本:
import numpy
numpy.version.version
'1.16.2'
Run Code Online (Sandbox Code Playgroud)
我正在spyder中运行所有这些,但这似乎无关紧要,因为我在python解释器中遇到了相同的错误