From 152b37753c5769581f56f4824106f6df600f44a6 Mon Sep 17 00:00:00 2001 From: Dheeraj Peri Date: Thu, 5 Aug 2021 02:27:42 -0700 Subject: [PATCH] chore: Rename var dtype to be explicit Signed-off-by: Dheeraj Peri --- core/lowering/passes/unpack_var.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/core/lowering/passes/unpack_var.cpp b/core/lowering/passes/unpack_var.cpp index 75fa84fa05..8a5c21cf0b 100644 --- a/core/lowering/passes/unpack_var.cpp +++ b/core/lowering/passes/unpack_var.cpp @@ -17,7 +17,7 @@ void UnpackVar(std::shared_ptr& graph) { %none: None = prim::Constant() %false: bool = prim::Constant[value=0]() %0: int = prim::Constant[value=0]() - %dtype: int = prim::Constant[value=6]() + %f32_dtype: int = prim::Constant[value=6]() %1: int = prim::Constant[value=1]() %sqrd: Tensor = aten::mul(%input, %input) %sqrdmean: Tensor = aten::mean(%sqrd, %dims, %keepdim, %none) @@ -27,7 +27,7 @@ void UnpackVar(std::shared_ptr& graph) { %varout : Tensor = prim::If(%unbiased) block0(): %shape: int[] = aten::size(%input) - %shapet: Tensor = aten::tensor(%shape, %dtype, %none, %false) + %shapet: Tensor = aten::tensor(%shape, %f32_dtype, %none, %false) %dim: int = prim::ListUnpack(%dims) %reduceddims: Tensor = aten::select(%shapet, %0, %dim) %numel: Tensor = aten::prod(%reduceddims, %dim, %keepdim, %none)