Home
last modified time | relevance | path

Searched refs:unit_size (Results 1 – 25 of 31) sorted by relevance

12

/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/gpu/cuda_impl/
Dscatter_nd_functor_impl.cu21 __global__ void ScatterNdUpdate(const size_t unit_size, const size_t index_depth, const size_t upda… in ScatterNdUpdate() argument
29 i = read_index / unit_size; in ScatterNdUpdate()
30 j = read_index % unit_size; in ScatterNdUpdate()
35 write_index += indices_i * out_strides[k] * unit_size; in ScatterNdUpdate()
47 __global__ void ScatterNdAdd(const size_t unit_size, const size_t index_depth, const size_t updates… in ScatterNdAdd() argument
55 i = read_index / unit_size; in ScatterNdAdd()
56 j = read_index % unit_size; in ScatterNdAdd()
61 write_index += indices_i * out_strides[k] * unit_size; in ScatterNdAdd()
73 __global__ void ScatterNdSub(const size_t unit_size, const size_t index_depth, const size_t updates… in ScatterNdSub() argument
81 i = read_index / unit_size; in ScatterNdSub()
[all …]
Dscatter_nd_functor_impl.cuh30 void CalScatterNdFunctor(enum ScatterNdFunctorType func_type, const size_t &unit_size, const size_t…
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/fp32/
Dprior_box_fp32.h29 size_t unit_size = size / thread_num; in PriorBox() local
30 size_t copy_size = (tid == thread_num - 1) ? size - unit_size * tid : unit_size; in PriorBox()
31 …(void)memcpy(output_data + tid * unit_size, input_data + tid * unit_size, copy_size * sizeof(float… in PriorBox()
Dscatter_nd_fp32.c21 int DoScatterND(float *output_ptr, const float *update, int *output_unit_offsets, int unit_size, in… in DoScatterND() argument
22 …if (output_ptr == NULL || update == NULL || output_unit_offsets == NULL || unit_size <= 0 || num_u… in DoScatterND()
26 …(void)memcpy(output_ptr + output_unit_offsets[i], update + unit_size * i, (size_t)(unit_size) * si… in DoScatterND()
Ddeconv_winograd_fp32.c444 … const float *bt_buf, float *b_tmp_buf, int unit_size, int w_start, int h_start, in DeConvWgCalWgFp32() argument
446 int winograd_plane = unit_size * unit_size; in DeConvWgCalWgFp32()
447 if (!transferred[unit_size]) { in DeConvWgCalWgFp32()
448 …WinogradTransLeft(tile_in, at_buf, a_mid_buf, DECONV_WINOGRAD_DEFAULT_UNIT, unit_size, DECONV_WINO… in DeConvWgCalWgFp32()
450 …WinogradTransRight(a_mid_buf, at_buf, trans_a_buf, unit_size, unit_size, DECONV_WINOGRAD_DEFAULT_U… in DeConvWgCalWgFp32()
452 transferred[unit_size] = true; in DeConvWgCalWgFp32()
463 WinogradTransLeft(tmp_buf, bt_buf, b_tmp_buf, unit_size, unit_size, unit_size, in DeConvWgCalWgFp32()
465 WinogradTransRight(b_tmp_buf, bt_buf, tmp_buf, unit_size, unit_size, unit_size, in DeConvWgCalWgFp32()
469 for (int uhi = 0; uhi < unit_size; uhi++) { in DeConvWgCalWgFp32()
471 for (int uwi = 0; uwi < unit_size; uwi++) { in DeConvWgCalWgFp32()
[all …]
Dscatter_nd_fp32.h25 int DoScatterND(float *output_ptr, const float *update, int *output_unit_offsets, int unit_size, in…
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/int8/
Dconv_int8.c29 int unit_size; in ConvInt8() local
34 unit_size = UP_ROUND(kernel_plane * in_channel, C16NUM); in ConvInt8()
38 unit_size = UP_ROUND(kernel_plane * in_channel, C4NUM); in ConvInt8()
41 unit_size = UP_ROUND(kernel_plane * in_channel, C16NUM); in ConvInt8()
60 int8_t *gemm_input = packed_input + task_id * unit_size * tile_n; in ConvInt8()
70 …gemm_input, packed_weight, gemm_output, real_cal_num, out_channel, unit_size, tmp_input_sum, bias_… in ConvInt8()
76 …matmul_func(gemm_input, packed_weight, gemm_output, real_cal_num, out_channel, unit_size, out_chan… in ConvInt8()
83 UP_ROUND(out_channel, C4NUM), unit_size, tmp_input_sum, bias_data, in ConvInt8()
91 …gemm_input, packed_weight, gemm_output, real_cal_num, out_channel, unit_size, out_channel, tmp_inp… in ConvInt8()
Dslice_int8.c38 int unit_size = param->size_[7] * sizeof(int8_t); in SliceInt8() local
73 memcpy(output + out_offset, input + in_offset, unit_size); in SliceInt8()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/cpu/nnacl/fp16/
Ddeconv_winograd_fp16.c177 … const float16_t *bt_buf, float16_t *b_tmp_buf, int unit_size, int w_start, int h_start, in DeConvWgCalWgFp16() argument
179 int winograd_plane = unit_size * unit_size; in DeConvWgCalWgFp16()
180 if (!transferred[unit_size]) { in DeConvWgCalWgFp16()
181 WinogradTransLeftFp16(tile_in, at_buf, a_mid_buf, DECONV_WINOGRAD_DEFAULT_UNIT, unit_size, in DeConvWgCalWgFp16()
183 …WinogradTransRightFp16(a_mid_buf, at_buf, trans_a_buf, unit_size, unit_size, DECONV_WINOGRAD_DEFAU… in DeConvWgCalWgFp16()
185 transferred[unit_size] = true; in DeConvWgCalWgFp16()
196 WinogradTransLeftFp16(tmp_buf, bt_buf, b_tmp_buf, unit_size, unit_size, unit_size, in DeConvWgCalWgFp16()
198 WinogradTransRightFp16(b_tmp_buf, bt_buf, tmp_buf, unit_size, unit_size, unit_size, in DeConvWgCalWgFp16()
202 for (int uhi = 0; uhi < unit_size; uhi++) { in DeConvWgCalWgFp16()
204 for (int uwi = 0; uwi < unit_size; uwi++) { in DeConvWgCalWgFp16()
[all …]
/third_party/ffmpeg/libavformat/
Drtpenc_vc2hq.c107 uint32_t unit_size; in ff_rtp_send_vc2hq() local
111 unit_size = AV_RB32(&unit[5]); in ff_rtp_send_vc2hq()
118 …send_packet(ctx, parse_code, 0, unit + DIRAC_DATA_UNIT_HEADER_SIZE, unit_size - DIRAC_DATA_UNIT_HE… in ff_rtp_send_vc2hq()
122 …send_picture(ctx, unit + DIRAC_DATA_UNIT_HEADER_SIZE, unit_size - DIRAC_DATA_UNIT_HEADER_SIZE, int… in ff_rtp_send_vc2hq()
132 unit += unit_size; in ff_rtp_send_vc2hq()
/third_party/mindspore/mindspore/lite/test/ut/src/runtime/kernel/arm/common/
Dpack_tests.cc80 int unit_size = kernel_plane * channel_block * inchannel_block; in TEST_F() local
81 int packed_input_size = output_tile_count * tile_n * unit_size; in TEST_F()
93 … reinterpret_cast<float *>(packed_input) + thread_id * unit_size * tile_n + gemm_in_batch_offset; in TEST_F()
143 int unit_size = kernel_plane * channel_block * inchannel_block; in TEST_F() local
144 int packed_input_size = output_tile_count * tile_n * unit_size; in TEST_F()
156 …reinterpret_cast<float16_t *>(packed_input) + thread_id * unit_size * tile_n + gemm_in_batch_offse… in TEST_F()
/third_party/mindspore/mindspore/lite/src/delegate/npu/pass/
Dnpu_pass_utils.cc226 void NPUPassUtils::AssistDataNHWC2NCHW(int *data, size_t unit_size) { in AssistDataNHWC2NCHW() argument
228 for (size_t i = 0; i < unit_size; ++i) { in AssistDataNHWC2NCHW()
229 int c = data[3 * unit_size + i]; in AssistDataNHWC2NCHW()
232 data[3 * unit_size + i] = data[2 * unit_size + i]; in AssistDataNHWC2NCHW()
233 data[2 * unit_size + i] = data[unit_size + i]; in AssistDataNHWC2NCHW()
234 data[unit_size + i] = c; in AssistDataNHWC2NCHW()
Dnpu_pass_utils.h57 static void AssistDataNHWC2NCHW(int *data, size_t unit_size);
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/gpu/math/
Dupdate_thor_gradient.h157 size_t unit_size = sizeof(T); in InitSizeLists() local
158 size_t input_size_ = gradient_size.h * gradient_size.h * gradient_size.batch_h * unit_size; in InitSizeLists()
161 input_size_ = gradient_size.ori_h * gradient_size.ori_w * unit_size; in InitSizeLists()
164 input_size_ = gradient_size.w * gradient_size.w * gradient_size.batch_w * unit_size; in InitSizeLists()
167 size_t output_size = gradient_size.ori_h * gradient_size.ori_w * unit_size; in InitSizeLists()
171 gradient_size.w * gradient_size.h * gradient_size.batch_w * gradient_size.batch_h * unit_size; in InitSizeLists()
175 …e_ = gradient_size.w * gradient_size.h * gradient_size.batch_w * gradient_size.batch_h * unit_size; in InitSizeLists()
177 …e_ = gradient_size.w * gradient_size.h * gradient_size.batch_w * gradient_size.batch_h * unit_size; in InitSizeLists()
183 …adient_size.ori_w + gradient_size.pad_w) * (gradient_size.ori_h + gradient_size.pad_h) * unit_size; in InitSizeLists()
Dcholesky_trsm_solve_gpu_kernel.h99 size_t unit_size = sizeof(T); in InitSizeLists() local
100 size_t input_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
102 size_t output_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
111 size_t unit_size = sizeof(T); in InitSizeLists() local
112 size_t input_size = height_ * width_ * unit_size; in InitSizeLists()
114 size_t output_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
122 workspace_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
Dcholesky_solve_gpu_kernel.h237 size_t unit_size = sizeof(T); in InitSizeLists() local
241 input_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
243 input_size = height_ * width_ * unit_size; in InitSizeLists()
244 workspace_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
248 size_t output_size = batch_ * m_ * lda_ * unit_size; in InitSizeLists()
Dmatmul_gpu_kernel.h174 size_t unit_size = sizeof(T); in InitSizeLists() local
176 size_t input_size = batch_ * m_ * k_ * unit_size; in InitSizeLists()
179 input_size = batch_ * n_ * k_ * unit_size; in InitSizeLists()
182 size_t output_size = batch_ * m_ * n_ * unit_size; in InitSizeLists()
Dbroadcast_gpu_kernel.h151 auto unit_size = is_comp_op_ ? sizeof(bool) : sizeof(T); in InitSizeLists() local
152 output_size_list_.push_back(output_num_ * unit_size); in InitSizeLists()
/third_party/ffmpeg/libavcodec/
Dh264_mp4toannexb_bsf.c69 uint16_t unit_size; in h264_extradata_to_annexb() local
92 unit_size = bytestream2_get_be16u(gb); in h264_extradata_to_annexb()
93 total_size += unit_size + 4; in h264_extradata_to_annexb()
95 if (bytestream2_get_bytes_left(gb) < unit_size + !sps_done) { in h264_extradata_to_annexb()
103 memcpy(out + total_size - unit_size - 4, nalu_header, 4); in h264_extradata_to_annexb()
104 bytestream2_get_bufferu(gb, out + total_size - unit_size, unit_size); in h264_extradata_to_annexb()
Dcbs_mpeg2.c150 size_t unit_size; in cbs_mpeg2_split_fragment() local
181 unit_size = (end - 4) - start; in cbs_mpeg2_split_fragment()
184 unit_size = end - start; in cbs_mpeg2_split_fragment()
189 unit_size, frag->data_ref); in cbs_mpeg2_split_fragment()
/third_party/mindspore/mindspore/ccsrc/backend/kernel_compiler/gpu/trt/
Dtrt_kernel.cc34 size_t unit_size = UnitSizeInBytes(type_id); in Init() local
35 …auto size_in_byte = std::accumulate(input_shape.begin(), input_shape.end(), unit_size, std::multip… in Init()
43 size_t unit_size = UnitSizeInBytes(type_id); in Init() local
44 …auto size_in_byte = std::accumulate(output_shape.begin(), output_shape.end(), unit_size, std::mult… in Init()
/third_party/mindspore/mindspore/lite/src/runtime/kernel/arm/fp32/
Dconvolution_fp32.cc42 …int unit_size = conv_param_->kernel_h_ * conv_param_->kernel_w_ * conv_param_->input_channel_ * C6… in InitTmpBuffer() local
44 …int unit_size = conv_param_->kernel_h_ * conv_param_->kernel_w_ * conv_param_->input_channel_ * C4… in InitTmpBuffer() local
46 int unit_size = in InitTmpBuffer() local
49 packed_input_ = reinterpret_cast<float *>(ctx_->allocator->Malloc(unit_size * sizeof(float))); in InitTmpBuffer()
55 col_major_input_ = reinterpret_cast<float *>(ctx_->allocator->Malloc(unit_size * sizeof(float))); in InitTmpBuffer()
/third_party/mindspore/mindspore/lite/src/runtime/kernel/arm/fp16/
Dconvolution_fp16.cc78 int unit_size = in InitTmpBuffer() local
81 …packed_input_ = reinterpret_cast<float16_t *>(ctx_->allocator->Malloc(unit_size * sizeof(float16_t… in InitTmpBuffer()
87 …col_major_input_ = reinterpret_cast<float16_t *>(ctx_->allocator->Malloc(unit_size * sizeof(float1… in InitTmpBuffer()
/third_party/iowow/src/utils/
Diwarr.h84 IW_EXPORT iwrc iwulist_init(IWULIST *list, size_t initial_length, size_t unit_size);
93 IW_EXPORT IWULIST *iwulist_create(size_t initial_length, size_t unit_size);\
Diwarr.c180 iwrc iwulist_init(IWULIST *list, size_t initial_length, size_t unit_size) { in iwulist_init() argument
181 list->usize = unit_size; in iwulist_init()
188 list->array = malloc(unit_size * initial_length); in iwulist_init()
195 IWULIST *iwulist_create(size_t initial_length, size_t unit_size) { in iwulist_create() argument
200 if (iwulist_init(list, initial_length, unit_size)) { in iwulist_create()

12