浏览代码

fix all the places that used v0.3 and should be fixed, also updated t… (#863)

* fix all the places that used v0.3 and should be fixed, also updated the migration doc

* resolved the comment
/develop-generalizationTraining-TrainerController
GitHub 7 年前
当前提交
758c611a
共有 8 个文件被更改,包括 44 次插入39 次删除
  1. 4
      README.md
  2. 4
      docs/Installation-Windows.md
  3. 2
      docs/Readme.md
  4. 2
      docs/dox-ml-agents.conf
  5. 2
      docs/localized/zh-CN/README.md
  6. 2
      docs/localized/zh-CN/docs/Readme.md
  7. 36
      docs/Migrating.md
  8. 31
      docs/Migrating-v0.3.md

4
README.md


* For more information, in addition to installation and usage
instructions, see our [documentation home](docs/Readme.md).
* If you have
used a version of ML-Agents prior to v0.3, we strongly recommend
our [guide on migrating to v0.3](docs/Migrating-v0.3.md).
used a version of ML-Agents prior to v0.4, we strongly recommend
our [guide on migrating from earlier versions](docs/Migrating.md).
## References

4
docs/Installation-Windows.md


ML-Agents supports Windows 10. While it might be possible to run ML-Agents using other versions of Windows, it has not been tested on other versions. Furthermore, ML-Agents has not been tested on a Windows VM such as Bootcamp or Parallels.
To use ML-Agents, you install Python and the required Python packages as outlined below. This guide also covers how set up GPU-based training (for advanced users). GPU-based training is not required for the v0.3 release of ML-Agents. However, training on a GPU might be required by future versions and features.
To use ML-Agents, you install Python and the required Python packages as outlined below. This guide also covers how set up GPU-based training (for advanced users). GPU-based training is not required for the v0.4 release of ML-Agents. However, training on a GPU might be required by future versions and features.
## Step 1: Install Python via Anaconda

GPU is not required for ML-Agents and won't speed up the PPO algorithm a lot during training(but something in the future will benefit from GPU). This is a guide for advanced users who want to train using GPUs. Additionally, you will need to check if your GPU is CUDA compatible. Please check Nvidia's page [here](https://developer.nvidia.com/cuda-gpus).
As of ML-Agents v0.3, only CUDA v9.0 and cuDNN v7.0.5 is supported.
As of ML-Agents v0.4, only CUDA v9.0 and cuDNN v7.0.5 is supported.
### Install Nvidia CUDA toolkit

2
docs/Readme.md


* [Using TensorBoard to Observe Training](Using-Tensorboard.md)
## Help
* [Migrating to ML-Agents v0.3](Migrating-v0.3.md)
* [Migrating from earlier versions of ML-Agents](Migrating.md)
* [Frequently Asked Questions](FAQ.md)
* [ML-Agents Glossary](Glossary.md)
* [Limitations](Limitations.md)

2
docs/dox-ml-agents.conf


# could be handy for archiving the generated documentation or if some version
# control system is used.
PROJECT_NUMBER = v0.3
PROJECT_NUMBER = v0.4
# Using the PROJECT_BRIEF tag one can provide an optional one line description
# for a project that appears at the top of each page and should give viewer a

2
docs/localized/zh-CN/README.md


**除了安装和使用说明外,如需更多信息,
请参阅我们的[文档主页](docs/Readme.md)。**如果您使用的
是 v0.3 之前的 ML-Agents 版本,强烈建议您参考
我们的[关于迁移到 v0.3 的指南](/docs/Migrating-v0.3.md)。
我们的[关于迁移到 v0.3 的指南](/docs/Migrating.md)。
我们还发布了一系列与 ML-Agents 相关的博客文章:
- reinforcement learning(强化学习)概念概述

2
docs/localized/zh-CN/docs/Readme.md


* [如何使用 TensorBoard 观察训练过程](/docs/Using-Tensorboard.md)
## 帮助
* [如何从老版本升级到 ML-Agents v0.3](/docs/Migrating-v0.3.md)
* [如何从老版本升级到 ML-Agents v0.3](/docs/Migrating.md)
* [常见问题](/docs/FAQ.md)
* [ML-Agents 术语表](/docs/Glossary.md)
* [ML-Agents 尚未实现功能](/docs/Limitations.md)

36
docs/Migrating.md


# Migrating from ML-Agents v0.3 to ML-Agents v0.4
## Unity API
* `using MLAgents;` needs to be added in all of the C# scripts that use ML-Agents.
# Migrating from ML-Agents v0.2 to ML-Agents v0.3
There are a large number of new features and improvements in ML-Agents v0.3 which change both the training process and Unity API in ways which will cause incompatibilities with environments made using older versions. This page is designed to highlight those changes for users familiar with v0.1 or v0.2 in order to ensure a smooth transition.
## Important
* ML-Agents is no longer compatible with Python 2.
## Python Training
* The training script `ppo.py` and `PPO.ipynb` Python notebook have been replaced with a single `learn.py` script as the launching point for training with ML-Agents. For more information on using `learn.py`, see [here]().
* Hyperparameters for training brains are now stored in the `trainer_config.yaml` file. For more information on using this file, see [here]().
## Unity API
* Modifications to an Agent's rewards must now be done using either `AddReward()` or `SetReward()`.
* Setting an Agent to done now requires the use of the `Done()` method.
* `CollectStates()` has been replaced by `CollectObservations()`, which now no longer returns a list of floats.
* To collect observations, call `AddVectorObs()` within `CollectObservations()`. Note that you can call `AddVectorObs()` with floats, integers, lists and arrays of floats, Vector3 and Quaternions.
* `AgentStep()` has been replaced by `AgentAction()`.
* `WaitTime()` has been removed.
* The `Frame Skip` field of the Academy is replaced by the Agent's `Decision Frequency` field, enabling agent to make decisions at different frequencies.
* The names of the inputs in the Internal Brain have been changed. You must replace `state` with `vector_observation` and `observation` with `visual_observation`. In addition, you must remove the `epsilon` placeholder.
## Semantics
In order to more closely align with the terminology used in the Reinforcement Learning field, and to be more descriptive, we have changed the names of some of the concepts used in ML-Agents. The changes are highlighted in the table below.
| Old - v0.2 and earlier | New - v0.3 and later |
| --- | --- |
| State | Vector Observation |
| Observation | Visual Observation |
| Action | Vector Action |
| N/A | Text Observation |
| N/A | Text Action |

31
docs/Migrating-v0.3.md


# Migrating to ML-Agents v0.3
There are a large number of new features and improvements in ML-Agents v0.3 which change both the training process and Unity API in ways which will cause incompatibilities with environments made using older versions. This page is designed to highlight those changes for users familiar with v0.1 or v0.2 in order to ensure a smooth transition.
## Important
* ML-Agents is no longer compatible with Python 2.
## Python Training
* The training script `ppo.py` and `PPO.ipynb` Python notebook have been replaced with a single `learn.py` script as the launching point for training with ML-Agents. For more information on using `learn.py`, see [here]().
* Hyperparameters for training brains are now stored in the `trainer_config.yaml` file. For more information on using this file, see [here]().
## Unity API
* Modifications to an Agent's rewards must now be done using either `AddReward()` or `SetReward()`.
* Setting an Agent to done now requires the use of the `Done()` method.
* `CollectStates()` has been replaced by `CollectObservations()`, which now no longer returns a list of floats.
* To collect observations, call `AddVectorObs()` within `CollectObservations()`. Note that you can call `AddVectorObs()` with floats, integers, lists and arrays of floats, Vector3 and Quaternions.
* `AgentStep()` has been replaced by `AgentAction()`.
* `WaitTime()` has been removed.
* The `Frame Skip` field of the Academy is replaced by the Agent's `Decision Frequency` field, enabling agent to make decisions at different frequencies.
* The names of the inputs in the Internal Brain have been changed. You must replace `state` with `vector_observation` and `observation` with `visual_observation`. In addition, you must remove the `epsilon` placeholder.
## Semantics
In order to more closely align with the terminology used in the Reinforcement Learning field, and to be more descriptive, we have changed the names of some of the concepts used in ML-Agents. The changes are highlighted in the table below.
| Old - v0.2 and earlier | New - v0.3 and later |
| --- | --- |
| State | Vector Observation |
| Observation | Visual Observation |
| Action | Vector Action |
| N/A | Text Observation |
| N/A | Text Action |
正在加载...
取消
保存