提交 47a46357 authored 作者: Roy Xue's avatar Roy Xue

New test function

上级 305cd4fb
...@@ -403,11 +403,16 @@ class T_function(unittest.TestCase): ...@@ -403,11 +403,16 @@ class T_function(unittest.TestCase):
""" """
Make test on free() function Make test on free() function
""" """
x = T.scalar('x') origin_config = theano.config.allow_gc
y = x * 3 try:
fn = function([x], y) theano.config.allow_gc = False
fn.free() x = T.scalar('x')
y = x * 3
func = function([x], y)
assert (var == [None] for var in func.fn.stoage_map)
func.free()
finally:
theano.config.allow_gc = origin_config
class T_picklefunction(unittest.TestCase): class T_picklefunction(unittest.TestCase):
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论