From 62164fc1b7baf77370002ac4572dd9e99ec0f6cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=BC=A0=E5=8B=87=E8=B4=A4?= Date: Mon, 21 Nov 2022 00:30:40 +0800 Subject: [PATCH] Fix bug for grid sample GPU --- .../ccsrc/plugin/device/gpu/kernel/nn/grid_sampler_gpu_kernel.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mindspore/ccsrc/plugin/device/gpu/kernel/nn/grid_sampler_gpu_kernel.h b/mindspore/ccsrc/plugin/device/gpu/kernel/nn/grid_sampler_gpu_kernel.h index 54ec507624e..f0776b8ed42 100644 --- a/mindspore/ccsrc/plugin/device/gpu/kernel/nn/grid_sampler_gpu_kernel.h +++ b/mindspore/ccsrc/plugin/device/gpu/kernel/nn/grid_sampler_gpu_kernel.h @@ -113,7 +113,7 @@ class GridSampler2DGpuKernelMod : public NativeGpuKernelMod { stride_compute(input_stride_, input_shape_); stride_compute(grid_stride_, grid_shape_); stride_compute(output_stride_, output_shape_); - size_ = input_shape_[kIndex0] * grid_shape_[kIndex1] * grid_shape_[kIndex2] * grid_shape_[kIndex3]; + size_ = input_shape_[kIndex0] * grid_shape_[kIndex1] * grid_shape_[kIndex2]; return KRET_OK; }