From dbb3232c31d6b34bafd22c30fa8cbaac2fc7164c Mon Sep 17 00:00:00 2001 From: Megvii Engine Team Date: Fri, 24 Sep 2021 19:09:15 +0800 Subject: [PATCH] fix(sdk): fix error caused by incorrect parsing u16/s16 inputs in lar GitOrigin-RevId: 9486cf362d25b898b44e023d9fd2a49d7873dd96 --- sdk/load-and-run/src/mgblar.cpp | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/sdk/load-and-run/src/mgblar.cpp b/sdk/load-and-run/src/mgblar.cpp index a7f71789..b3d901b7 100644 --- a/sdk/load-and-run/src/mgblar.cpp +++ b/sdk/load-and-run/src/mgblar.cpp @@ -423,10 +423,13 @@ private: } const std::map type_map = { - {"f4", dtype::Float32()}, + {"f4", dtype::Float32()}, {"i4", dtype::Int32()}, - {"i1", dtype::Int8()}, - {"u1", dtype::Uint8()}}; + {"u2", dtype::Uint16()}, + {"i2", dtype::Int16()}, + {"i1", dtype::Int8()}, + {"u1", dtype::Uint8()}, + }; megdnn::DType hv_type; for (auto& item : type_map) { -- GitLab