提交 856fdd09 authored 作者: Ian Goodfellow's avatar Ian Goodfellow

added call to function using log softmax so DEBUG_MODE can verify the

optimization
上级 973c2669
......@@ -142,9 +142,15 @@ def test_stabilize_log_softmax():
f = function([x],z)
#check that the softmax has been optimized out
for node in f.maker.fgraph.toposort():
assert not isinstance(node.op, y.owner.op.__class__)
#call the function so debug mode can verify the optimized
#version matches the unoptimized version
rng = numpy.random.RandomState([2012,8,22])
f(numpy.cast[config.floatX](rng.randn(2,3)))
def test_add_canonizer_problem0():
n_segments = 10
label = lscalar('label')
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论