tutorials icon indicating copy to clipboard operation
tutorials copied to clipboard

Export Python functions to ONNX as a single op

Open gyenesvi opened this issue 4 years ago • 1 comments

Ask a Question

Question

I have seen some (experimental?) support in ONNX proto to functions (sequence of ops). Is it actually supported by ONNX latest version, or was it just experimental? How can I export a PyTorch model with such a function in it?

Further information

  • Relevant Area: model usage, best practices

  • Is this issue related to a specific model?
    No

Notes

For example, when exporting a ShuffleNet, it would be good to have the shuffle ops as a single op/a function so that it is easier on the importer side to understand which ops form a higher level compound. For small functions like the shuffle op, it could be merged on the importer side, but such practice becomes prohibitive for larger functions.

gyenesvi avatar Feb 15 '21 15:02 gyenesvi

Should be solved by https://github.com/onnx/onnx/issues/3286. Thanks.

jcwchen avatar Mar 02 '21 18:03 jcwchen