提交 02a2b749 authored 作者: James Bergstra's avatar James Bergstra

merge

......@@ -164,7 +164,11 @@ def map_storage(env, order, input_storage, output_storage):
return input_storage, output_storage, storage_map
def streamline(env, thunks, order, no_recycling = [], profiler = None):
def streamline(env, thunks, order, no_recycling = [], profiler = None):
def clear():
for thunk in thunks:
for output in thunk.outputs:
output[0] = None
if profiler is None:
def f():
for x in no_recycling:
......@@ -183,6 +187,7 @@ def streamline(env, thunks, order, no_recycling = [], profiler = None):
profiler.profile_node(thunk, node)
profiler.profile_env(g, env)
f.profiler = profiler
f.clear = clear
return f
class LocalLinker(Linker):
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论