Home
last modified time | relevance | path

Searched refs:stride_h (Results 1 – 25 of 47) sorted by relevance

12

/third_party/mindspore/mindspore/lite/test/ut/src/runtime/kernel/opencl/
Ddepthwise_conv2d_tests.cc26 OpParameter *CreateParameter(int kernel_h, int kernel_w, int stride_h, int stride_w, int pad_u, int… in CreateParameter() argument
31 param->stride_h_ = stride_h; in CreateParameter()
50 int stride_h = 1; in TEST_F() local
84 …auto *param = CreateParameter(kernel_h, kernel_w, stride_h, stride_w, pad_u, pad_d, pad_l, pad_r, … in TEST_F()
96 int stride_h = 1; in TEST_F() local
131 …auto *param = CreateParameter(kernel_h, kernel_w, stride_h, stride_w, pad_u, pad_d, pad_l, pad_r, … in TEST_F()
143 int stride_h = 1; in TEST_F() local
176 …auto *param = CreateParameter(kernel_h, kernel_w, stride_h, stride_w, pad_u, pad_d, pad_l, pad_r, … in TEST_F()
187 int stride_h = 1; in TEST_F() local
245 …auto *param = CreateParameter(kernel_h, kernel_w, stride_h, stride_w, pad_u, pad_d, pad_l, pad_r, … in TEST_F()
Dpooling_tests.cc25 OpParameter *CreateParameter(PoolMode pool_mode, int window_h, int window_w, int stride_h, int stri… in CreateParameter() argument
37 param->stride_h_ = stride_h; in CreateParameter()
/third_party/mindspore/mindspore/ops/_op_impl/_custom_op/
Dimg2col_impl.py39 stride_w, stride_h, filter_w, filter_h, dilation_filter_w, dilation_filter_h = shape_info
56 … left_top_h, stride_w, stride_h, filter_w, filter_h, dilation_filter_w,
66 stride_w, stride_h, filter_w, filter_h, dilation_filter_w, dilation_filter_h = shape_info
83 … left_top_h, stride_w, stride_h, filter_w, filter_h, dilation_filter_w,
94 stride_w, stride_h, filter_w, filter_h, dilation_filter_w, dilation_filter_h = shape_info
107 left_top_w, left_top_h, stride_w, stride_h,
118 stride_w, stride_h, filter_w, filter_h, dilation_filter_w, dilation_filter_h = shape_info
134 left_top_w, left_top_h, stride_w, stride_h, filter_w,
146 stride_w, stride_h, filter_w, filter_h, dilation_filter_w, dilation_filter_h = shape_info
162 stride_w, stride_h, filter_w, filter_h,
[all …]
/third_party/mindspore/mindspore/core/ops/
Davg_pool_3d.cc59 … int64_t kernel_w, int64_t stride_d, int64_t stride_h, int64_t stride_w, in GetOutputShape() argument
71 …<int64_t>(std::floor((in_h + pad_list[2] + pad_list[3] - kernel_h + stride_h - 1) / stride_h + 1)); in GetOutputShape()
77 if ((out_h - 1) * stride_h >= in_h + pad_list[2]) { in GetOutputShape()
85 …h = static_cast<int64_t>(std::floor((in_h + pad_list[2] + pad_list[3] - kernel_h) / stride_h + 1)); in GetOutputShape()
93 int64_t stride_d, int64_t stride_h, int64_t stride_w, const int64_t &pad_mode, in GetPadsByPadding() argument
99 MS_EXCEPTION_IF_ZERO("stride_h", stride_h); in GetPadsByPadding()
102 int64_t tail_h = in_h % stride_h; in GetPadsByPadding()
105 int64_t pad_h = std::max((tail_h > 0 ? kernel_h - tail_h : kernel_h - stride_h), (int64_t)0); in GetPadsByPadding()
141 auto stride_h = strides[1]; in InferShape() local
144 …GetPadsByPadding(in_d, in_h, in_w, kernel_d, kernel_h, kernel_w, stride_d, stride_h, stride_w, pad… in InferShape()
[all …]
Dmax_pool.cc104 auto stride_h = strides[2]; in InferShape() local
109 out_h = static_cast<int64_t>(ceil((in_h - (kernel_h - 1)) + static_cast<float>(stride_h) - 1) / in InferShape()
110 static_cast<float>(stride_h)); in InferShape()
114 out_h = static_cast<int64_t>(ceil(in_h / static_cast<float>(stride_h))); in InferShape()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/fp32_grad/
Dpack_ext.c26 const int stride_h = conv_param->stride_h_; in RollingIm2ColPackDwUnitFp32() local
47 int input_h = block_start / output_w * stride_h; in RollingIm2ColPackDwUnitFp32()
76 const int stride_h = conv_param->stride_h_; in rolling_im2col_hwc() local
98 int input_h = block_start / output_w * stride_h; in rolling_im2col_hwc()
118 int input_h = block_start / output_w * stride_h; in rolling_im2col_hwc()
147 const int stride_h = conv_param->stride_h_; in rolling_im2row_hwc() local
168 int input_row = -pad_up + kernel_row * dilation_h + output_rows * stride_h; in rolling_im2row_hwc()
195 const int stride_h = conv_param->stride_h_; in col2im_hwc() local
235 row_stride_offset += stride_h; in col2im_hwc()
243 const int stride_h = conv_param->stride_h_; in rolling_col2im_hwc() local
[all …]
Dpooling_grad.c23 int stride_h = pooling_param->stride_h_; in AvgPoolingGrad() local
43 int over_h = pad_h - yh * stride_h; in AvgPoolingGrad()
61 int xh = yh * stride_h + kh - pad_h; in AvgPoolingGrad()
82 int xh = yh * stride_h + kh - pad_h; in AvgPoolingGrad()
106 int stride_h = pooling_param->stride_h_; in MaxPoolingGrad() local
121 int over_h = pad_h - yh * stride_h; in MaxPoolingGrad()
141 int xh = yh * stride_h + kh - pad_h; in MaxPoolingGrad()
171 int xh = yh * stride_h + kh - pad_h; in MaxPoolingGrad()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/infer/
Ddeconv2d_infer.c59 int stride_h = param->stride_h_; in Deconv2dInferShape() local
61 MS_CHECK_FALSE(stride_h == 0, NNACL_ERR); in Deconv2dInferShape()
62 MS_CHECK_FALSE(INT_MUL_OVERFLOW(input_h, stride_h), NNACL_ERR); in Deconv2dInferShape()
72 …output_h = (input_h - 1) * stride_h + ((kernel_h - 1) * dilate_h + 1) - param->pad_u_ - param->pad… in Deconv2dInferShape()
75 output_h = input_h * stride_h; in Deconv2dInferShape()
78 output_h = (input_h - 1) * stride_h + kernel_h; in Deconv2dInferShape()
94 param->pad_u_ = ((input_h - 1) * stride_h + (kernel_h - 1) * dilate_h + 1 - output_h) / 2; in Deconv2dInferShape()
Dconv2d_infer.c23 int stride_h = param->stride_h_; in ConvInferShape() local
27 if (stride_w == 0 || stride_h == 0) { in ConvInferShape()
35 *output_h = ceil((float)(input_h) / (float)(stride_h)); in ConvInferShape()
36 int pad_h_all = ((*output_h - 1) * stride_h + (kernel_h - 1) * dilate_h + 1 - input_h); in ConvInferShape()
54 (float)(stride_h)); in ConvInferShape()
59 *output_h = ((input_h) + param->pad_u_ + param->pad_d_ - kernel_height) / stride_h + 1; in ConvInferShape()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/fp16_grad/
Dpack_fp16_ext.c25 const int stride_h = conv_param->stride_h_; in RollingIm2ColPackDwUnitFp16() local
46 int input_h = block_start / output_w * stride_h; in RollingIm2ColPackDwUnitFp16()
75 const int stride_h = conv_param->stride_h_; in RollingIm2ColPackUnitFp16() local
97 int input_h = block_start / output_w * stride_h; in RollingIm2ColPackUnitFp16()
117 int input_h = block_start / output_w * stride_h; in RollingIm2ColPackUnitFp16()
142 const int stride_h = conv_param->stride_h_; in RollingCol2ImPackUnitFp16() local
164 int row_stride_offset = output_row * stride_h; in RollingCol2ImPackUnitFp16()
183 int row_stride_offset = output_row * stride_h; in RollingCol2ImPackUnitFp16()
Dpooling_grad.c23 int stride_h = pooling_param->stride_h_; in AvgPoolingFp16Grad() local
43 int over_h = pad_h - yh * stride_h; in AvgPoolingFp16Grad()
61 int xh = yh * stride_h + kh - pad_h; in AvgPoolingFp16Grad()
82 int xh = yh * stride_h + kh - pad_h; in AvgPoolingFp16Grad()
108 int stride_h = pooling_param->stride_h_; in MaxPoolingFp16Grad() local
124 int over_h = pad_h - yh * stride_h; in MaxPoolingFp16Grad()
144 int xh = yh * stride_h + kh - pad_h; in MaxPoolingFp16Grad()
173 int xh = yh * stride_h + kh - pad_h; in MaxPoolingFp16Grad()
/third_party/mindspore/tests/vm_impl/
Dvm_me.py158 stride_h = stride
161 stride_h = stride[0]
164 stride_h = stride[2]
187 out_h = (height + pad_top + pad_bottom - filter_h) // stride_h + 1
194 height + pad_top + pad_bottom + stride_h - 1,
198 y_max = y + stride_h * out_h
200 x_max = x + stride_h * out_w
201 img[:, :, y:y_max:stride_h, x:x_max:stride_h] += col[:, :, y, x, :, :]
245 stride_h = stride[0]
273 …h = 1 + int((x_h + pad_top + pad_bottom - filter_h - (filter_h - 1) * (dilation_h - 1)) / stride_h)
[all …]
/third_party/mindspore/mindspore/ops/operations/
D_thor_ops.py176 _, stride_h, stride_w, _ = self.strides
182 shape = [bs * int(h // stride_h) * int(w // stride_w), k_w * k_h * c1 * c0]
496 stride_h = self.stride[2]
501 h_out = math.ceil((x_shape[2] - dilation_h * (kernel_size_h - 1)) / stride_h)
505 h_out = math.ceil(x_shape[2] / stride_h)
507 … pad_needed_h = max(0, (h_out - 1) * stride_h + dilation_h * (kernel_size_h - 1) + 1 - x_shape[2])
515 …1 + (x_shape[2] + 2 * self.pad - kernel_size_h - (kernel_size_h - 1) * (dilation_h - 1)) / stride_h
576 stride_h = self.strides
581 h_out = math.ceil((x_shape[2] - dilation_h * (kernel_size_h - 1)) / stride_h)
585 h_out = math.ceil(x_shape[2] / stride_h)
[all …]
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/base/
Dbatch_to_space_base.c26 int stride_h = block_w * out_n; in BatchToSpaceNoCropForNHWC() local
38 int in_offset = in_stride_n * (bh * stride_h + bw * out_n + n) + w_offset + h_offset; in BatchToSpaceNoCropForNHWC()
67 int stride_h = block_w * out_n; in BatchToSpaceForNHWC() local
87 int in_offset = in_stride_n * (bh * stride_h + bw * out_n + n) + w_offset + h_offset; in BatchToSpaceForNHWC()
/third_party/mindspore/mindspore/lite/src/delegate/npu/op/
Davg_pooling_npu.cc27 auto stride_h = static_cast<int>(*(pooling_prim->strides()->begin())); in IsSupport() local
31 if (pad_u > stride_h || pad_l > stride_w) { in IsSupport()
47 auto stride_h = static_cast<int>(*(pooling_prim->strides()->begin())); in SetPoolingParam() local
49 pooling_->set_attr_stride(ge::AttrValue::LIST_INT({stride_h, stride_w})); in SetPoolingParam()
Dconvolution_npu.cc28 auto stride_h = static_cast<int>(*(conv_prim->stride()->begin())); in IsSupport() local
31 if (stride_h > in_shape[NHWC_H] || stride_w > in_shape[NHWC_W]) { in IsSupport()
40 auto stride_h = static_cast<int>(*(conv_prim->stride()->begin())); in SetConvParam() local
44 conv_->set_attr_strides(ge::AttrValue::LIST_INT({stride_h, stride_w})); in SetConvParam()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/int8/
Dbatch_to_space_int8.c26 size_t stride_h = block_w * out_n; in BatchToSpaceNoCropForNHWCInt8() local
42 size_t in_offset = in_stride_n * (bh * stride_h + bw * out_n + n) + w_offset + h_offset; in BatchToSpaceNoCropForNHWCInt8()
72 size_t stride_h = block_w * out_n; in BatchToSpaceForNHWCInt8() local
97 size_t in_offset = in_stride_n * (bh * stride_h + bw * out_n + n) + w_offset + h_offset; in BatchToSpaceForNHWCInt8()
/third_party/mindspore/mindspore/lite/tools/converter/parser/tflite/
Dtflite_pooling_parser.cc47 prim->set_strides({tflite_attr->stride_h, tflite_attr->stride_w}); in Parse()
55 int status = getPaddingParam(dataTensor, padMode, tflite_attr->stride_h, tflite_attr->stride_w, in Parse()
87 prim->set_strides({tflite_attr->stride_h, tflite_attr->stride_w}); in Parse()
95 int status = getPaddingParam(dataTensor, padMode, tflite_attr->stride_h, tflite_attr->stride_w, in Parse()
Dtflite_conv_parser.cc49 prim->set_stride({tflite_attr->stride_h, tflite_attr->stride_w}); in Parse()
77 int status = getPaddingParam(dataTensor, padMode, tflite_attr->stride_h, tflite_attr->stride_w, in Parse()
106 prim->set_stride({tflite_attr->stride_h, tflite_attr->stride_w}); in Parse()
154 int status = getPaddingParam(data_tensor, padMode, tflite_attr->stride_h, tflite_attr->stride_w, in Parse()
Dtflite_conv_transpose_parser.cc46 prim->set_stride({tflite_attr->stride_h, tflite_attr->stride_w}); in Parse()
72 int status = getPaddingParam(data_tensor, padMode, tflite_attr->stride_h, tflite_attr->stride_w, in Parse()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/gpu/nn/
Dpooling_grad_gpu_kernel.h241 int stride_h = stride_[2]; in SetPad() local
246 stride_h = stride_[1]; in SetPad()
251 int strideA[2] = {stride_h, stride_w}; in SetPad()
253 pad_height_ = GetPad(old_height_, window_height, stride_h); in SetPad()
292 int stride_h = stride_[3]; in SetPad3D() local
299 stride_h = stride_[2]; in SetPad3D()
304 int strideA[3] = {stride_d, stride_h, stride_w}; in SetPad3D()
307 pad_height_ = GetPad(old_height_, window_height, stride_h); in SetPad3D()
/third_party/mindspore/mindspore/lite/tools/optimizer/parallel/
Dsplit_strategy.cc37 int64_t stride_h = strides.at(kIndexH); in ApproximateFLOPs() local
39 if (stride_h == 0 || stride_w == 0) { in ApproximateFLOPs()
43 return (input_h / stride_h) * (input_w / stride_w) * in_c * k_h * k_w * out_c / kPerFlops; in ApproximateFLOPs()
/third_party/mindspore/mindspore/core/ops/fusion/
Davg_pool_fusion.cc78 auto stride_h = strides[2]; in InferShape() local
83 out_h = static_cast<int64_t>(ceil((in_h - (kernel_h - 1)) / static_cast<float>(stride_h))); in InferShape()
86 out_h = static_cast<int64_t>(ceil(in_h / static_cast<float>(stride_h))); in InferShape()
Dmax_pool_fusion.cc75 auto stride_h = strides[2]; in InferShape() local
80 out_h = static_cast<int64_t>(ceil((in_h - (kernel_h - 1)) / static_cast<float>(stride_h))); in InferShape()
83 out_h = static_cast<int64_t>(ceil(in_h / static_cast<float>(stride_h))); in InferShape()
/third_party/mindspore/mindspore/lite/tools/optimizer/fisson/
Dfisson_util.cc141 auto stride_h = ori_conv_prim->get_stride()[kIndexH]; in CalSplitInShape() local
143 if (INT_MUL_OVERFLOW_THRESHOLD(stride_h, split_axis_dim, INT64_MAX)) { in CalSplitInShape()
150stride_h * split_axis_dim - ori_conv_prim->get_pad_list()[kPadUp] + ori_conv_prim->get_kernel_size… in CalSplitInShape()
152 tmp = stride_h * split_axis_dim - ori_conv_prim->get_pad_list()[kPadDown] + in CalSplitInShape()
155 tmp = stride_h * split_axis_dim - 0 + ori_conv_prim->get_kernel_size()[kIndexH]; in CalSplitInShape()
164 tmp = stride_h * split_axis_reduce_dim - ori_conv_prim->get_pad_list()[kPadDown] - in CalSplitInShape()
167 tmp = stride_h * split_axis_reduce_dim - ori_conv_prim->get_pad_list()[kPadUp] + in CalSplitInShape()

12