提交 268a90fc 编写于 作者: L liutuo

fix DepthToSpace bug

上级 8f5a79b7
......@@ -10,3 +10,5 @@ mace/codegen/tuning/
mace/codegen/version/
build/
docs/_build/
\.project/
......@@ -29,6 +29,8 @@ void DepthToSpaceOpFunctor<DeviceType::OPENCL, T>::operator()(
output_height = input_height * block_size_;
output_width = input_width * block_size_;
output_depth = input_depth / (block_size_ * block_size_);
MACE_CHECK(output_depth % 4 == 0, "output channel not support:")
<< output_depth;
kernel_name = "depth_to_space";
gws[0] = static_cast<uint32_t>(RoundUpDiv4(output_depth));
......@@ -40,6 +42,8 @@ void DepthToSpaceOpFunctor<DeviceType::OPENCL, T>::operator()(
output_height = input_height / block_size_;
output_width = input_width / block_size_;
output_depth = input_depth * block_size_ * block_size_;
MACE_CHECK(input_depth % 4 == 0, "input channel not support:")
<< input_depth;
kernel_name = "space_to_depth";
gws[0] = static_cast<uint32_t>(RoundUpDiv4(input_depth));
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册