提交 4deb04c9 authored 作者: Benjamin Scellier's avatar Benjamin Scellier

file theano/compile/sharedvalue.py

上级 2f8b838e
......@@ -9,7 +9,7 @@ import copy
import logging
# Third-party imports
import numpy
import numpy as np
# Theano imports
from theano.gof import Container, Variable, generic, utils
......@@ -162,7 +162,7 @@ class SharedVariable(Variable):
# implemented at all, but with a more explicit error message to help
# Theano users figure out the root of the problem more easily.
value = self.get_value(borrow=True)
if isinstance(value, numpy.ndarray):
if isinstance(value, np.ndarray):
# Array probably had an unknown dtype.
msg = ("a Numpy array with dtype: '%s'. This data type is not "
"currently recognized by Theano tensors: please cast "
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论