When I perform a transformation on an ONNX node, I encounter the following error. I checked the input of this Mul
operation, and it looks like this.
relax.PrimValue
, but the actual input is indeed tvm.relax.expr.Call
. I would like to ask how to resolve this error. Thank you very much.
the error is:\
Traceback (most recent call last):
File "/lpai/code/llava_tvm/debug.py", line 39, in <module>
relax_mod = from_onnx(onnx_model, shape_dict=encoder_shape_dyna, dtype_dict=dtype_dict, keep_params_in_input=True)
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 3703, in from_onnx
return g.from_onnx(graph, opset)
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 3320, in from_onnx
self._construct_nodes(graph)
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 3504, in _construct_nodes
op = self._convert_operator(op_name, inputs, attr, self.opset)
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 3609, in _convert_operator
sym = op_function(self.bb, inputs, attrs, [self._nodes, self._params])
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 381, in _impl_v7
return cls.base_impl(bb, inputs, attr, params)
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 344, in base_impl
x = _to_numpy(inputs[0])
File "/lpai/tvm/python/tvm/relax/frontend/onnx/onnx_frontend.py", line 324, in _to_numpy
return x.data.numpy()
File "/lpai/tvm/python/tvm/runtime/object.py", line 75, in __getattr__
raise AttributeError(f"{type(self)} has no attribute {name}") from None
AttributeError: <class 'tvm.relax.expr.Call'> has no attribute data