zhiwei-dong opened a new issue, #11371:
URL: https://github.com/apache/tvm/issues/11371

   ### Expected behavior
   
   Thank for your great works on microTVM, I try to run MCUNet model, in 
[here](https://drive.google.com/file/d/1ievEPUMpA5gPdFJY3SWzB2N6kv4n9keN/view?usp=sharing)
 .
   I followed this 
[tutorial](https://tvm.apache.org/docs/how_to/work_with_microtvm/micro_tvmc.html#sphx-glr-how-to-work-with-microtvm-micro-tvmc-py).
 When I use the tutorial 
[model](https://github.com/tensorflow/tflite-micro/raw/main/tensorflow/lite/micro/examples/magic_wand/magic_wand.tflite),
 every thing is ok, but when I use above mcunet model, I encounter RPCError. 
   
   ### Actual behavior
   
   (microtvm-3BvVWFka-py3.6) vagrant@microtvm:/Users/zhiwei.dong/test/tvm$ tvmc 
run \
   >          --device micro \
   >          project \
   >          --project-option zephyr_board=qemu_x86 \
   >          --fill-mode ones \
   >          --print-top 4
   INFO:__main__:b'[  2%] Built target parse_syscalls_target\n'
   INFO:__main__:b'[  3%] Built target kobj_types_h_target\n'
   INFO:__main__:b'[  4%] Built target syscall_list_h_target\n'
   INFO:__main__:b'[  5%] Built target driver_validation_h_target\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
offsets\n'
   INFO:__main__:b'[  6%] Built target offsets\n'
   INFO:__main__:b'[  7%] Built target offsets_h\n'
   INFO:__main__:b'[  7%] Built target zephyr_generated_headers\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
kernel\n'
   INFO:__main__:b'[ 27%] Built target kernel\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
microtvm_rpc_server\n'
   INFO:__main__:b'[ 28%] Built target microtvm_rpc_server\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
microtvm_rpc_common\n'
   INFO:__main__:b'[ 32%] Built target microtvm_rpc_common\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
common\n'
   INFO:__main__:b'[ 36%] Built target common\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
tvm_model\n'
   INFO:__main__:b'[ 39%] Built target tvm_model\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target app\n'
   INFO:__main__:b'[ 40%] Built target app\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
zephyr\n'
   INFO:__main__:b'[ 62%] Built target zephyr\n'
   INFO:__main__:b'[ 63%] Built target linker_zephyr_prebuilt_script_target\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
arch__x86__core\n'
   INFO:__main__:b'[ 77%] Built target arch__x86__core\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
lib__libc__newlib\n'
   INFO:__main__:b'[ 78%] Built target lib__libc__newlib\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
lib__posix\n'
   INFO:__main__:b'[ 80%] Built target lib__posix\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
subsys__random\n'
   INFO:__main__:b'[ 81%] Built target subsys__random\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
drivers__interrupt_controller\n'
   INFO:__main__:b'[ 84%] Built target drivers__interrupt_controller\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
drivers__serial\n'
   INFO:__main__:b'[ 86%] Built target drivers__serial\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
drivers__timer\n'
   INFO:__main__:b'[ 88%] Built target drivers__timer\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
zephyr_prebuilt\n'
   INFO:__main__:b'[ 90%] Built target zephyr_prebuilt\n'
   INFO:__main__:b'[ 91%] Built target linker_zephyr_final_script_target\n'
   INFO:__main__:b'[ 91%] Built target gen_idt_output\n'
   INFO:__main__:b'[ 92%] Built target staticIdt_o\n'
   INFO:__main__:b'[ 93%] Built target irq_int_vector_map_o\n'
   INFO:__main__:b'[ 94%] Built target irq_vectors_alloc_o\n'
   INFO:__main__:b'[ 95%] Built target pagetables_bin_target\n'
   INFO:__main__:b'[ 95%] Built target pagetables_o\n'
   INFO:__main__:b'Consolidate compiler generated dependencies of target 
zephyr_final\n'
   INFO:__main__:b'[ 98%] Built target zephyr_final\n'
   INFO:__main__:b'[100%] [QEMU] CPU: qemu32,+nx,+pae\n'
   [14:54:33] 
/Users/zhiwei.dong/test/tvm/src/runtime/micro/micro_session.cc:367: remote: 
microTVM Zephyr runtime - running
   INFO:__main__:b'[100%] Built target run\n'
   Traceback (most recent call last):
     File "/usr/lib/python3.6/runpy.py", line 193, in _run_module_as_main
       "__main__", mod_spec)
     File "/usr/lib/python3.6/runpy.py", line 85, in _run_code
       exec(code, run_globals)
     File "/Users/zhiwei.dong/test/tvm/python/tvm/driver/tvmc/__main__.py", 
line 24, in <module>
       tvmc.main.main()
     File "/Users/zhiwei.dong/test/tvm/python/tvm/driver/tvmc/main.py", line 
115, in main
       sys.exit(_main(sys.argv[1:]))
     File "/Users/zhiwei.dong/test/tvm/python/tvm/driver/tvmc/main.py", line 
103, in _main
       return args.func(args)
     File "/Users/zhiwei.dong/test/tvm/python/tvm/driver/tvmc/runner.py", line 
277, in drive_run
       options=options,
     File "/Users/zhiwei.dong/test/tvm/python/tvm/driver/tvmc/runner.py", line 
580, in run_module
       module = tvm.micro.create_local_graph_executor(tvmc_package.graph, lib, 
dev)
     File "/Users/zhiwei.dong/test/tvm/python/tvm/micro/session.py", line 214, 
in create_local_graph_executor
       fcreate(graph_json_str, mod, lookup_remote_linked_param, *device_type_id)
     File "/Users/zhiwei.dong/test/tvm/python/tvm/_ffi/_ctypes/packed_func.py", 
line 237, in __call__
       raise get_last_ffi_error()
   tvm.error.RPCError: Traceback (most recent call last):
     12: TVMFuncCall
     11: 
tvm::runtime::PackedFuncObj::Extractor<tvm::runtime::PackedFuncSubObj<tvm::runtime::{lambda(tvm::runtime::TVMArgs,
 tvm::runtime::TVMRetValue*)#1}> >::Call(tvm::runtime::PackedFuncObj const*, 
tvm::runtime::TVMArgs, tvm::runtime::TVMRetValue*)
     10: tvm::runtime::GraphExecutorCreate(std::__cxx11::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, tvm::runtime::Module 
const&, std::vector<DLDevice, std::allocator<DLDevice> > const&, 
tvm::runtime::PackedFunc)
     9: tvm::runtime::GraphExecutor::Init(std::__cxx11::basic_string<char, 
std::char_traits<char>, std::allocator<char> > const&, tvm::runtime::Module, 
std::vector<DLDevice, std::allocator<DLDevice> > const&, 
tvm::runtime::PackedFunc)
     8: tvm::runtime::GraphExecutor::SetupStorage()
     7: tvm::runtime::NDArray::Empty(tvm::runtime::ShapeTuple, DLDataType, 
DLDevice, tvm::runtime::Optional<tvm::runtime::String>)
     6: tvm::runtime::RPCDeviceAPI::AllocDataSpace(DLDevice, int, long const*, 
DLDataType, tvm::runtime::Optional<tvm::runtime::String>)
     5: tvm::runtime::RPCClientSession::AllocDataSpace(DLDevice, int, long 
const*, DLDataType, tvm::runtime::Optional<tvm::runtime::String>)
     4: 
tvm::runtime::PackedFuncObj::Extractor<tvm::runtime::PackedFuncSubObj<tvm::runtime::RPCEndpoint::Init()::{lambda(tvm::runtime::TVMArgs,
 tvm::runtime::TVMRetValue*)#2}> >::Call(tvm::runtime::PackedFuncObj const*, 
tvm::runtime::TVMArgs, tvm::runtime::TVMRetValue*)
     3: tvm::runtime::RPCEndpoint::HandleUntilReturnEvent(bool, 
std::function<void (tvm::runtime::TVMArgs)>)
     2: tvm::runtime::RPCEndpoint::EventHandler::HandleNextEvent(bool, bool, 
std::function<void (tvm::runtime::TVMArgs)>)
     1: 
tvm::runtime::RPCEndpoint::EventHandler::HandleProcessPacket(std::function<void 
(tvm::runtime::TVMArgs)>)
     0: 
tvm::runtime::RPCEndpoint::EventHandler::HandleReturn(tvm::runtime::RPCCode, 
std::function<void (tvm::runtime::TVMArgs)>)
     File "/Users/zhiwei.dong/test/tvm/src/runtime/rpc/rpc_endpoint.cc", line 
376
   RPCError: Error caught from RPC call:
   
   ### Environment
   
   Reference VM is my environment.
   
   ### Steps to reproduce
   
   Just download my model, and follow above tutorial, error will present when 
executing dvmc run cmd.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to