46 unsigned int depth_multiplier)
50 unsigned int depth_multiplier);
53 &ClDWCNativeDefaultConfigValhall::configure_G78_f32, &ClDWCNativeDefaultConfigValhall::configure_G78_f16,
54 &ClDWCNativeDefaultConfigValhall::configure_G78_u8);
57 &ClDWCNativeDefaultConfigValhall::configure_G78_f32, &ClDWCNativeDefaultConfigValhall::configure_G77_f16,
58 &ClDWCNativeDefaultConfigValhall::configure_G78_u8);
60 ConfigurationFunctionExecutorPtr func =
nullptr;
73 return (this->*func)(
src, wei,
conv_info, dilation, depth_multiplier);
80 unsigned int depth_multiplier)
89 const size_t kernel_c = wei_shape[idx_c];
90 const size_t kernel_w = wei_shape[idx_w];
95 if (depth_multiplier == 1)
101 if ((depth_multiplier % 4) == 0)
105 else if ((depth_multiplier % 2) == 0)
122 if (
conv_info.stride().first == 1 && dilation.
x() == 1)
124 if ((kernel_w >= 9) || (kernel_w == 1))
142 DWCComputeKernelInfo ClDWCNativeDefaultConfigValhall::configure_G78_f16(
const ITensorInfo *
src,
143 const ITensorInfo *wei,
145 const Size2D &dilation,
146 unsigned int depth_multiplier)
148 DWCComputeKernelInfo desc;
155 const TensorShape src_shape =
src->tensor_shape();
156 const TensorShape wei_shape = wei->tensor_shape();
157 const size_t src_w = src_shape[idx_w];
158 const size_t kernel_c = wei_shape[idx_c];
159 const size_t kernel_w = wei_shape[idx_w];
161 desc.export_input_to_cl_image =
false;
164 if (depth_multiplier == 1)
166 if (desc.export_weights_to_cl_image ==
false)
177 if ((depth_multiplier % 4) == 0)
181 else if ((depth_multiplier % 2) == 0)
193 (desc.export_weights_to_cl_image ==
true));
198 if (
conv_info.stride().first == 1 && dilation.x() == 1)
200 if ((kernel_w >= 9) || (kernel_w == 1))
206 if ((src_w % 5) == 0)
225 DWCComputeKernelInfo ClDWCNativeDefaultConfigValhall::configure_G78_u8(
const ITensorInfo *
src,
226 const ITensorInfo *wei,
228 const Size2D &dilation,
229 unsigned int depth_multiplier)
233 DWCComputeKernelInfo desc;
237 desc.export_input_to_cl_image =
false;
238 desc.export_weights_to_cl_image =
false;
239 desc.n0 = (depth_multiplier == 1) ? 4 : 1;
240 if (
conv_info.stride().first == 1 && dilation.x() == 1 && depth_multiplier == 1)
253 DWCComputeKernelInfo ClDWCNativeDefaultConfigValhall::configure_G77_f16(
const ITensorInfo *
src,
254 const ITensorInfo *wei,
256 const Size2D &dilation,
257 unsigned int depth_multiplier)
259 DWCComputeKernelInfo desc;
265 const TensorShape wei_shape = wei->tensor_shape();
266 const size_t kernel_c = wei_shape[idx_c];
267 const size_t kernel_w = wei_shape[idx_w];
269 desc.export_input_to_cl_image =
false;
272 if (depth_multiplier == 1)
274 if (desc.export_weights_to_cl_image ==
false)
285 if ((depth_multiplier % 4) == 0)
289 else if ((depth_multiplier % 2) == 0)
301 (desc.export_weights_to_cl_image ==
true));
306 if (
conv_info.stride().first == 1 && dilation.x() == 1)
308 if ((kernel_w >= 9) || (kernel_w == 1))