| 150 | } |
| 151 | |
| 152 | void GaussianBlurImpl::exec( |
| 153 | _megdnn_tensor_in src, _megdnn_tensor_in dst, _megdnn_workspace workspace) { |
| 154 | using namespace megcv; |
| 155 | check_exec(src.layout, dst.layout, workspace.size); |
| 156 | Param param = this->param(); |
| 157 | MEGDNN_DISPATCH_CPU_KERN_OPR( |
| 158 | if (dst.layout.dtype == dtype::Float32()) { |
| 159 | gaussian_blur_exec<float>(src, dst, param); |
| 160 | } else if (dst.layout.dtype == dtype::Uint8()) { |
| 161 | gaussian_blur_exec_8u(src, dst, param); |
| 162 | } else { megdnn_throw("Unsupported datatype of GaussianBlur optr."); }); |
| 163 | } |
| 164 | |
| 165 | } // namespace x86 |
| 166 | } // namespace megdnn |