!12429 correct data type before schedule npu kernel
From: @zhaozhenlong Reviewed-by: @zhanghaibo5,@ddwsky Signed-off-by: @zhanghaibo5
This commit is contained in:
commit
73278d43ba
|
@ -209,6 +209,9 @@ kernel::LiteKernel *Scheduler::FindBackendKernel(const std::vector<Tensor *> &in
|
|||
#endif
|
||||
#if SUPPORT_NPU
|
||||
if (context_->IsNpuEnabled()) {
|
||||
if (desc.data_type == kNumberTypeFloat16) {
|
||||
desc.data_type = kNumberTypeFloat32;
|
||||
}
|
||||
kernel::KernelKey npu_desc{kNPU, desc.data_type, desc.type};
|
||||
auto *kernel = KernelRegistry::GetInstance()->GetKernel(in_tensors, out_tensors, primitive, context_, npu_desc);
|
||||
if (kernel != nullptr) {
|
||||
|
|
Loading…
Reference in New Issue