From: 오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 Date: Thu, 25 Oct 2018 10:46:32 +0000 (+0900) Subject: [neurun] Fix Shape4D in LowerInfo order (#3339) X-Git-Tag: 0.3~520 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bd5beb96771f610f67a8f33eeb7b14346882ef50;p=platform%2Fcore%2Fml%2Fnnfw.git [neurun] Fix Shape4D in LowerInfo order (#3339) Fix Shape4D order bug (NHWC) Signed-off-by: Hyeongseok Oh --- diff --git a/runtimes/neurun/src/graph/operand/Shape4DConvert.h b/runtimes/neurun/src/graph/operand/Shape4DConvert.h index b840d19..2825740 100644 --- a/runtimes/neurun/src/graph/operand/Shape4DConvert.h +++ b/runtimes/neurun/src/graph/operand/Shape4DConvert.h @@ -34,16 +34,16 @@ inline LowerInfo::Shape4D asShape4D(const Shape &shape) return LowerInfo::Shape4D(1, 1, 1, 1); case 1u: - return LowerInfo::Shape4D(1, 1, 1, shape.dim(0)); + return LowerInfo::Shape4D(shape.dim(0), 1, 1, 1); case 2u: - return LowerInfo::Shape4D(1, 1, shape.dim(1), shape.dim(0)); + return LowerInfo::Shape4D(shape.dim(0), shape.dim(1), 1, 1); case 3u: - return LowerInfo::Shape4D(1, shape.dim(2), shape.dim(1), shape.dim(0)); + return LowerInfo::Shape4D(shape.dim(0), shape.dim(1), shape.dim(2), 1); case 4u: - return LowerInfo::Shape4D(shape.dim(3), shape.dim(2), shape.dim(1), shape.dim(0)); + return LowerInfo::Shape4D(shape.dim(0), shape.dim(1), shape.dim(2), shape.dim(3)); default: throw "Unsupported rank > 4";