Getting error model was trained with newer verision of trainer

Hi,
i have been trying to learn Ml-agents and everything was working great till I tried to take result agent.onnx file and added to the behavior and show me a warning in the editor and exception if running

UnityAgentsException: Unknown tensorProxy expected as input : obs_0
Unity.MLAgents.Inference.TensorGenerator.GenerateTensors (System.Collections.Generic.IReadOnlyList1[T] tensors, System.Int32 currentBatchSize, System.Collections.Generic.IList1[T] infos) (at Library/PackageCache/com.unity.ml-agents@1.9.1-preview/Runtime/Inference/TensorGenerator.cs:164)

the training was done with the same versions
I am using com.unity.ml-agents v1.9.1
ml-agents (Python) v0.27.0
with latest python version

thanks in advance

Hi, if you are using the latest python version, you will need to use the latest C# version. Please read the documentation for each release to see which packages work together.

ml-agents (Python) v0.27.0 requires → com.unity.ml-agents 2.1.0

you have the wrong version of mlagents in unity. Check enable preview packages to install the right version in the Unity IDE. This error happened to me too!

check this url the corresponding mlagents in unity for each version of the python mlagents: https://github.com/Unity-Technologies/ml-agents/tree/release_18_docs

1 Like