MCPcopy Create free account
hub / github.com/DeepRec-AI/DeepRec / GetGridSize

Method GetGridSize

tensorflow/lite/delegates/gpu/cl/kernels/conv_buffer_1x1.cc:278–292  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

276}
277
278int3 ConvBuffer1x1::GetGridSize() const {
279 if (src_[0]->Width() % 2 == 0) { // using kernel_flt8_
280 const int grid_x =
281 IntegralDivideRoundUp(GetGridWidth(dst_[0]->Width()), flt8_x_count_);
282 const int grid_y = IntegralDivideRoundUp(dst_[0]->Height(), flt8_y_count_);
283 const int grid_z = dst_[0]->Depth();
284 return int3(grid_x, grid_y, grid_z);
285 } else { // using kernel_flt4_
286 const int grid_x =
287 IntegralDivideRoundUp(GetGridWidth(dst_[0]->Width()), flt4_x_count_);
288 const int grid_y = IntegralDivideRoundUp(dst_[0]->Height(), flt4_y_count_);
289 const int grid_z = dst_[0]->Depth();
290 return int3(grid_x, grid_y, grid_z);
291 }
292}
293
294Status ConvBuffer1x1::Tune(const TuningParameters& params) {
295 RETURN_IF_ERROR(BindArguments());

Callers

nothing calls this directly

Calls 5

GetGridWidthFunction · 0.85
WidthMethod · 0.80
HeightMethod · 0.80
DepthMethod · 0.80
IntegralDivideRoundUpFunction · 0.50

Tested by

no test coverage detected