Skip to content

Latest commit

 

History

History
 
 

protobuf-definitions

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Unity ML-Agents Protobuf Definitions

Contains relevant definitions needed to generate probobuf files used in ML-Agents Toolkit.

Requirements

  • grpc 1.14.1
  • protobuf 3.6.0

Set-up & Installation

pip install protobuf==3.6.0 --force

pip install grpcio-tools

nuget install Grpc.Tools into known directory.

Installing Protobuf Compiler

On Mac: brew install protobuf

On Windows & Linux: See here.

Running

  1. Install pre-requisites.
  2. Un-comment line 4 in make.bat, and set to correct Grpc.Tools sub-directory.
  3. Run make.bat
  4. In the generated UnityToExternalGrpc.cs file in the UnitySDK/Assets/ML-Agents/Scripts/CommunicatorObjects folder, you will need to add the following to the beginning of the file
# if UNITY_EDITOR || UNITY_STANDALONE_WIN || UNITY_STANDALONE_OSX || UNITY_STANDALONE_LINUX

and the following line to the end

#endif

This is to make sure the generated code does not try to access the Grpc library on platforms that are not supported by Grpc.