Search Unity

  1. Welcome to the Unity Forums! Please take the time to read our Code of Conduct to familiarize yourself with the forum rules and how to post constructively.

How to use a TF-hub saved_model in Unity

Discussion in 'ML-Agents' started by zwendi214, Apr 28, 2020.

  1. zwendi214


    Mar 1, 2020
    I plan to use "" model to build a game in Unity. It's my first time try the ml-agents plugin, so not sure how to do that.

    The model I downloaded from TF-hub is a saved_model.pb file.

    in ml-agents hub tutorial (, it says I should assign a <behaviour_name>.nn file to the Model parameter.


    In the Youtube tutorial(
    ), it says I should assign a <model_name>.bytes file to the Model parameter.

    I'm confused, what should I use?
  2. vincentpierre


    Unity Technologies

    May 5, 2017
    The video tutorial you linked to is rather old. we changed the model file from bytes to nn why we stoped using TensorFlowSharp and started using the Unity Inference Engine instead.
    ML-Agents only supports models trained with ML-Agents in games.
    If you want to use the Unity Inference Engine to use your non-ML-Agents model in your game this is its github repository :
    zwendi214 likes this.