提交 93c3df7b 编写于 作者: Z zhaojiaying01

format code style

上级 eebe855a
...@@ -37,25 +37,25 @@ bool ConvKernel<GPU_CL, float>::Init(ConvParam<GPU_CL> *param) { ...@@ -37,25 +37,25 @@ bool ConvKernel<GPU_CL, float>::Init(ConvParam<GPU_CL> *param) {
DLOG << " filter dims: " << param->Filter()->dims(); DLOG << " filter dims: " << param->Filter()->dims();
if (param->Filter()->dims()[2] == 1 && param->Filter()->dims()[3] == 1) { if (param->Filter()->dims()[2] == 1 && param->Filter()->dims()[3] == 1) {
param->Filter()->InitNImage(cl_helper_.CLContext(), param->Filter()->InitNImage(cl_helper_.CLContext(),
cl_helper_.CLCommandQueue()); cl_helper_.CLCommandQueue());
this->cl_helper_.AddKernel("conv_1x1", "conv_kernel.cl"); this->cl_helper_.AddKernel("conv_1x1", "conv_kernel.cl");
DLOG << "conv 1x1"; DLOG << "conv 1x1";
} else if (param->Filter()->dims()[1] == 1 && } else if (param->Filter()->dims()[1] == 1 &&
param->Input()->dims()[1] == param->Output()->dims()[1] && param->Input()->dims()[1] == param->Output()->dims()[1] &&
param->Filter()->dims()[2] == 3) { param->Filter()->dims()[2] == 3) {
param->Filter()->InitDWImage(cl_helper_.CLContext(), param->Filter()->InitDWImage(cl_helper_.CLContext(),
cl_helper_.CLCommandQueue()); cl_helper_.CLCommandQueue());
this->cl_helper_.AddKernel("depth_conv_3x3", "depthwise_conv_kernel.cl"); this->cl_helper_.AddKernel("depth_conv_3x3", "depthwise_conv_kernel.cl");
DLOG << "depth_conv 3x3"; DLOG << "depth_conv 3x3";
} else if (param->Filter()->dims()[2] == 3 && } else if (param->Filter()->dims()[2] == 3 &&
param->Filter()->dims()[3] == 3) { param->Filter()->dims()[3] == 3) {
param->Filter()->InitCLImage(cl_helper_.CLContext(), param->Filter()->InitCLImage(cl_helper_.CLContext(),
cl_helper_.CLCommandQueue()); cl_helper_.CLCommandQueue());
this->cl_helper_.AddKernel("conv_3x3", "conv_kernel.cl"); this->cl_helper_.AddKernel("conv_3x3", "conv_kernel.cl");
DLOG << "conv 3x3"; DLOG << "conv 3x3";
} else { } else {
PADDLE_MOBILE_THROW_EXCEPTION(" not support "); PADDLE_MOBILE_THROW_EXCEPTION(" not support ");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册