| 69 | return x; |
| 70 | } |
| 71 | bool _runmbv1() { |
| 72 | auto x = _Input({1, 3, 224, 224}, NC4HW4); |
| 73 | auto y = _mobileNetV1Expr(x); |
| 74 | auto buffer = Variable::save({y}); |
| 75 | y = nullptr;x=nullptr; |
| 76 | MNN::BackendConfig bnConfig; |
| 77 | auto exe = Executor::newExecutor(MNN_FORWARD_CPU, bnConfig, 1); |
| 78 | ExecutorScope scope(exe); |
| 79 | std::shared_ptr<Module> m(Module::load({"Input"}, {"Prob"}, (const uint8_t*)buffer.data(), buffer.size())); |
| 80 | x = _Input({1, 3, 224, 224}, NC4HW4); |
| 81 | x->writeMap<float>(); |
| 82 | m->onForward({x}); |
| 83 | exe->setGlobalExecutorConfig(MNN_FORWARD_CPU, bnConfig, 4); |
| 84 | m->onForward({x}); |
| 85 | |
| 86 | return true; |
| 87 | } |
| 88 | |
| 89 | virtual bool run(int precision) { |
| 90 | int numberThread = 0; |
nothing calls this directly
no test coverage detected