浏览代码

Release 0.12.1 doc fixes (#3070)

/tag-0.12.1
GitHub 4 年前
当前提交
f8621d4d
共有 6 个文件被更改,包括 286 次插入6 次删除
  1. 21
      docs/Installation.md
  2. 3
      docs/Learning-Environment-Create-New.md
  3. 1
      docs/Migrating.md
  4. 6
      docs/Training-ML-Agents.md
  5. 2
      gym-unity/README.md
  6. 259
      docs/images/barracuda-package.png

21
docs/Installation.md


It also contains many [example environments](Learning-Environment-Examples.md)
to help you get started.
### Package Installation
If you intend to copy the `UnitySDK` folder in to your project, ensure that
you have the [Barracuda preview package](https://docs.unity3d.com/Packages/com.unity.barracuda@0.3/manual/index.html) installed.
To install the Barracuda package in Unity **2017.4.x**, you will have to copy the
`UnityPackageManager` folder under the `UnitySDK` folder to the root directory of your
project.
To install the Barrcuda package in later versions of Unity, navigate to the Package
Manager window by navigating to the menu `Window` -> `Package Manager`. Click on the
`Adavanced` dropdown menu to the left of the search bar and make sure "Show Preview Packages"
is checked. Search for or select the `Barracuda` package and install the latest version.
<p align="center">
<img src="images/barracuda-package.png"
alt="Barracuda Package Manager"
width="710" border="10"
height="569" />
</p>
The `ml-agents` subdirectory contains a Python package which provides deep reinforcement
learning trainers to use with Unity environments.

3
docs/Learning-Environment-Create-New.md


calculate the rewards used for reinforcement training. You can also implement
optional methods to reset the Agent when it has finished or failed its task.
4. Add your Agent subclasses to appropriate GameObjects, typically, the object
in the scene that represents the Agent in the simulation. Each Agent object
must be assigned a Brain object.
in the scene that represents the Agent in the simulation.
**Note:** If you are unfamiliar with Unity, refer to
[Learning the interface](https://docs.unity3d.com/Manual/LearningtheInterface.html)

1
docs/Migrating.md


* If you use RayPerception3D, replace it with RayPerceptionSensorComponent3D (and similarly for 2D). The settings, such as ray angles and detectable tags, are configured on the component now.
RayPerception3D would contribute `(# of rays) * (# of tags + 2)` to the State Size in Behavior Parameters, but this is no longer necessary, so you should reduce the State Size by this amount.
Making this change will require retraining your model, since the observations that RayPerceptionSensorComponent3D produces are different from the old behavior.
* If you see messages such as `The type or namespace 'Barracuda' could not be found` or `The type or namespace 'Google' could not be found`, you will need to [install the Barracuda preview package](Installation.md#package-installation).
## Migrating from ML-Agents toolkit v0.10 to v0.11.0

6
docs/Training-ML-Agents.md


The output of the training process is a model file containing the optimized
policy. This model file is a TensorFlow data graph containing the mathematical
operations and the optimized weights selected during the training process. You
can use the generated model file with the Learning Brain type in your Unity
project to decide the best course of action for an agent.
can set the generated model file in the Behaviors Parameters under your
Agent in your Unity project to decide the best course of action for an agent.
Use the command `mlagents-learn` to train your agents. This command is installed
with the `mlagents` package and its implementation can be found at

each Brain.
each Behavior.
For a broader overview of reinforcement learning, imitation learning and the
ML-Agents training process, see [ML-Agents Toolkit

2
gym-unity/README.md


from baselines import deepq
from baselines import logger
from gym_unity.envs.unity_env import UnityEnv
from gym_unity.envs import UnityEnv
def main():
env = UnityEnv("./envs/GridWorld", 0, use_visual=True, uint8_visual=True)

259
docs/images/barracuda-package.png

之前 之后
宽度: 701  |  高度: 569  |  大小: 79 KiB
正在加载...
取消
保存