MCPcopy Create free account
hub / github.com/MegEngine/MegEngine / kern_naive

Method kern_naive

dnn/src/naive/resize/opr_impl.cpp:175–207  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

173}
174template <typename ctype>
175void ResizeImpl::kern_naive(const KernParam<ctype>& kern_param) {
176 if (kern_param.format == Format::NHWC) {
177 MIDOUT_BEGIN(megdnn_naive_resize_layout, midout_iv(0)) {
178 kern_naive_nhwc(kern_param);
179 }
180 MIDOUT_END();
181 return;
182 } else if (kern_param.format == Format::NHWCD4) {
183 MIDOUT_BEGIN(megdnn_naive_resize_layout, midout_iv(1)) {
184 kern_naive_nhwcd4(kern_param);
185 }
186 MIDOUT_END();
187 return;
188 } else if (kern_param.format == Format::NCHW4) {
189 MIDOUT_BEGIN(megdnn_naive_resize_layout, midout_iv(2)) {
190 kern_naive_nchwx<ctype, 4>(kern_param);
191 }
192 MIDOUT_END();
193 return;
194 } else if (kern_param.format == Format::NCHW44) {
195 MIDOUT_BEGIN(megdnn_naive_resize_layout, midout_iv(3)) {
196 kern_naive_nchwx<ctype, 4>(kern_param);
197 }
198 MIDOUT_END();
199 return;
200 } else if (kern_param.format == Format::NCHW88) {
201 MIDOUT_BEGIN(megdnn_naive_resize_layout, midout_iv(4)) {
202 kern_naive_nchwx<ctype, 8>(kern_param);
203 }
204 MIDOUT_END();
205 return;
206 }
207}
208
209template <typename ctype>
210void ResizeImpl::kern_naive_nhwc(const KernParam<ctype>& kern_param) {

Callers

nothing calls this directly

Calls 1

MIDOUT_BEGINFunction · 0.50

Tested by

no test coverage detected