提交 3b9c8f7e authored 作者: Pierre Luc Carrier's avatar Pierre Luc Carrier 提交者: Pierre Luc Carrier

Validate that dot_input.owner is not None

上级 853bbb10
...@@ -729,7 +729,8 @@ class PushOutScanOutput(gof.Optimizer): ...@@ -729,7 +729,8 @@ class PushOutScanOutput(gof.Optimizer):
# 1 if sitsot_in_idx==0 # 1 if sitsot_in_idx==0
dot_input = nd.inputs[dot_in_idx] dot_input = nd.inputs[dot_in_idx]
if (isinstance(dot_input.owner.op, theano.tensor.Dot) and if (dot_input.owner is not None and
isinstance(dot_input.owner.op, theano.tensor.Dot) and
len(dot_input.clients) == 1 and len(dot_input.clients) == 1 and
dot_input.owner.inputs[0].ndim == 2 and dot_input.owner.inputs[0].ndim == 2 and
dot_input.owner.inputs[1].ndim == 2 and dot_input.owner.inputs[1].ndim == 2 and
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论