Home
last modified time | relevance | path

Searched refs:stride_w (Results 1 – 25 of 55) sorted by relevance

123

/third_party/mindspore/mindspore/lite/src/runtime/kernel/opencl/cl/
Dsparse_to_dense.cl21 … int4 outputshape, float default_value, int stride_w, int inshapeindex1_dim) {
31 index = (index_input_int.x) * stride_w;
33 index = (index_input_int.x) * stride_w + (index_input_int.y);
35 …index = (index_input_int.x) * stride_w + (index_input_int.y) * outputshape.w * C4NUM + (index_inpu…
37 index = (index_input_int.x) * outputshape.y * stride_w + (index_input_int.y) * stride_w +
44 … int2 inputshape, int4 outputshape, float default_value, int stride_w,
55 index = (index_input_int.x) * stride_w;
57 index = (index_input_int.x) * stride_w + index_input_int.y;
59 …index = (index_input_int.x) * stride_w + (index_input_int.y) * outputshape.w * C4NUM + index_input…
61 index = (index_input_int.x) * outputshape.y * stride_w + (index_input_int.y) * stride_w +
Dstack.cl105 int4 input_shape, int4 output_shape, int2 stride_w) {
114 int index_out = X * output_shape.y * stride_w.x + Y * stride_w.x;
115 int index_in = X * input_shape.y * stride_w.y + Y * Align_in;
/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
32 param->stride_w_ = stride_w; in CreateParameter()
51 int stride_w = 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()
97 int stride_w = 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()
144 int stride_w = 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()
188 int stride_w = 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 …ateParameter(PoolMode pool_mode, int window_h, int window_w, int stride_h, int stride_w, int pad_u, in CreateParameter() argument
36 param->stride_w_ = stride_w; 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
73 …<int64_t>(std::floor((in_w + pad_list[4] + pad_list[5] - kernel_w + stride_w - 1) / stride_w + 1)); in GetOutputShape()
80 if ((out_w - 1) * stride_w >= in_w + pad_list[4]) { in GetOutputShape()
86 …w = static_cast<int64_t>(std::floor((in_w + pad_list[4] + pad_list[5] - kernel_w) / stride_w + 1)); in GetOutputShape()
93 int64_t stride_d, int64_t stride_h, int64_t stride_w, const int64_t &pad_mode, in GetPadsByPadding() argument
100 MS_EXCEPTION_IF_ZERO("stride_w", stride_w); in GetPadsByPadding()
103 int64_t tail_w = in_w % stride_w; in GetPadsByPadding()
106 int64_t pad_w = std::max((tail_w > 0 ? kernel_w - tail_w : kernel_w - stride_w), (int64_t)0); in GetPadsByPadding()
142 auto stride_w = strides[2]; 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.cc105 auto stride_w = strides[3]; in InferShape() local
111 out_w = static_cast<int64_t>(ceil((in_w - (kernel_w - 1)) + static_cast<float>(stride_w) - 1) / in InferShape()
112 static_cast<float>(stride_w)); in InferShape()
115 out_w = static_cast<int64_t>(ceil(in_w / static_cast<float>(stride_w))); in InferShape()
Davg_pool.cc110 auto stride_w = strides[3]; in InferShape() local
115 out_w = static_cast<int64_t>(std::ceil((in_w - (kernel_w - 1)) / static_cast<float>(stride_w))); in InferShape()
118 out_w = static_cast<int64_t>(std::ceil(in_w / static_cast<float>(stride_w))); in InferShape()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/fp32_grad/
Dpack_ext.c27 const int stride_w = conv_param->stride_w_; in RollingIm2ColPackDwUnitFp32() local
48 int input_w = block_start % output_w * stride_w; in RollingIm2ColPackDwUnitFp32()
77 const int stride_w = conv_param->stride_w_; in rolling_im2col_hwc() local
99 int input_w = block_start % output_w * stride_w; in rolling_im2col_hwc()
119 int input_w = block_start % output_w * stride_w; in rolling_im2col_hwc()
148 const int stride_w = conv_param->stride_w_; in rolling_im2row_hwc() local
182 input_col += stride_w; in rolling_im2row_hwc()
196 const int stride_w = conv_param->stride_w_; in col2im_hwc() local
233 col_stride_offset += stride_w; in col2im_hwc()
244 const int stride_w = conv_param->stride_w_; in rolling_col2im_hwc() local
[all …]
Dpooling_grad.c22 int stride_w = pooling_param->stride_w_; in AvgPoolingGrad() local
47 int over_w = pad_w - yw * stride_w; in AvgPoolingGrad()
63 int xw = yw * stride_w + kw - pad_w; in AvgPoolingGrad()
84 int xw = yw * stride_w + kw - pad_w; in AvgPoolingGrad()
105 int stride_w = pooling_param->stride_w_; in MaxPoolingGrad() local
125 int over_w = pad_w - yw * stride_w; in MaxPoolingGrad()
143 int xw = yw * stride_w + kw - pad_w; in MaxPoolingGrad()
173 int xw = yw * stride_w + kw - pad_w; in MaxPoolingGrad()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/infer/
Ddeconv2d_infer.c58 int stride_w = param->stride_w_; in Deconv2dInferShape() local
60 MS_CHECK_FALSE(stride_w == 0, NNACL_ERR); in Deconv2dInferShape()
63 MS_CHECK_FALSE(INT_MUL_OVERFLOW(input_w, stride_w), NNACL_ERR); in Deconv2dInferShape()
73 …output_w = (input_w - 1) * stride_w + ((kernel_w - 1) * dilate_w + 1) - param->pad_l_ - param->pad… in Deconv2dInferShape()
76 output_w = input_w * stride_w; in Deconv2dInferShape()
79 output_w = (input_w - 1) * stride_w + kernel_w; in Deconv2dInferShape()
95 param->pad_l_ = ((input_w - 1) * stride_w + (kernel_w - 1) * dilate_w + 1 - output_w) / 2; in Deconv2dInferShape()
Dconv2d_infer.c22 int stride_w = param->stride_w_; in ConvInferShape() local
27 if (stride_w == 0 || stride_h == 0) { in ConvInferShape()
34 *output_w = ceil((float)(input_w) / (float)(stride_w)); in ConvInferShape()
37 int pad_w_all = ((*output_w - 1) * stride_w + (kernel_w - 1) * dilate_w + 1 - input_w); in ConvInferShape()
52 (float)(stride_w)); in ConvInferShape()
58 *output_w = ((input_w) + param->pad_l_ + param->pad_r_ - kernel_width) / stride_w + 1; in ConvInferShape()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/fp16_grad/
Dpack_fp16_ext.c26 const int stride_w = conv_param->stride_w_; in RollingIm2ColPackDwUnitFp16() local
47 int input_w = block_start % output_w * stride_w; in RollingIm2ColPackDwUnitFp16()
76 const int stride_w = conv_param->stride_w_; in RollingIm2ColPackUnitFp16() local
98 int input_w = block_start % output_w * stride_w; in RollingIm2ColPackUnitFp16()
118 int input_w = block_start % output_w * stride_w; in RollingIm2ColPackUnitFp16()
143 const int stride_w = conv_param->stride_w_; in RollingCol2ImPackUnitFp16() local
165 int col_stride_offset = output_col * stride_w; in RollingCol2ImPackUnitFp16()
184 int col_stride_offset = output_col * stride_w; in RollingCol2ImPackUnitFp16()
Dpooling_grad.c22 int stride_w = pooling_param->stride_w_; in AvgPoolingFp16Grad() local
47 int over_w = pad_w - yw * stride_w; in AvgPoolingFp16Grad()
63 int xw = yw * stride_w + kw - pad_w; in AvgPoolingFp16Grad()
84 int xw = yw * stride_w + kw - pad_w; in AvgPoolingFp16Grad()
107 int stride_w = pooling_param->stride_w_; in MaxPoolingFp16Grad() local
128 int over_w = pad_w - yw * stride_w; in MaxPoolingFp16Grad()
146 int xw = yw * stride_w + kw - pad_w; in MaxPoolingFp16Grad()
175 int xw = yw * stride_w + kw - pad_w; in MaxPoolingFp16Grad()
/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]
497 stride_w = self.stride[3]
502 w_out = math.ceil((x_shape[3] - dilation_w * (kernel_size_w - 1)) / stride_w)
506 w_out = math.ceil(x_shape[3] / stride_w)
510 … pad_needed_w = max(0, (w_out - 1) * stride_w + dilation_w * (kernel_size_w - 1) + 1 - x_shape[3])
516 …1 + (x_shape[3] + 2 * self.pad - kernel_size_w - (kernel_size_w - 1) * (dilation_w - 1)) / stride_w
577 stride_w = self.strides
582 w_out = math.ceil((x_shape[3] - dilation_w * (kernel_size_w - 1)) / stride_w)
586 w_out = math.ceil(x_shape[3] / stride_w)
[all …]
/third_party/mindspore/mindspore/lite/src/delegate/npu/op/
Davg_pooling_npu.cc28 auto stride_w = static_cast<int>(*(pooling_prim->strides()->begin() + 1)); in IsSupport() local
31 if (pad_u > stride_h || pad_l > stride_w) { in IsSupport()
48 auto stride_w = static_cast<int>(*(pooling_prim->strides()->begin() + 1)); in SetPoolingParam() local
49 pooling_->set_attr_stride(ge::AttrValue::LIST_INT({stride_h, stride_w})); in SetPoolingParam()
Dconvolution_npu.cc29 auto stride_w = static_cast<int>(*(conv_prim->stride()->begin() + 1)); in IsSupport() local
31 if (stride_h > in_shape[NHWC_H] || stride_w > in_shape[NHWC_W]) { in IsSupport()
41 auto stride_w = static_cast<int>(*(conv_prim->stride()->begin() + 1)); in SetConvParam() local
44 conv_->set_attr_strides(ge::AttrValue::LIST_INT({stride_h, stride_w})); in SetConvParam()
/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.h242 int stride_w = stride_[3]; in SetPad() local
247 stride_w = stride_[2]; in SetPad()
251 int strideA[2] = {stride_h, stride_w}; in SetPad()
254 pad_width_ = GetPad(old_width_, window_width, stride_w); in SetPad()
293 int stride_w = stride_[4]; in SetPad3D() local
300 stride_w = stride_[3]; in SetPad3D()
304 int strideA[3] = {stride_d, stride_h, stride_w}; in SetPad3D()
308 pad_width_ = GetPad(old_width_, window_width, stride_w); in SetPad3D()
/third_party/mindspore/tests/vm_impl/
Dvm_me.py159 stride_w = stride
162 stride_w = stride[1]
165 stride_w = stride[3]
188 out_w = (width + pad_left + pad_right - filter_w) // stride_w + 1
195 width + pad_left + pad_right + stride_w - 1)) \
246 stride_w = stride[1]
274 …w = 1 + int((x_w + pad_left + pad_right - filter_w - (filter_w - 1) * (dilation_w - 1)) / stride_w)
353 stride_w = stride
356 stride_w = stride[1]
359 stride_w = stride[3]
[all …]
/third_party/mindspore/mindspore/lite/tools/optimizer/parallel/
Dsplit_strategy.cc38 int64_t stride_w = strides.at(kIndexW); 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.cc79 auto stride_w = strides[3]; in InferShape() local
84 out_w = static_cast<int64_t>(ceil((in_w - (kernel_w - 1)) / static_cast<float>(stride_w))); in InferShape()
87 out_w = static_cast<int64_t>(ceil(in_w / static_cast<float>(stride_w))); in InferShape()
Dmax_pool_fusion.cc76 auto stride_w = strides[3]; in InferShape() local
81 out_w = static_cast<int64_t>(ceil((in_w - (kernel_w - 1)) / static_cast<float>(stride_w))); in InferShape()
84 out_w = static_cast<int64_t>(ceil(in_w / static_cast<float>(stride_w))); in InferShape()

123