浏览代码

Merge branch 'master' into develop-agentprocessor

/develop-newnormalization
Ervin Teng 5 年前
当前提交
3d25f9d2
共有 142 个文件被更改,包括 605 次插入462 次删除
  1. 2
      .circleci/config.yml
  2. 6
      .pre-commit-config.yaml
  3. 6
      .pylintrc
  4. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/AgentAction.cs
  5. 10
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/AgentInfo.cs
  6. 12
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/AgentInfoActionPair.cs
  7. 10
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/BrainParameters.cs
  8. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/Command.cs
  9. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/CustomResetParameters.cs
  10. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/DemonstrationMeta.cs
  11. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/EngineConfiguration.cs
  12. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/Header.cs
  13. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/Observation.cs
  14. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/SpaceType.cs
  15. 12
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityInput.cs
  16. 14
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityMessage.cs
  17. 12
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityOutput.cs
  18. 8
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlInitializationInput.cs
  19. 10
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlInitializationOutput.cs
  20. 12
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlInput.cs
  21. 10
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlOutput.cs
  22. 10
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityToExternal.cs
  23. 2
      UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityToExternalGrpc.cs
  24. 6
      docs/Basic-Guide.md
  25. 8
      docs/Learning-Environment-Executable.md
  26. 10
      docs/Migrating.md
  27. 22
      docs/Python-API.md
  28. 2
      docs/Training-Generalized-Reinforcement-Learning-Agents.md
  29. 10
      docs/Training-on-Amazon-Web-Service.md
  30. 2
      docs/Training-on-Microsoft-Azure.md
  31. 2
      gym-unity/gym_unity/__init__.py
  32. 2
      gym-unity/gym_unity/envs/__init__.py
  33. 2
      gym-unity/gym_unity/tests/test_gym.py
  34. 2
      ml-agents-envs/README.md
  35. 8
      ml-agents-envs/setup.py
  36. 2
      ml-agents/README.md
  37. 2
      ml-agents/mlagents/trainers/__init__.py
  38. 10
      ml-agents/mlagents/trainers/brain.py
  39. 4
      ml-agents/mlagents/trainers/brain_conversion_utils.py
  40. 2
      ml-agents/mlagents/trainers/buffer.py
  41. 8
      ml-agents/mlagents/trainers/demo_loader.py
  42. 5
      ml-agents/mlagents/trainers/env_manager.py
  43. 8
      ml-agents/mlagents/trainers/exception.py
  44. 14
      ml-agents/mlagents/trainers/learn.py
  45. 11
      ml-agents/mlagents/trainers/meta_curriculum.py
  46. 2
      ml-agents/mlagents/trainers/ppo/multi_gpu_policy.py
  47. 2
      ml-agents/mlagents/trainers/ppo/policy.py
  48. 2
      ml-agents/mlagents/trainers/sac/policy.py
  49. 2
      ml-agents/mlagents/trainers/sac/trainer.py
  50. 6
      ml-agents/mlagents/trainers/simple_env_manager.py
  51. 16
      ml-agents/mlagents/trainers/subprocess_env_manager.py
  52. 12
      ml-agents/mlagents/trainers/tests/test_bcmodule.py
  53. 1
      ml-agents/mlagents/trainers/tests/test_curriculum.py
  54. 53
      ml-agents/mlagents/trainers/tests/test_meta_curriculum.py
  55. 14
      ml-agents/mlagents/trainers/tests/test_ppo.py
  56. 16
      ml-agents/mlagents/trainers/tests/test_reward_signals.py
  57. 10
      ml-agents/mlagents/trainers/tests/test_sac.py
  58. 22
      ml-agents/mlagents/trainers/tests/test_simple_rl.py
  59. 4
      ml-agents/mlagents/trainers/tests/test_subprocess_env_manager.py
  60. 73
      ml-agents/mlagents/trainers/tests/test_trainer_util.py
  61. 2
      ml-agents/mlagents/trainers/tf_policy.py
  62. 6
      ml-agents/mlagents/trainers/trainer.py
  63. 9
      ml-agents/mlagents/trainers/trainer_controller.py
  64. 59
      ml-agents/mlagents/trainers/trainer_util.py
  65. 6
      ml-agents/setup.py
  66. 6
      notebooks/getting-started.ipynb
  67. 12
      protobuf-definitions/make.sh
  68. 8
      protobuf-definitions/make_for_win.bat
  69. 2
      utils/validate_versions.py
  70. 4
      ml-agents-envs/mlagents_envs/tests/test_timers.py
  71. 8
      ml-agents-envs/mlagents_envs/tests/test_side_channel.py
  72. 10
      ml-agents-envs/mlagents_envs/tests/test_rpc_utils.py
  73. 4
      ml-agents-envs/mlagents_envs/tests/test_rpc_communicator.py
  74. 26
      ml-agents-envs/mlagents_envs/tests/test_envs.py
  75. 2
      ml-agents-envs/mlagents_envs/side_channel/raw_bytes_channel.py
  76. 2
      ml-agents-envs/mlagents_envs/side_channel/float_properties_channel.py
  77. 4
      ml-agents-envs/mlagents_envs/side_channel/engine_configuration_channel.py
  78. 10
      ml-agents-envs/mlagents_envs/rpc_utils.py
  79. 10
      ml-agents-envs/mlagents_envs/rpc_communicator.py
  80. 16
      ml-agents-envs/mlagents_envs/mock_communicator.py
  81. 2
      ml-agents-envs/mlagents_envs/exception.py
  82. 26
      ml-agents-envs/mlagents_envs/environment.py
  83. 10
      ml-agents-envs/mlagents_envs/communicator_objects/unity_to_external_pb2_grpc.py
  84. 14
      ml-agents-envs/mlagents_envs/communicator_objects/unity_to_external_pb2.py
  85. 8
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_output_pb2.pyi
  86. 18
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_output_pb2.py
  87. 16
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_input_pb2.pyi
  88. 22
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_input_pb2.py
  89. 8
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_initialization_output_pb2.pyi
  90. 14
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_initialization_output_pb2.py
  91. 8
      ml-agents-envs/mlagents_envs/communicator_objects/unity_rl_initialization_input_pb2.py
  92. 16
      ml-agents-envs/mlagents_envs/communicator_objects/unity_output_pb2.pyi
  93. 18
      ml-agents-envs/mlagents_envs/communicator_objects/unity_output_pb2.py
  94. 24
      ml-agents-envs/mlagents_envs/communicator_objects/unity_message_pb2.pyi
  95. 22
      ml-agents-envs/mlagents_envs/communicator_objects/unity_message_pb2.py
  96. 16
      ml-agents-envs/mlagents_envs/communicator_objects/unity_input_pb2.pyi
  97. 18
      ml-agents-envs/mlagents_envs/communicator_objects/unity_input_pb2.py
  98. 6
      ml-agents-envs/mlagents_envs/communicator_objects/space_type_pb2.py
  99. 10
      ml-agents-envs/mlagents_envs/communicator_objects/observation_pb2.py
  100. 8
      ml-agents-envs/mlagents_envs/communicator_objects/header_pb2.py

