提交 e1edbefd authored 作者: Razvan Pascanu's avatar Razvan Pascanu

fix adding profiling only on True or non-empty strings

上级 551b590c
...@@ -355,7 +355,8 @@ class Scan(PureOp): ...@@ -355,7 +355,8 @@ class Scan(PureOp):
self.outputs[:slices] ] self.outputs[:slices] ]
wrapped_outputs += self.outputs[slices:] wrapped_outputs += self.outputs[slices:]
profile = None profile = None
if theano.config.profile or isinstance(self.profile, (str,bool)): if (theano.config.profile or (isinstance(self.profile, (str,bool))
and self.profile)):
profile = ScanProfileStats(name = self.name) profile = ScanProfileStats(name = self.name)
elif self.profile: elif self.profile:
profile = self.profile profile = self.profile
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论