Search Unity

  1. Get the latest news, tutorials and offers directly to your inbox with our newsletters. Sign up now.
    Dismiss Notice

Help Wanted tf2 to onnx conversion?

Discussion in 'Barracuda' started by ADNCG, Mar 5, 2021.

  1. ADNCG

    ADNCG

    Joined:
    Jun 9, 2014
    Posts:
    877
    Docs recommend using tf1 when converting to onnx from tf/keras. Is that still a thing? Asking with hope that it might be outdated docs.
     
  2. alexandreribard_unity

    alexandreribard_unity

    Unity Technologies

    Joined:
    Sep 18, 2019
    Posts:
    27
    https://github.com/onnx/tensorflow-onnx
    Looks like tf2onnx does now support exporting TF-2.x to onnx.
    I know at one point they were having stability issues, but now it seems ok. So I would go with that.

    Let me know
     
    ADNCG likes this.
  3. ADNCG

    ADNCG

    Joined:
    Jun 9, 2014
    Posts:
    877
    Everything went super smoothly. Ran into a minor issue but that's all on me. Didn't realize the Tensor(texture) constructor outputs 0-1 values. I rescale within the model as well.

    Thanks for the hard work on barracuda <3
     
  4. alexandreribard_unity

    alexandreribard_unity

    Unity Technologies

    Joined:
    Sep 18, 2019
    Posts:
    27
    awesome, glad to hear it :)
     
unityunity