From c2be5bb8d9ae3f74666ad77c3f5cdb18d4a5518f Mon Sep 17 00:00:00 2001 From: lianliguang Date: Tue, 28 Apr 2020 15:32:15 +0800 Subject: [PATCH] change runtime error to type error when cannot find kernel info --- mindspore/ccsrc/device/ascend/kernel_select_ascend.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/mindspore/ccsrc/device/ascend/kernel_select_ascend.cc b/mindspore/ccsrc/device/ascend/kernel_select_ascend.cc index 1efd3d6c2..d8779bc55 100644 --- a/mindspore/ccsrc/device/ascend/kernel_select_ascend.cc +++ b/mindspore/ccsrc/device/ascend/kernel_select_ascend.cc @@ -482,8 +482,8 @@ void SelectKernelInfo(const CNodePtr &kernel_node) { if (selected_kernel_info == nullptr) { std::ostringstream buffer; PrintInputAndOutputInferType(buffer, kernel_node); - MS_LOG(EXCEPTION) << "The node [" << kernel_node->DebugString() - << "] cannot find valid kernel info, not supported the type" << buffer.str(); + MS_EXCEPTION(TypeError) << "The node [" << kernel_node->DebugString() + << "] cannot find valid kernel info, not supported the type" << buffer.str(); } else { PrintRaiseOrReducePrecisionSelectedInfo(kernel_node, selected_kernel_info, precision_reduce); } -- GitLab