提交 817ff62b authored 作者: Frederic Bastien's avatar Frederic Bastien

Make repeat test pass on 32bit python. We use the numpy code only for vector, not scalar

上级 45c7b96a
...@@ -436,6 +436,7 @@ class TestRepeatOp(utt.InferShapeTester): ...@@ -436,6 +436,7 @@ class TestRepeatOp(utt.InferShapeTester):
r_var = T.scalar(dtype=dtype) r_var = T.scalar(dtype=dtype)
r = numpy.asarray(3, dtype=dtype) r = numpy.asarray(3, dtype=dtype)
if dtype in self.numpy_unsupported_dtypes: if dtype in self.numpy_unsupported_dtypes:
r_var = T.vector(dtype=dtype)
self.assertRaises(TypeError, self.assertRaises(TypeError,
repeat, x, r_var, axis=axis) repeat, x, r_var, axis=axis)
else: else:
...@@ -489,6 +490,7 @@ class TestRepeatOp(utt.InferShapeTester): ...@@ -489,6 +490,7 @@ class TestRepeatOp(utt.InferShapeTester):
r_var = T.scalar(dtype=dtype) r_var = T.scalar(dtype=dtype)
r = numpy.asarray(3, dtype=dtype) r = numpy.asarray(3, dtype=dtype)
if dtype in self.numpy_unsupported_dtypes: if dtype in self.numpy_unsupported_dtypes:
r_var = T.vector(dtype=dtype)
self.assertRaises(TypeError, repeat, x, r_var) self.assertRaises(TypeError, repeat, x, r_var)
else: else:
self._compile_and_check( self._compile_and_check(
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论