提交 de87e576 authored 作者: notoraptor's avatar notoraptor

small correction.

上级 ba0a5e10
......@@ -4567,7 +4567,7 @@ class Reshape(Op):
x = as_tensor_variable(x)
shp_orig = shp
shp = as_tensor_variable(shp, ndim=1)
if not (shp.dtype in int_types or
if not (shp.dtype in int_dtypes or
(isinstance(shp, TensorConstant) and shp.data.size == 0)):
# It raises an error if shp is not of integer type,
# except when shp is constant and empty
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论