def test_output_list_still_works(self):
'''
Test that theano.function works if outputs is a list.
'''
x = T.scalar('x')
f = theano.function([x], outputs=[x * 3, x * 2, x * 4, x])
result = f(5.0)
assert result[0] == 15.0
assert result[1] == 10.0
assert result[2] == 20.0
assert result[3] == 5.0
test_dictionary_output.py 文件源码
python
阅读 18
收藏 0
点赞 0
评论 0
评论列表
文章目录