提交 1d221db2 authored 作者: Frederic's avatar Frederic

Fix the crash.

上级 a05cd7c5
...@@ -817,8 +817,13 @@ class ProfileStats(object): ...@@ -817,8 +817,13 @@ class ProfileStats(object):
if max_mem_count > mem_bound: if max_mem_count > mem_bound:
continue continue
viewed_by_temp = viewed_by.copy()
view_of_temp = view_of.copy() view_of_temp = view_of.copy()
# We don't want a shallow copy, but we don't want
# a deep copy. So this do a "middle" copy, where
# we copy the dict and the list, but not the var
viewed_by_temp = {}
for k, v in viewed_by.iteritems():
viewed_by_temp[k] = list(v)
for var in node.outputs: for var in node.outputs:
compute_map[var][0] = 1 compute_map[var][0] = 1
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论