Browse Source

Erase kAttrPynativeNextOpName and kAttrPynativeNextIndex after SelectKernel

tags/v1.1.0
tanghuikang 5 years ago
parent
commit
acd910323e
1 changed files with 2 additions and 0 deletions
  1. +2
    -0
      mindspore/ccsrc/backend/session/ascend_session.cc

+ 2
- 0
mindspore/ccsrc/backend/session/ascend_session.cc View File

@@ -771,6 +771,8 @@ void AscendSession::SelectKernel(const KernelGraph &kernel_graph) const {
size_t reduce_precision_count = 0; size_t reduce_precision_count = 0;
for (const auto &cnode : kernel_graph.execution_order()) { for (const auto &cnode : kernel_graph.execution_order()) {
auto status = device::ascend::SelectKernelInfo(cnode); auto status = device::ascend::SelectKernelInfo(cnode);
AnfAlgo::EraseNodeAttr(kAttrPynativeNextOpName, cnode);
AnfAlgo::EraseNodeAttr(kAttrPynativeNextIndex, cnode);
if (status == device::ascend::kStatusRaisePrecision) { if (status == device::ascend::kStatusRaisePrecision) {
raise_precision_count++; raise_precision_count++;
} else if (status == device::ascend::kStatusReducePrecision) { } else if (status == device::ascend::kStatusReducePrecision) {


Loading…
Cancel
Save