提交 9d0a7273 authored 作者: Razvan Pascanu's avatar Razvan Pascanu

test for the recent fix for one optimization of scan

上级 388a827b
......@@ -2676,6 +2676,13 @@ class T_Scan(unittest.TestCase):
dtype=theano.config.floatX)
assert numpy.allclose(f(vx, vA), vR)
def test_savemem_opt(self):
y0 = theano.shared(numpy.ones((2, 10)))
[y1, y2], updates = theano.scan(lambda y: [y, y],
outputs_info=[dict(initial=y0,
taps=[-2]), None],
n_steps=5)
rval = theano.function([], y2.sum())()
def test_speed():
#
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论