提交 f8e1fb6e authored 作者: abergeron's avatar abergeron

Merge pull request #2740 from nouiz/debugprint_file

fix gh-2738
...@@ -121,7 +121,7 @@ def debugprint(obj, depth=-1, print_type=False, ...@@ -121,7 +121,7 @@ def debugprint(obj, depth=-1, print_type=False,
scan_ops.append(r) scan_ops.append(r)
if p is not None: if p is not None:
print >> file, """ print >> _file, """
Timing Info Timing Info
----------- -----------
--> <time> <% time> - <total time> <% total time>' --> <time> <% time> - <total time> <% total time>'
...@@ -144,13 +144,13 @@ N.B.: ...@@ -144,13 +144,13 @@ N.B.:
scan_ops=scan_ops, stop_on_name=stop_on_name, scan_ops=scan_ops, stop_on_name=stop_on_name,
profile=p) profile=p)
if len(scan_ops) > 0: if len(scan_ops) > 0:
print >> file, "" print >> _file, ""
new_prefix = ' >' new_prefix = ' >'
new_prefix_child = ' >' new_prefix_child = ' >'
print >> file, "Inner graphs of the scan ops:" print >> _file, "Inner graphs of the scan ops:"
for s in scan_ops: for s in scan_ops:
print >> file, "" print >> _file, ""
debugmode.debugprint(s, depth=depth, done=done, debugmode.debugprint(s, depth=depth, done=done,
print_type=print_type, print_type=print_type,
file=_file, ids=ids, file=_file, ids=ids,
...@@ -167,7 +167,7 @@ N.B.: ...@@ -167,7 +167,7 @@ N.B.:
debugmode.debugprint(r=i, prefix=new_prefix, debugmode.debugprint(r=i, prefix=new_prefix,
depth=depth, done=done, depth=depth, done=done,
print_type=print_type, file=file, print_type=print_type, file=_file,
ids=ids, stop_on_name=stop_on_name, ids=ids, stop_on_name=stop_on_name,
prefix_child=new_prefix_child, prefix_child=new_prefix_child,
scan_ops=scan_ops) scan_ops=scan_ops)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论