def summary(self, file=sys.stderr, n_ops_to_print=20,
n_apply_to_print=20):
self.summary_function(file)
self.summary_globals(file)
local_time = sum(self.apply_time.values())
if local_time > 0:
self.summary_class(file, n_ops_to_print)
self.summary_ops(file, n_ops_to_print)
self.summary_nodes(file, n_apply_to_print)
elif self.fct_callcount > 0:
print(" No execution time accumulated "
"(hint: try config profiling.time_thunks=1)", file=file)
if config.profiling.debugprint:
fcts = set([n.fgraph for n in self.apply_time.keys()])
theano.printing.debugprint(fcts, print_type=True)
if self.variable_shape or self.variable_strides:
self.summary_memory(file, n_apply_to_print)
if self.optimizer_profile:
print("Optimizer Profile", file=file)
print("-----------------", file=file)
self.optimizer_profile[0].print_profile(file,
self.optimizer_profile[1])
self.print_tips(file)
评论列表
文章目录