!33118 GPU change reduce-precision log level to INFO

Merge pull request !33118 from VectorSL/reduce-log
This commit is contained in:
i-robot 2022-04-16 03:30:11 +00:00 committed by Gitee
commit 63b53a7e45
No known key found for this signature in database
GPG Key ID: 173E9B9CA92EEF8F
2 changed files with 6 additions and 6 deletions

View File

@ -90,16 +90,16 @@ bool NativeGpuKernelModFactory::ReducePrecision(
(iter->second)[attr_index].first.GetInputAttr(input_index % attr_size).first == kNumberTypeInt32) {
builder->SetInputDeviceType(kNumberTypeInt32, input_index);
reduce_flag_.first.push_back(input_index);
MS_LOG(WARNING) << "Kernel [" << kernel_name << "] does not support int64, cast input " << input_index
<< " to int32.";
MS_LOG(INFO) << "Kernel [" << kernel_name << "] does not support int64, cast input " << input_index
<< " to int32.";
}
}
for (size_t output_index = 0; output_index < kernel_info->GetOutputNum(); output_index++) {
if (kernel_info->GetOutputDeviceType(output_index) == kNumberTypeInt64 &&
(iter->second)[attr_index].first.GetOutputAttr(output_index % attr_size).first == kNumberTypeInt32) {
builder->SetOutputDeviceType(kNumberTypeInt32, output_index);
MS_LOG(WARNING) << "Kernel [" << kernel_name << "] does not support int64, cast output " << output_index
<< " to int32.";
MS_LOG(INFO) << "Kernel [" << kernel_name << "] does not support int64, cast output " << output_index
<< " to int32.";
}
}
}

View File

@ -81,8 +81,8 @@ bool ReducePrecisionFusion::Run(const FuncGraphPtr &graph) {
auto deviceType = AnfAlgo::GetInputDeviceDataType(node, i);
if (inferType == kNumberTypeInt64 && deviceType == kNumberTypeInt32) {
ReducePrecision(graph, node, i, inferType, deviceType);
MS_LOG(WARNING) << "Reduce precision for [" << common::AnfAlgo::GetCNodeName(utils::cast<CNodePtr>(node))
<< "] input " << i;
MS_LOG(INFO) << "Reduce precision for [" << common::AnfAlgo::GetCNodeName(utils::cast<CNodePtr>(node))
<< "] input " << i;
}
}
for (size_t i = 0; i < output_num; i++) {