forked from huawei/mindspore2022
fix reshape reshape case in auto parallel
This commit is contained in:
parent
0f22140331
commit
dcb91b0ef6
|
|
@ -88,7 +88,9 @@ class TwoReshapeEliminater : public AnfVisitor {
|
|||
|
||||
auto fg = node->func_graph();
|
||||
if (fg != nullptr && x_ != nullptr && shape_ != nullptr) {
|
||||
return fg->NewCNode({NewValueNode(prim_), x_, shape_});
|
||||
auto new_node = fg->NewCNode({NewValueNode(prim_), x_, shape_});
|
||||
new_node->set_abstract(node->abstract());
|
||||
return new_node;
|
||||
}
|
||||
return nullptr;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue