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

Try to fix floating precision error (detected via travis on my online repo).

上级 94d648d9
...@@ -5491,5 +5491,5 @@ def test_default_value_broadcasted(): ...@@ -5491,5 +5491,5 @@ def test_default_value_broadcasted():
gW_x = theano.tensor.grad(cost, W_x) gW_x = theano.tensor.grad(cost, W_x)
updates = [(W_x, W_x - 0.1 * gW_x)] updates = [(W_x, W_x - 0.1 * gW_x)]
f = theano.function([X], outputs=cost, updates=updates) f = theano.function([X], outputs=cost, updates=updates)
test = f(numpy.random.rand(10, in_size)) test = f(numpy.random.rand(10, in_size).astype(X.dtype))
print(test) print(test)
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论