提交 851e3dd1 authored 作者: Frederic's avatar Frederic

Better test

上级 1547ecc6
......@@ -304,7 +304,9 @@ def test_careduce():
def test_flatten():
x = cuda.fmatrix('x')
f = theano.function([x], x.flatten())
f = theano.function([x], x.flatten(), mode=mode_with_gpu)
assert any([node for node in f.maker.fgraph.toposort()
if isinstance(node.op, B.GpuFlatten)])
assert len(f([[0., 0.], [0., 0.]]).shape) == 1
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论