vicalloy opened a new issue #7908: URL: https://github.com/apache/tvm/issues/7908
1. The follow code is used to run the model by vm. ```python import onnx import time import tvm import numpy as np import tvm.relay as relay target = 'llvm' # model from openvino. https://github.com/openvinotoolkit/open_model_zoo/blob/master/models/intel/face-detection-0200/description/face-detection-0200.md model_path = 'face-detection-0200.org.onnx' onnx_model = onnx.load(model_path) shape = [1, 3, 256, 256] input_name = "image" shape_dict = { "image": shape, } mod, params = relay.frontend.from_onnx(onnx_model, shape_dict) with tvm.transform.PassContext(opt_level=3): exe = relay.vm.compile(mod, target="llvm", target_host=None, params=params) data = np.random.uniform(size=shape).astype("float32") ctx = tvm.cpu() vm = tvm.runtime.vm.VirtualMachine(exe, ctx) out = vm.run(data) print(out.asnumpy()) ``` 2. The error ``` File "run-tvm.py", line 30, in <module> print(out.asnumpy()) File "/home/hu/tvm/python/tvm/runtime/object.py", line 63, in __getattr__ return _ffi_node_api.NodeGetAttr(self, name) File "/home/hu/tvm/python/tvm/_ffi/_ctypes/packed_func.py", line 237, in __call__ raise get_last_ffi_error() TypeError: Traceback (most recent call last): 3: TVMFuncCall 2: _ZNSt17_Function_handlerIFvN3t 1: tvm::NodeGetAttr(tvm::runtime::TVMArgs, tvm::runtime::TVMRetValue*) 0: tvm::ReflectionVTable::GetAttr(tvm::runtime::Object*, tvm::runtime::String const&) const File "/home/hu/tvm/include/tvm/node/reflection.h", line 390 TypeError: runtime.ADT is not registered via TVM_REGISTER_NODE_TYPE ``` 3. The model: [face-detection-0200.org.zip](https://github.com/apache/tvm/files/6355337/face-detection-0200.org.zip) -- 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. For queries about this service, please contact Infrastructure at: [email protected]
