未验证 提交 957e182a 编写于 作者: H hong 提交者: GitHub

revert a+b axis change; test=develop (#21821)

上级 6624ea76
...@@ -225,13 +225,15 @@ def monkey_patch_variable(): ...@@ -225,13 +225,15 @@ def monkey_patch_variable():
other_var = tmp other_var = tmp
out = create_new_tmp_var(current_block(self), dtype=lhs_dtype) out = create_new_tmp_var(current_block(self), dtype=lhs_dtype)
axis = -1
if other_var.shape[0] == -1:
axis = 0
current_block(self).append_op( current_block(self).append_op(
type=op_type, type=op_type,
inputs={'X': [self], inputs={'X': [self],
'Y': [other_var]}, 'Y': [other_var]},
outputs={'Out': out}, outputs={'Out': out},
attrs={'axis': -1}) attrs={'axis': axis})
return out return out
comment = OpProtoHolder.instance().get_op_proto(op_type).comment comment = OpProtoHolder.instance().get_op_proto(op_type).comment
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册