Add warning log.

This commit is contained in:
gaoyong10 2021-12-30 19:35:14 +08:00
parent b6081c5fb9
commit 815babc29f
1 changed files with 4 additions and 1 deletions

View File

@ -1228,7 +1228,10 @@ void ControlNodeScheduler::LinkDataArrow(AbstractActor *const from_actor, Abstra
size_t from_index, size_t to_index, const AnfNodePtr &from_kernel) {
MS_EXCEPTION_IF_NULL(from_actor);
MS_EXCEPTION_IF_NULL(to_actor);
if (from_actor->type() == KernelTransformType::kKernelActor && to_actor->type() != KernelTransformType::kExitActor) {
MS_LOG(WARNING) << "Kernel actor:" << from_actor->GetAID() << " link data arrow to actor:" << to_actor->GetAID()
<< " is not an exit actor.";
}
auto data_arrow = std::make_shared<DataArrow>(from_index, to_actor->GetAID(), to_index);
(void)from_actor->output_data_arrows_.emplace_back(data_arrow);
(void)from_actor->output_data_nodes_.emplace_back(from_kernel);