2
.circleci/config.yml


- checkout
- run:
name: Combine proto files for caching
command: cat protobuf-definitions/proto/mlagents/envs/communicator_objects/*.proto > /tmp/proto_deps.txt
command: cat protobuf-definitions/proto/mlagents_envs/communicator_objects/*.proto > /tmp/proto_deps.txt
- restore_cache:
keys:

6
.pre-commit-config.yaml


- id: mypy
name: mypy-ml-agents
files: "ml-agents/.*"
args: [--ignore-missing-imports, --disallow-incomplete-defs, --namespace-packages]
args: [--ignore-missing-imports, --disallow-incomplete-defs]
args: [--ignore-missing-imports, --disallow-incomplete-defs, --namespace-packages]
args: [--ignore-missing-imports, --disallow-incomplete-defs]
args: [--ignore-missing-imports, --disallow-incomplete-defs, --namespace-packages]
args: [--ignore-missing-imports, --disallow-incomplete-defs]
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v2.4.0

6
.pylintrc


# W0703: Catching too general exception Exception
W0703,
# E0401: Unable to import...
# E0611: No name '...' in module '...'
# need to look into these, probably namespace packages
E0401, E0611,
# E0401: Unable to import... - triggers for external dependencies like numpy
E0401,
# This was causing false positives
# Appears to be https://github.com/PyCQA/pylint/issues/2981

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/AgentAction.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/agent_action.proto
// source: mlagents_envs/communicator_objects/agent_action.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/agent_action.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/agent_action.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/agent_action.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/agent_action.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjVtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2Fj",
"CjVtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2Fj",
"dGlvbi5wcm90bxIUY29tbXVuaWNhdG9yX29iamVjdHMiSwoQQWdlbnRBY3Rp",
"b25Qcm90bxIWCg52ZWN0b3JfYWN0aW9ucxgBIAMoAhINCgV2YWx1ZRgEIAEo",
"AkoECAIQA0oECAMQBEoECAUQBkIfqgIcTUxBZ2VudHMuQ29tbXVuaWNhdG9y",

10
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/AgentInfo.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/agent_info.proto
// source: mlagents_envs/communicator_objects/agent_info.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/agent_info.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/agent_info.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/agent_info.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/agent_info.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjNtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2lu",
"Zm8ucHJvdG8SFGNvbW11bmljYXRvcl9vYmplY3RzGjRtbGFnZW50cy9lbnZz",
"CjNtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2lu",
"Zm8ucHJvdG8SFGNvbW11bmljYXRvcl9vYmplY3RzGjRtbGFnZW50c19lbnZz",
"L2NvbW11bmljYXRvcl9vYmplY3RzL29ic2VydmF0aW9uLnByb3RvItEBCg5B",
"Z2VudEluZm9Qcm90bxIOCgZyZXdhcmQYByABKAISDAoEZG9uZRgIIAEoCBIY",
"ChBtYXhfc3RlcF9yZWFjaGVkGAkgASgIEgoKAmlkGAogASgFEhMKC2FjdGlv",

12
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/AgentInfoActionPair.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/agent_info_action_pair.proto
// source: mlagents_envs/communicator_objects/agent_info_action_pair.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/agent_info_action_pair.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/agent_info_action_pair.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/agent_info_action_pair.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/agent_info_action_pair.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"Cj9tbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2lu",
"Cj9tbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2lu",
"bGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2luZm8u",
"cHJvdG8aNW1sYWdlbnRzL2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvYWdl",
"bGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2FnZW50X2luZm8u",
"cHJvdG8aNW1sYWdlbnRzX2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvYWdl",
"bnRfYWN0aW9uLnByb3RvIpEBChhBZ2VudEluZm9BY3Rpb25QYWlyUHJvdG8S",
"OAoKYWdlbnRfaW5mbxgBIAEoCzIkLmNvbW11bmljYXRvcl9vYmplY3RzLkFn",
"ZW50SW5mb1Byb3RvEjsKC2FjdGlvbl9pbmZvGAIgASgLMiYuY29tbXVuaWNh",

10
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/BrainParameters.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/brain_parameters.proto
// source: mlagents_envs/communicator_objects/brain_parameters.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/brain_parameters.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/brain_parameters.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/brain_parameters.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/brain_parameters.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjltbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2JyYWluX3Bh",
"CjltbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2JyYWluX3Bh",
"cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3NwYWNlX3R5cGUucHJvdG8i",
"c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3NwYWNlX3R5cGUucHJvdG8i",
"2QEKFEJyYWluUGFyYW1ldGVyc1Byb3RvEhoKEnZlY3Rvcl9hY3Rpb25fc2l6",
"ZRgDIAMoBRIiChp2ZWN0b3JfYWN0aW9uX2Rlc2NyaXB0aW9ucxgFIAMoCRJG",
"Chh2ZWN0b3JfYWN0aW9uX3NwYWNlX3R5cGUYBiABKA4yJC5jb21tdW5pY2F0",

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/Command.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/command.proto
// source: mlagents_envs/communicator_objects/command.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/command.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/command.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/command.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/command.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjBtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2NvbW1hbmQu",
"CjBtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2NvbW1hbmQu",
"cHJvdG8SFGNvbW11bmljYXRvcl9vYmplY3RzKi0KDENvbW1hbmRQcm90bxII",
"CgRTVEVQEAASCQoFUkVTRVQQARIICgRRVUlUEAJCH6oCHE1MQWdlbnRzLkNv",
"bW11bmljYXRvck9iamVjdHNiBnByb3RvMw=="));

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/CustomResetParameters.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/custom_reset_parameters.proto
// source: mlagents_envs/communicator_objects/custom_reset_parameters.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/custom_reset_parameters.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/custom_reset_parameters.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/custom_reset_parameters.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/custom_reset_parameters.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CkBtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2N1c3RvbV9y",
"CkBtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2N1c3RvbV9y",
"ZXNldF9wYXJhbWV0ZXJzLnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cyIc",
"ChpDdXN0b21SZXNldFBhcmFtZXRlcnNQcm90b0IfqgIcTUxBZ2VudHMuQ29t",
"bXVuaWNhdG9yT2JqZWN0c2IGcHJvdG8z"));

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/DemonstrationMeta.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/demonstration_meta.proto
// source: mlagents_envs/communicator_objects/demonstration_meta.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/demonstration_meta.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/demonstration_meta.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/demonstration_meta.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/demonstration_meta.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjttbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2RlbW9uc3Ry",
"CjttbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2RlbW9uc3Ry",
"YXRpb25fbWV0YS5wcm90bxIUY29tbXVuaWNhdG9yX29iamVjdHMijQEKFkRl",
"bW9uc3RyYXRpb25NZXRhUHJvdG8SEwoLYXBpX3ZlcnNpb24YASABKAUSGgoS",
"ZGVtb25zdHJhdGlvbl9uYW1lGAIgASgJEhQKDG51bWJlcl9zdGVwcxgDIAEo",

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/EngineConfiguration.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/engine_configuration.proto
// source: mlagents_envs/communicator_objects/engine_configuration.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/engine_configuration.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/engine_configuration.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/engine_configuration.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/engine_configuration.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"Cj1tbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2VuZ2luZV9j",
"Cj1tbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2VuZ2luZV9j",
"b25maWd1cmF0aW9uLnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cyKVAQoY",
"RW5naW5lQ29uZmlndXJhdGlvblByb3RvEg0KBXdpZHRoGAEgASgFEg4KBmhl",
"aWdodBgCIAEoBRIVCg1xdWFsaXR5X2xldmVsGAMgASgFEhIKCnRpbWVfc2Nh",

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/Header.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/header.proto
// source: mlagents_envs/communicator_objects/header.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/header.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/header.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/header.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/header.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"Ci9tbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2hlYWRlci5w",
"Ci9tbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL2hlYWRlci5w",
"cm90bxIUY29tbXVuaWNhdG9yX29iamVjdHMiLgoLSGVhZGVyUHJvdG8SDgoG",
"c3RhdHVzGAEgASgFEg8KB21lc3NhZ2UYAiABKAlCH6oCHE1MQWdlbnRzLkNv",
"bW11bmljYXRvck9iamVjdHNiBnByb3RvMw=="));

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/Observation.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/observation.proto
// source: mlagents_envs/communicator_objects/observation.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/observation.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/observation.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/observation.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/observation.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjRtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL29ic2VydmF0",
"CjRtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL29ic2VydmF0",
"aW9uLnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cyL5AQoQT2JzZXJ2YXRp",
"b25Qcm90bxINCgVzaGFwZRgBIAMoBRJEChBjb21wcmVzc2lvbl90eXBlGAIg",
"ASgOMiouY29tbXVuaWNhdG9yX29iamVjdHMuQ29tcHJlc3Npb25UeXBlUHJv",

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/SpaceType.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/space_type.proto
// source: mlagents_envs/communicator_objects/space_type.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/space_type.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/space_type.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/space_type.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/space_type.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjNtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3NwYWNlX3R5",
"CjNtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3NwYWNlX3R5",
"cGUucHJvdG8SFGNvbW11bmljYXRvcl9vYmplY3RzKi4KDlNwYWNlVHlwZVBy",
"b3RvEgwKCGRpc2NyZXRlEAASDgoKY29udGludW91cxABQh+qAhxNTEFnZW50",
"cy5Db21tdW5pY2F0b3JPYmplY3RzYgZwcm90bzM="));

12
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityInput.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_input.proto
// source: mlagents_envs/communicator_objects/unity_input.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_input.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_input.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_input.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_input.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjRtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X2lu",
"cHV0LnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cxo3bWxhZ2VudHMvZW52",
"CjRtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X2lu",
"cHV0LnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cxo3bWxhZ2VudHNfZW52",
"bWxhZ2VudHMvZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy91bml0eV9ybF9p",
"bWxhZ2VudHNfZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy91bml0eV9ybF9p",
"bml0aWFsaXphdGlvbl9pbnB1dC5wcm90byKkAQoPVW5pdHlJbnB1dFByb3Rv",
"EjkKCHJsX2lucHV0GAEgASgLMicuY29tbXVuaWNhdG9yX29iamVjdHMuVW5p",
"dHlSTElucHV0UHJvdG8SVgoXcmxfaW5pdGlhbGl6YXRpb25faW5wdXQYAiAB",

14
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityMessage.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_message.proto
// source: mlagents_envs/communicator_objects/unity_message.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_message.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_message.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_message.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_message.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjZtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X21l",
"c3NhZ2UucHJvdG8SFGNvbW11bmljYXRvcl9vYmplY3RzGjVtbGFnZW50cy9l",
"CjZtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X21l",
"c3NhZ2UucHJvdG8SFGNvbW11bmljYXRvcl9vYmplY3RzGjVtbGFnZW50c19l",
"bWxhZ2VudHMvZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy91bml0eV9pbnB1",
"dC5wcm90bxovbWxhZ2VudHMvZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy9o",
"bWxhZ2VudHNfZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy91bml0eV9pbnB1",
"dC5wcm90bxovbWxhZ2VudHNfZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy9o",
"ZWFkZXIucHJvdG8iwAEKEVVuaXR5TWVzc2FnZVByb3RvEjEKBmhlYWRlchgB",
"IAEoCzIhLmNvbW11bmljYXRvcl9vYmplY3RzLkhlYWRlclByb3RvEjwKDHVu",
"aXR5X291dHB1dBgCIAEoCzImLmNvbW11bmljYXRvcl9vYmplY3RzLlVuaXR5",

12
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityOutput.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_output.proto
// source: mlagents_envs/communicator_objects/unity_output.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_output.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_output.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_output.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_output.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjVtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X291",
"dHB1dC5wcm90bxIUY29tbXVuaWNhdG9yX29iamVjdHMaOG1sYWdlbnRzL2Vu",
"CjVtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X291",
"dHB1dC5wcm90bxIUY29tbXVuaWNhdG9yX29iamVjdHMaOG1sYWdlbnRzX2Vu",
"GkdtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"GkdtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"X2luaXRpYWxpemF0aW9uX291dHB1dC5wcm90byKpAQoQVW5pdHlPdXRwdXRQ",
"cm90bxI7CglybF9vdXRwdXQYASABKAsyKC5jb21tdW5pY2F0b3Jfb2JqZWN0",
"cy5Vbml0eVJMT3V0cHV0UHJvdG8SWAoYcmxfaW5pdGlhbGl6YXRpb25fb3V0",

8
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlInitializationInput.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_rl_initialization_input.proto
// source: mlagents_envs/communicator_objects/unity_rl_initialization_input.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_rl_initialization_input.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_rl_initialization_input.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_rl_initialization_input.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_rl_initialization_input.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CkZtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"CkZtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"X2luaXRpYWxpemF0aW9uX2lucHV0LnByb3RvEhRjb21tdW5pY2F0b3Jfb2Jq",
"ZWN0cyIvCh9Vbml0eVJMSW5pdGlhbGl6YXRpb25JbnB1dFByb3RvEgwKBHNl",
"ZWQYASABKAVCH6oCHE1MQWdlbnRzLkNvbW11bmljYXRvck9iamVjdHNiBnBy",

10
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlInitializationOutput.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_rl_initialization_output.proto
// source: mlagents_envs/communicator_objects/unity_rl_initialization_output.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_rl_initialization_output.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_rl_initialization_output.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_rl_initialization_output.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_rl_initialization_output.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CkdtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"CkdtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"amVjdHMaOW1sYWdlbnRzL2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvYnJh",
"amVjdHMaOW1sYWdlbnRzX2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvYnJh",
"aW5fcGFyYW1ldGVycy5wcm90byKfAQogVW5pdHlSTEluaXRpYWxpemF0aW9u",
"T3V0cHV0UHJvdG8SDAoEbmFtZRgBIAEoCRIPCgd2ZXJzaW9uGAIgASgJEhAK",
"CGxvZ19wYXRoGAMgASgJEkQKEGJyYWluX3BhcmFtZXRlcnMYBSADKAsyKi5j",

12
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlInput.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_rl_input.proto
// source: mlagents_envs/communicator_objects/unity_rl_input.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_rl_input.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_rl_input.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_rl_input.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_rl_input.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjdtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"X2lucHV0LnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cxo1bWxhZ2VudHMv",
"CjdtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"X2lucHV0LnByb3RvEhRjb21tdW5pY2F0b3Jfb2JqZWN0cxo1bWxhZ2VudHNf",
"MG1sYWdlbnRzL2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvY29tbWFuZC5w",
"MG1sYWdlbnRzX2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvY29tbWFuZC5w",
"cm90byL+AgoRVW5pdHlSTElucHV0UHJvdG8SUAoNYWdlbnRfYWN0aW9ucxgB",
"IAMoCzI5LmNvbW11bmljYXRvcl9vYmplY3RzLlVuaXR5UkxJbnB1dFByb3Rv",
"LkFnZW50QWN0aW9uc0VudHJ5EjMKB2NvbW1hbmQYBCABKA4yIi5jb21tdW5p",

10
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityRlOutput.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_rl_output.proto
// source: mlagents_envs/communicator_objects/unity_rl_output.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_rl_output.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_rl_output.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_rl_output.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_rl_output.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjhtbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"CjhtbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Js",
"L2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvYWdlbnRfaW5mby5wcm90byK5",
"X2VudnMvY29tbXVuaWNhdG9yX29iamVjdHMvYWdlbnRfaW5mby5wcm90byK5",
"AgoSVW5pdHlSTE91dHB1dFByb3RvEkwKCmFnZW50SW5mb3MYAiADKAsyOC5j",
"b21tdW5pY2F0b3Jfb2JqZWN0cy5Vbml0eVJMT3V0cHV0UHJvdG8uQWdlbnRJ",
"bmZvc0VudHJ5EhQKDHNpZGVfY2hhbm5lbBgDIAEoDBpJChJMaXN0QWdlbnRJ",

10
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityToExternal.cs


// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_to_external.proto
// source: mlagents_envs/communicator_objects/unity_to_external.proto
// </auto-generated>
#pragma warning disable 1591, 0612, 3021
#region Designer generated code

using scg = global::System.Collections.Generic;
namespace MLAgents.CommunicatorObjects {
/// <summary>Holder for reflection information generated from mlagents/envs/communicator_objects/unity_to_external.proto</summary>
/// <summary>Holder for reflection information generated from mlagents_envs/communicator_objects/unity_to_external.proto</summary>
/// <summary>File descriptor for mlagents/envs/communicator_objects/unity_to_external.proto</summary>
/// <summary>File descriptor for mlagents_envs/communicator_objects/unity_to_external.proto</summary>
public static pbr::FileDescriptor Descriptor {
get { return descriptor; }
}

byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CjptbGFnZW50cy9lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Rv",
"CjptbGFnZW50c19lbnZzL2NvbW11bmljYXRvcl9vYmplY3RzL3VuaXR5X3Rv",
"dHMvZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy91bml0eV9tZXNzYWdlLnBy",
"dHNfZW52cy9jb21tdW5pY2F0b3Jfb2JqZWN0cy91bml0eV9tZXNzYWdlLnBy",
"b3RvMnYKFFVuaXR5VG9FeHRlcm5hbFByb3RvEl4KCEV4Y2hhbmdlEicuY29t",
"bXVuaWNhdG9yX29iamVjdHMuVW5pdHlNZXNzYWdlUHJvdG8aJy5jb21tdW5p",
"Y2F0b3Jfb2JqZWN0cy5Vbml0eU1lc3NhZ2VQcm90byIAQh+qAhxNTEFnZW50",

2
UnitySDK/Assets/ML-Agents/Scripts/Grpc/CommunicatorObjects/UnityToExternalGrpc.cs


#if UNITY_EDITOR || UNITY_STANDALONE_WIN || UNITY_STANDALONE_OSX || UNITY_STANDALONE_LINUX
// <auto-generated>
// Generated by the protocol buffer compiler. DO NOT EDIT!
// source: mlagents/envs/communicator_objects/unity_to_external.proto
// source: mlagents_envs/communicator_objects/unity_to_external.proto
// </auto-generated>
#pragma warning disable 0414, 1591
#region Designer generated code

6
docs/Basic-Guide.md


like this:
```console
INFO:mlagents.envs:
INFO:mlagents_envs:
INFO:mlagents.envs:Connected new brain:
INFO:mlagents_envs:Connected new brain:
Unity brain name: 3DBallLearning
Number of Visual Observations (per agent): 0
Vector Observation space size (per agent): 8

Vector Action descriptions: ,
INFO:mlagents.envs:Hyperparameters for the PPO Trainer of brain 3DBallLearning:
INFO:mlagents_envs:Hyperparameters for the PPO Trainer of brain 3DBallLearning:
batch_size: 64
beta: 0.001
buffer_size: 12000

8
docs/Learning-Environment-Executable.md


'file_name' of the `UnityEnvironment`. For instance:
```python
from mlagents.envs.environment import UnityEnvironment
from mlagents_envs.environment import UnityEnvironment
env = UnityEnvironment(file_name=<env_name>)
```

CrashReporter: initialized
Mono path[0] = '/Users/dericp/workspace/ml-agents/3DBall.app/Contents/Resources/Data/Managed'
Mono config path = '/Users/dericp/workspace/ml-agents/3DBall.app/Contents/MonoBleedingEdge/etc'
INFO:mlagents.envs:
INFO:mlagents_envs:
INFO:mlagents.envs:Connected new brain:
INFO:mlagents_envs:Connected new brain:
Unity brain name: Ball3DLearning
Number of Visual Observations (per agent): 0
Vector Observation space size (per agent): 8

Vector Action descriptions: ,
INFO:mlagents.envs:Hyperparameters for the PPO Trainer of brain Ball3DLearning:
INFO:mlagents_envs:Hyperparameters for the PPO Trainer of brain Ball3DLearning:
batch_size: 64
beta: 0.001
buffer_size: 12000

10
docs/Migrating.md


# Migrating
## Migrating from master to develop
## Migrating from 0.12 to latest
* `reset()` on the Low-Level Python API no longer takes a `train_mode` argument. To modify the performance/speed of the engine, you must use an `EngineConfigurationChannel`
* `reset()` on the Low-Level Python API no longer takes a `config` argument. `UnityEnvironment` no longer has a `reset_parameters` field. To modify float properties in the environment, you must use a `FloatPropertiesChannel`. For more information, refer to the [Low Level Python API documentation](Python-API.md)
* `reset()` on the Low-Level Python API no longer takes a `train_mode` argument. To modify the performance/speed of the engine, you must use an `EngineConfigurationChannel`
* `reset()` on the Low-Level Python API no longer takes a `config` argument. `UnityEnvironment` no longer has a `reset_parameters` field. To modify float properties in the environment, you must use a `FloatPropertiesChannel`. For more information, refer to the [Low Level Python API documentation](Python-API.md)
* `mlagents.envs` was renamed to `mlagents_envs`. The previous repo layout depended on [PEP420](https://www.python.org/dev/peps/pep-0420/), which caused problems with some of our tooling such as mypy and pylint.
* Any imports from `mlagents.envs` should be replaced with `mlagents_envs`.
## Migrating from ML-Agents toolkit v0.11.0 to v0.12.0

* `UnitySDK/Assets/ML-Agents/Scripts/Communicator.cs` and its class `Communicator` have been renamed to `UnitySDK/Assets/ML-Agents/Scripts/ICommunicator.cs` and `ICommunicator` respectively.
* The `SpaceType` Enums `discrete`, and `continuous` have been renamed to `Discrete` and `Continuous`.
* We have removed the `Done` call as well as the capacity to set `Max Steps` on the Academy. Therefore an AcademyReset will never be triggered from C# (only from Python). If you want to reset the simulation after a fixed number of steps, or when an event in the simulation occurs, we recommend looking at our multi-agent example environments (such as BananaCollector). In our examples, groups of Agents can be reset through an "Area" that can reset groups of Agents.
* The import for `mlagents.envs.UnityEnvironment` was removed. If you are using the Python API, change `from mlagents.envs import UnityEnvironment` to `from mlagents.envs.environment import UnityEnvironment`.
* The import for `mlagents.envs.UnityEnvironment` was removed. If you are using the Python API, change `from mlagents_envs import UnityEnvironment` to `from mlagents_envs.environment import UnityEnvironment`.
## Migrating from ML-Agents toolkit v0.8 to v0.9

22
docs/Python-API.md


# Unity ML-Agents Python Low Level API
The `mlagents` Python package contains two components: a low level API which
allows you to interact directly with a Unity Environment (`mlagents.envs`) and
allows you to interact directly with a Unity Environment (`mlagents_envs`) and
an entry point to train (`mlagents-learn`) which allows you to train agents in
Unity Environments using our implementations of reinforcement learning or
imitation learning.

## mlagents.envs
## mlagents_envs
The ML-Agents Toolkit Low Level API is a Python API for controlling the simulation
loop of an environment or game built with Unity. This API is used by the

- **AgentGroupSpec** — describes the shape of the data inside a BatchedStepResult.
For example, provides the dimensions of the observations of a group.
These classes are all defined in the [base_env](../ml-agents-envs/mlagents/envs/base_env.py)
These classes are all defined in the [base_env](../ml-agents-envs/mlagents_envs/base_env.py)
script.
An Agent Group is a group of Agents identified by a string name that share the same

## Loading a Unity Environment
Python-side communication happens through `UnityEnvironment` which is located in
`ml-agents/mlagents/envs`. To load a Unity environment from a built binary
file, put the file in the same directory as `envs`. For example, if the filename
of your Unity environment is 3DBall.app, in python, run:
[`environment.py`](../ml-agents-envs/mlagents_envs/environment.py). To load
a Unity environment from a built binary file, put the file in the same directory
as `envs`. For example, if the filename of your Unity environment is 3DBall.app, in python, run:
from mlagents.envs.environment import UnityEnvironment
from mlagents_envs.environment import UnityEnvironment
env = UnityEnvironment(file_name="3DBall", base_port=5005, seed=1, side_channels=[])
```

For example :
```python
from mlagents.envs.environment import UnityEnvironment
from mlagents.envs.side_channel.engine_configuration_channel import EngineConfigurationChannel
from mlagents_envs.environment import UnityEnvironment
from mlagents_envs.side_channel.engine_configuration_channel import EngineConfigurationChannel
channel = EngineConfigurationChannel()

* `list_properties` Returns a list of all the string identifiers of the properties
```python
from mlagents.envs.environment import UnityEnvironment
from mlagents.envs.side_channel.float_properties_channel import FloatPropertiesChannel
from mlagents_envs.environment import UnityEnvironment
from mlagents_envs.side_channel.float_properties_channel import FloatPropertiesChannel
channel = FloatPropertiesChannel()

2
docs/Training-Generalized-Reinforcement-Learning-Agents.md


* **sub-arguments** - `intervals`
The implementation of the samplers can be found at `ml-agents-envs/mlagents/envs/sampler_class.py`.
The implementation of the samplers can be found at `ml-agents-envs/mlagents_envs/sampler_class.py`.
### Defining a New Sampler Type

10
docs/Training-on-Amazon-Web-Service.md


9. Test the instance setup from Python using:
```python
from mlagents.envs.environment import UnityEnvironment
from mlagents_envs.environment import UnityEnvironment
env = UnityEnvironment(<your_env>)
```

Logging to /home/ubuntu/.config/unity3d/<Some_Path>/Player.log
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/ubuntu/ml-agents/ml-agents/mlagents/envs/environment.py", line 63, in __init__
File "/home/ubuntu/ml-agents/ml-agents/mlagents_envs/environment.py", line 63, in __init__
File "/home/ubuntu/ml-agents/ml-agents/mlagents/envs/environment.py", line 489, in send_academy_parameters
File "/home/ubuntu/ml-agents/ml-agents/mlagents_envs/environment.py", line 489, in send_academy_parameters
File "/home/ubuntu/ml-agents/ml-agents/mlagents/envs/rpc_communicator.py", line 60, in initialize
mlagents.envs.exception.UnityTimeOutException: The Unity environment took too long to respond. Make sure that :
File "/home/ubuntu/ml-agents/ml-agents/mlagents_envs/rpc_communicator.py", line 60, in initialize
mlagents_envs.exception.UnityTimeOutException: The Unity environment took too long to respond. Make sure that :
The environment does not need user interaction to launch
The environment and the Python interface have compatible versions.
```

2
docs/Training-on-Microsoft-Azure.md


7. Test the instance setup from Python using:
```python
from mlagents.envs.environment import UnityEnvironment
from mlagents_envs.environment import UnityEnvironment
env = UnityEnvironment(<your_env>)
```

2
gym-unity/gym_unity/__init__.py


__version__ = "0.12.0"
__version__ = "0.12.1"

2
gym-unity/gym_unity/envs/__init__.py


import itertools
import gym
import numpy as np
from mlagents.envs.environment import UnityEnvironment
from mlagents_envs.environment import UnityEnvironment
from gym import error, spaces

2
gym-unity/gym_unity/tests/test_gym.py


from gym import spaces
from gym_unity.envs import UnityEnv, UnityGymException
from mlagents.envs.base_env import AgentGroupSpec, ActionType, BatchedStepResult
from mlagents_envs.base_env import AgentGroupSpec, ActionType, BatchedStepResult
@mock.patch("gym_unity.envs.UnityEnvironment")

2
ml-agents-envs/README.md


The `mlagents_envs` Python package contains one sub package:
* `mlagents.envs`: A low level API which allows you to interact directly with a
* `mlagents_envs`: A low level API which allows you to interact directly with a
Unity Environment. See
[here](https://github.com/Unity-Technologies/ml-agents/blob/master/docs/Python-API.md)
for more information on using this package.

8
ml-agents-envs/setup.py


import os
import sys
from setuptools import setup
from setuptools import setup, find_packages
import mlagents.envs
import mlagents_envs
VERSION = mlagents.envs.__version__
VERSION = mlagents_envs.__version__
here = os.path.abspath(os.path.dirname(__file__))

"Programming Language :: Python :: 3.6",
"Programming Language :: Python :: 3.7",
],
packages=["mlagents.envs", "mlagents.envs.communicator_objects"], # Required
packages=find_packages(exclude=["*.tests", "*.tests.*", "tests.*", "tests"]),
zip_safe=False,
install_requires=[
"cloudpickle",

2
ml-agents/README.md


The `mlagents` Python package contains two sub packages:
* `mlagents.envs`: A low level API which allows you to interact directly with a
* `mlagents_envs`: A low level API which allows you to interact directly with a
Unity Environment. See
[here](https://github.com/Unity-Technologies/ml-agents/blob/master/docs/Python-API.md)
for more information on using this package.

2
ml-agents/mlagents/trainers/__init__.py


__version__ = "0.12.0"
__version__ = "0.12.1"

10
ml-agents/mlagents/trainers/brain.py


import numpy as np
import io
from mlagents.envs.communicator_objects.agent_info_pb2 import AgentInfoProto
from mlagents.envs.communicator_objects.brain_parameters_pb2 import BrainParametersProto
from mlagents.envs.communicator_objects.observation_pb2 import ObservationProto
from mlagents.envs.timers import hierarchical_timer, timed
from mlagents_envs.communicator_objects.agent_info_pb2 import AgentInfoProto
from mlagents_envs.communicator_objects.brain_parameters_pb2 import BrainParametersProto
from mlagents_envs.communicator_objects.observation_pb2 import ObservationProto
from mlagents_envs.timers import hierarchical_timer, timed
logger = logging.getLogger("mlagents.envs")
logger = logging.getLogger("mlagents.trainers")
class CameraResolution(NamedTuple):

4
ml-agents/mlagents/trainers/brain_conversion_utils.py


from mlagents.trainers.brain import BrainInfo, BrainParameters, CameraResolution
from mlagents.envs.base_env import BatchedStepResult, AgentGroupSpec
from mlagents.envs.exception import UnityEnvironmentException
from mlagents_envs.base_env import BatchedStepResult, AgentGroupSpec
from mlagents_envs.exception import UnityEnvironmentException
import numpy as np
from typing import List

2
ml-agents/mlagents/trainers/buffer.py


import h5py
from typing import List, BinaryIO
from mlagents.envs.exception import UnityException
from mlagents_envs.exception import UnityException
class BufferException(UnityException):

8
ml-agents/mlagents/trainers/demo_loader.py


import numpy as np
from mlagents.trainers.buffer import AgentBuffer
from mlagents.trainers.brain import BrainParameters, BrainInfo
from mlagents.envs.communicator_objects.agent_info_action_pair_pb2 import (
from mlagents_envs.communicator_objects.agent_info_action_pair_pb2 import (
from mlagents.envs.communicator_objects.brain_parameters_pb2 import BrainParametersProto
from mlagents.envs.communicator_objects.demonstration_meta_pb2 import (
from mlagents_envs.communicator_objects.brain_parameters_pb2 import BrainParametersProto
from mlagents_envs.communicator_objects.demonstration_meta_pb2 import (
from mlagents.envs.timers import timed, hierarchical_timer
from mlagents_envs.timers import timed, hierarchical_timer
from google.protobuf.internal.decoder import _DecodeVarint32 # type: ignore

5
ml-agents/mlagents/trainers/env_manager.py


brain_name_to_action_info: Dict[str, ActionInfo]
def has_actions_for_brain(self, brain_name: str) -> bool:
return (
brain_name in self.brain_name_to_action_info
and self.brain_name_to_action_info[brain_name].outputs is not None
return brain_name in self.brain_name_to_action_info and bool(
self.brain_name_to_action_info[brain_name].outputs
)

8
ml-agents/mlagents/trainers/exception.py


pass
class TrainerConfigError(Exception):
"""
Any error related to the configuration of trainers in the ML-Agents Toolkit.
"""
pass
class CurriculumError(TrainerError):
"""
Any error related to training with a curriculum.

14
ml-agents/mlagents/trainers/learn.py


from typing import Any, Callable, Optional, List, NamedTuple
import mlagents.trainers
import mlagents.envs
import mlagents_envs
from mlagents import tf_utils
from mlagents.trainers.trainer_controller import TrainerController
from mlagents.trainers.exception import TrainerError

from mlagents.envs.environment import UnityEnvironment
from mlagents_envs.environment import UnityEnvironment
from mlagents.envs.base_env import BaseEnv
from mlagents_envs.base_env import BaseEnv
from mlagents.envs.side_channel.side_channel import SideChannel
from mlagents.envs.side_channel.engine_configuration_channel import EngineConfig
from mlagents_envs.side_channel.side_channel import SideChannel
from mlagents_envs.side_channel.engine_configuration_channel import EngineConfig
class CommandLineOptions(NamedTuple):

# pylint: disable=no-member
return f""" Version information:
ml-agents: {mlagents.trainers.__version__},
ml-agents-envs: {mlagents.envs.__version__},
ml-agents-envs: {mlagents_envs.__version__},
Communicator API: {UnityEnvironment.API_VERSION},
TensorFlow: {tf_utils.tf.__version__}"""

print(get_version_string())
options = parse_command_line()
trainer_logger = logging.getLogger("mlagents.trainers")
env_logger = logging.getLogger("mlagents.envs")
env_logger = logging.getLogger("mlagents_envs")
trainer_logger.info(options)
if options.debug:
trainer_logger.setLevel("DEBUG")

11
ml-agents/mlagents/trainers/meta_curriculum.py


try:
for curriculum_filename in os.listdir(curriculum_folder):
# This process requires JSON files
if not curriculum_filename.lower().endswith(".json"):
brain_name, extension = os.path.splitext(curriculum_filename)
if extension.lower() != ".json":
brain_name = curriculum_filename.split(".")[0]
curriculum_filepath = os.path.join(
curriculum_folder, curriculum_filename
)

for brain_name, lesson in lesson_nums.items():
self.brains_to_curriculums[brain_name].lesson_num = lesson
def _lesson_ready_to_increment(self, brain_name, reward_buff_size):
def _lesson_ready_to_increment(
self, brain_name: str, reward_buff_size: int
) -> bool:
"""Determines whether the curriculum of a specified brain is ready
to attempt an increment.

Whether the curriculum of the specified brain should attempt to
increment its lesson.
"""
if brain_name not in self.brains_to_curriculums:
return False
return reward_buff_size >= (
self.brains_to_curriculums[brain_name].min_lesson_length
)

2
ml-agents/mlagents/trainers/ppo/multi_gpu_policy.py


from tensorflow.python.client import device_lib
from mlagents.trainers.brain import BrainParameters
from mlagents.envs.timers import timed
from mlagents_envs.timers import timed
from mlagents.trainers.models import EncoderType, LearningRateSchedule
from mlagents.trainers.ppo.policy import PPOPolicy
from mlagents.trainers.ppo.models import PPOModel

2
ml-agents/mlagents/trainers/ppo/policy.py


from mlagents.tf_utils import tf
from mlagents.envs.timers import timed
from mlagents_envs.timers import timed
from mlagents.trainers.brain import BrainParameters
from mlagents.trainers.models import EncoderType, LearningRateSchedule
from mlagents.trainers.ppo.models import PPOModel

2
ml-agents/mlagents/trainers/sac/policy.py


import numpy as np
from mlagents.tf_utils import tf
from mlagents.envs.timers import timed
from mlagents_envs.timers import timed
from mlagents.trainers.brain import BrainInfo, BrainParameters
from mlagents.trainers.models import EncoderType, LearningRateSchedule
from mlagents.trainers.sac.models import SACModel

2
ml-agents/mlagents/trainers/sac/trainer.py


import numpy as np
from mlagents.envs.timers import timed
from mlagents_envs.timers import timed
from mlagents.trainers.sac.policy import SACPolicy
from mlagents.trainers.rl_trainer import RLTrainer
from mlagents.trainers.trajectory import Trajectory, SplitObservations

6
ml-agents/mlagents/trainers/simple_env_manager.py


from typing import Dict, List
from mlagents.envs.base_env import BaseEnv
from mlagents_envs.base_env import BaseEnv
from mlagents.envs.timers import timed
from mlagents_envs.timers import timed
from mlagents.envs.side_channel.float_properties_channel import FloatPropertiesChannel
from mlagents_envs.side_channel.float_properties_channel import FloatPropertiesChannel
from mlagents.trainers.brain_conversion_utils import (
step_result_to_brain_info,
group_spec_to_brain_parameters,

16
ml-agents/mlagents/trainers/subprocess_env_manager.py


from typing import Dict, NamedTuple, List, Any, Optional, Callable, Set
import cloudpickle
from mlagents.envs.environment import UnityEnvironment
from mlagents.envs.exception import UnityCommunicationException, UnityTimeOutException
from mlagents_envs.environment import UnityEnvironment
from mlagents_envs.exception import UnityCommunicationException, UnityTimeOutException
from mlagents.envs.base_env import BaseEnv
from mlagents_envs.base_env import BaseEnv
from mlagents.envs.timers import (
from mlagents_envs.timers import (
TimerNode,
timed,
hierarchical_timer,

from mlagents.trainers.brain import AllBrainInfo, BrainParameters
from mlagents.trainers.action_info import ActionInfo
from mlagents.envs.side_channel.float_properties_channel import FloatPropertiesChannel
from mlagents.envs.side_channel.engine_configuration_channel import (
from mlagents_envs.side_channel.float_properties_channel import FloatPropertiesChannel
from mlagents_envs.side_channel.engine_configuration_channel import (
from mlagents.envs.side_channel.side_channel import SideChannel
from mlagents_envs.side_channel.side_channel import SideChannel
logger = logging.getLogger("mlagents.envs")
logger = logging.getLogger("mlagents.trainers")
class EnvironmentCommand(NamedTuple):

12
ml-agents/mlagents/trainers/tests/test_bcmodule.py


# Test default values
@mock.patch("mlagents.envs.environment.UnityEnvironment")
@mock.patch("mlagents_envs.environment.UnityEnvironment")
def test_bcmodule_defaults(mock_env):
# See if default values match
mock_brain = mb.create_mock_3dball_brain()

@pytest.mark.parametrize(
"trainer_config", [ppo_dummy_config(), sac_dummy_config()], ids=["ppo", "sac"]
)
@mock.patch("mlagents.envs.environment.UnityEnvironment")
@mock.patch("mlagents_envs.environment.UnityEnvironment")
def test_bcmodule_update(mock_env, trainer_config):
mock_brain = mb.create_mock_3dball_brain()
env, policy = create_policy_with_bc_mock(

@pytest.mark.parametrize(
"trainer_config", [ppo_dummy_config(), sac_dummy_config()], ids=["ppo", "sac"]
)
@mock.patch("mlagents.envs.environment.UnityEnvironment")
@mock.patch("mlagents_envs.environment.UnityEnvironment")
def test_bcmodule_constant_lr_update(mock_env, trainer_config):
mock_brain = mb.create_mock_3dball_brain()
trainer_config["behavioral_cloning"]["steps"] = 0

@pytest.mark.parametrize(
"trainer_config", [ppo_dummy_config(), sac_dummy_config()], ids=["ppo", "sac"]
)
@mock.patch("mlagents.envs.environment.UnityEnvironment")
@mock.patch("mlagents_envs.environment.UnityEnvironment")
def test_bcmodule_rnn_update(mock_env, trainer_config):
mock_brain = mb.create_mock_3dball_brain()
env, policy = create_policy_with_bc_mock(

@pytest.mark.parametrize(
"trainer_config", [ppo_dummy_config(), sac_dummy_config()], ids=["ppo", "sac"]
)
@mock.patch("mlagents.envs.environment.UnityEnvironment")
@mock.patch("mlagents_envs.environment.UnityEnvironment")
def test_bcmodule_dc_visual_update(mock_env, trainer_config):
mock_brain = mb.create_mock_banana_brain()
env, policy = create_policy_with_bc_mock(

@pytest.mark.parametrize(
"trainer_config", [ppo_dummy_config(), sac_dummy_config()], ids=["ppo", "sac"]
)
@mock.patch("mlagents.envs.environment.UnityEnvironment")
@mock.patch("mlagents_envs.environment.UnityEnvironment")
def test_bcmodule_rnn_dc_update(mock_env, trainer_config):
mock_brain = mb.create_mock_banana_brain()
env, policy = create_policy_with_bc_mock(

1
ml-agents/mlagents/trainers/tests/test_curriculum.py


from mlagents.trainers.exception import CurriculumConfigError, CurriculumLoadingError
from mlagents.trainers.curriculum import Curriculum
dummy_curriculum_json_str = """
{
"measure" : "reward",

53
ml-agents/mlagents/trainers/tests/test_meta_curriculum.py


import pytest
from unittest.mock import patch, call
from unittest.mock import patch, call, mock_open
from mlagents.trainers.curriculum import Curriculum
from mlagents.trainers.tests.test_simple_rl import (
Simple1DEnvironment,
_check_environment_trains,
BRAIN_NAME,
)
from mlagents.trainers.tests.test_curriculum import dummy_curriculum_json_str
class MetaCurriculumTest(MetaCurriculum):

@patch("mlagents.trainers.curriculum.Curriculum.get_config", return_value={})
@patch("mlagents.trainers.curriculum.Curriculum.__init__", return_value=None)
@patch("os.listdir", return_value=["Brain1.json", "Brain2.json"])
@patch("os.listdir", return_value=["Brain1.json", "Brain2.test.json"])
def test_init_meta_curriculum_happy_path(
listdir, mock_curriculum_init, mock_curriculum_get_config, default_reset_parameters
):

assert "Brain1" in meta_curriculum.brains_to_curriculums
assert "Brain2" in meta_curriculum.brains_to_curriculums
assert "Brain2.test" in meta_curriculum.brains_to_curriculums
calls = [call("test/Brain1.json"), call("test/Brain2.json")]
calls = [call("test/Brain1.json"), call("test/Brain2.test.json")]
mock_curriculum_init.assert_has_calls(calls)

new_reset_parameters.update(more_reset_parameters)
assert meta_curriculum.get_config() == new_reset_parameters
META_CURRICULUM_CONFIG = """
default: