tvm.error.OpNotImplemented: The following operators are not supported for frontend ONNX: Resize, MaxUnpool

I am new to tvm, and recently Im doing some stuff on accelerating onnx model using tvm.
But seems there are two operators from onnx not supported by tvm when I tried to load onnx model into TVM.
Here is the error:
tvm.error.OpNotImplemented: The following operators are not supported for frontend ONNX: Resize, MaxUnpool

Do I need wrote those operators in tvm on my own? Or there are some useful tools?
Can anybody tell me how to solve it?

You can implement the operators in the tvm/python/tvm/relay/frontend/onnx.py, following the templates seen in this file (a class for an operator, use _op.X functions, etc.) and adding the new operators in the convert map.

In practice I (and others) can’t make it work, and TVM guys have been silent on this subject (onnx operators support) for about 2 weeks.

Good luck!

1 Like

In general adding new operators to Relay, Topi and the frontends is very hard to make it on your own and this is a showstopper when at least one single operator is missing.

hello,do you know how to fix this problem now?

I agree. Adding a new operator to tvm(both in relay and topi) + adding support for frontend(like tensorflow) is a pretty difficult task. I am also trying to add new operators. I have got some luck with this but still struggle a lot. Once I get a pretty fair understanding, probably I will do a write up on the same. Did you already get acquainted with the process of adding new operators in tvm. If so please share your insights too.

Regards, Deepak

See [Relay][ONNX][Frontend] Implement Resize Operation for onnx resize

Thank you @masahi. I will also try to put some draft documentation for operators support in tvm in Relay, topi and front-end. I will try to make it generic so anyone can take some hint from it even for different type of operators(math, probability, nn etc.) I am currently trying to understand it myself so I can support few operators.