Skip to content

Commit e8393d5

Browse files
shihzyawjuliani
authored andcommitted
Documentation 0.5 Release Check List (Part 1) (Unity-Technologies#1154)
1 parent a4e7140 commit e8393d5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+775
-717
lines changed

CODE_OF_CONDUCT.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,8 @@ members of the project's leadership.
6767

6868
## Attribution
6969

70-
This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71-
available at https://www.contributor-covenant.org/version/1/4/code-of-conduct/
70+
This Code of Conduct is adapted from the [Contributor Covenant][homepage],
71+
version 1.4, available at
72+
https://www.contributor-covenant.org/version/1/4/code-of-conduct/
7273

7374
[homepage]: https://www.contributor-covenant.org

CONTRIBUTING.md

Lines changed: 31 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -1,54 +1,56 @@
11
# Contribution Guidelines
22

3-
Thank you for your interest in contributing to the ML-Agents toolkit! We are incredibly
4-
excited to see how members of our community will use and extend the ML-Agents toolkit.
5-
To facilitate your contributions, we've outlined a brief set of guidelines
6-
to ensure that your extensions can be easily integrated.
3+
Thank you for your interest in contributing to the ML-Agents toolkit! We are
4+
incredibly excited to see how members of our community will use and extend the
5+
ML-Agents toolkit. To facilitate your contributions, we've outlined a brief set
6+
of guidelines to ensure that your extensions can be easily integrated.
77

8-
### Communication
8+
## Communication
99

10-
First, please read through our [code of conduct](CODE_OF_CONDUCT.md),
11-
as we expect all our contributors to follow it.
10+
First, please read through our [code of conduct](CODE_OF_CONDUCT.md), as we
11+
expect all our contributors to follow it.
1212

13-
Second, before starting on a project that you intend to contribute
14-
to the ML-Agents toolkit (whether environments or modifications to the codebase),
15-
we **strongly** recommend posting on our
16-
[Issues page](https://github.com/Unity-Technologies/ml-agents/issues) and
17-
briefly outlining the changes you plan to make. This will enable us to provide
18-
some context that may be helpful for you. This could range from advice and
19-
feedback on how to optimally perform your changes or reasons for not doing it.
13+
Second, before starting on a project that you intend to contribute to the
14+
ML-Agents toolkit (whether environments or modifications to the codebase), we
15+
**strongly** recommend posting on our
16+
[Issues page](https://github.com/Unity-Technologies/ml-agents/issues)
17+
and briefly outlining the changes you plan to make. This will enable us to
18+
provide some context that may be helpful for you. This could range from advice
19+
and feedback on how to optimally perform your changes or reasons for not doing
20+
it.
2021

2122
Lastly, if you're looking for input on what to contribute, feel free to
2223
reach out to us directly at [email protected] and/or browse the GitHub
2324
issues with the `contributions welcome` label.
2425

25-
### Git Branches
26+
## Git Branches
2627

27-
Starting with v0.3, we adopted the
28+
Starting with v0.3, we adopted the
2829
[Gitflow Workflow](http://nvie.com/posts/a-successful-git-branching-model/).
29-
Consequently, the `master` branch corresponds to the latest release of
30+
Consequently, the `master` branch corresponds to the latest release of
3031
the project, while the `develop` branch corresponds to the most recent, stable,
3132
version of the project.
3233

3334
Thus, when adding to the project, **please branch off `develop`**
3435
and make sure that your Pull Request (PR) contains the following:
36+
3537
* Detailed description of the changes performed
36-
* Corresponding changes to documentation, unit tests and sample environments
37-
(if applicable)
38+
* Corresponding changes to documentation, unit tests and sample environments (if
39+
applicable)
3840
* Summary of the tests performed to validate your changes
3941
* Issue numbers that the PR resolves (if any)
4042

41-
### Environments
43+
## Environments
4244

43-
We are also actively open to adding community contributed environments as
44-
examples, as long as they are small, simple, demonstrate a unique feature of
45-
the platform, and provide a unique non-trivial challenge to modern
45+
We are also actively open to adding community contributed environments as
46+
examples, as long as they are small, simple, demonstrate a unique feature of
47+
the platform, and provide a unique non-trivial challenge to modern
4648
machine learning algorithms. Feel free to submit these environments with a
47-
PR explaining the nature of the environment and task.
49+
PR explaining the nature of the environment and task.
4850

49-
### Style Guide
51+
## Style Guide
5052

51-
When performing changes to the codebase, ensure that you follow the style
52-
guide of the file you're modifying. For Python, we follow
53-
[PEP 8](https://www.python.org/dev/peps/pep-0008/). For C#, we will soon be
54-
adding a formal style guide for our repository.
53+
When performing changes to the codebase, ensure that you follow the style guide
54+
of the file you're modifying. For Python, we follow
55+
[PEP 8](https://www.python.org/dev/peps/pep-0008/).
56+
For C#, we will soon be adding a formal style guide for our repository.

MLAgentsSDK/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
# ML-Agents SDK

README.md

Lines changed: 50 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -4,75 +4,81 @@
44

55
# Unity ML-Agents Toolkit (Beta)
66

7-
**The Unity Machine Learning Agents Toolkit** (ML-Agents) is an open-source Unity plugin
8-
that enables games and simulations to serve as environments for training
9-
intelligent agents. Agents can be trained using reinforcement learning,
10-
imitation learning, neuroevolution, or other machine learning methods through
11-
a simple-to-use Python API. We also provide implementations (based on
12-
TensorFlow) of state-of-the-art algorithms to enable game developers
13-
and hobbyists to easily train intelligent agents for 2D, 3D and VR/AR games.
14-
These trained agents can be used for multiple purposes, including
15-
controlling NPC behavior (in a variety of settings such as multi-agent and
16-
adversarial), automated testing of game builds and evaluating different game
17-
design decisions pre-release. The ML-Agents toolkit is mutually beneficial for both game
18-
developers and AI researchers as it provides a central platform where advances
19-
in AI can be evaluated on Unity’s rich environments and then made accessible
20-
to the wider research and game developer communities.
7+
**The Unity Machine Learning Agents Toolkit** (ML-Agents) is an open-source
8+
Unity plugin that enables games and simulations to serve as environments for
9+
training intelligent agents. Agents can be trained using reinforcement learning,
10+
imitation learning, neuroevolution, or other machine learning methods through a
11+
simple-to-use Python API. We also provide implementations (based on TensorFlow)
12+
of state-of-the-art algorithms to enable game developers and hobbyists to easily
13+
train intelligent agents for 2D, 3D and VR/AR games. These trained agents can be
14+
used for multiple purposes, including controlling NPC behavior (in a variety of
15+
settings such as multi-agent and adversarial), automated testing of game builds
16+
and evaluating different game design decisions pre-release. The ML-Agents
17+
toolkit is mutually beneficial for both game developers and AI researchers as it
18+
provides a central platform where advances in AI can be evaluated on Unity’s
19+
rich environments and then made accessible to the wider research and game
20+
developer communities.
2121

2222
## Features
23+
2324
* Unity environment control from Python
2425
* 10+ sample Unity environments
2526
* Support for multiple environment configurations and training scenarios
26-
* Train memory-enhanced Agents using deep reinforcement learning
27+
* Train memory-enhanced agents using deep reinforcement learning
2728
* Easily definable Curriculum Learning scenarios
28-
* Broadcasting of Agent behavior for supervised learning
29+
* Broadcasting of agent behavior for supervised learning
2930
* Built-in support for Imitation Learning
30-
* Flexible Agent control with On Demand Decision Making
31+
* Flexible agent control with On Demand Decision Making
3132
* Visualizing network outputs within the environment
3233
* Simplified set-up with Docker
3334

3435
## Documentation
3536

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

4242
## References
4343

4444
We have published a series of blog posts that are relevant for ML-Agents:
45-
- Overviewing reinforcement learning concepts
46-
([multi-armed bandit](https://blogs.unity3d.com/2017/06/26/unity-ai-themed-blog-entries/)
47-
and [Q-learning](https://blogs.unity3d.com/2017/08/22/unity-ai-reinforcement-learning-with-q-learning/))
48-
- [Using Machine Learning Agents in a real game: a beginner’s guide](https://blogs.unity3d.com/2017/12/11/using-machine-learning-agents-in-a-real-game-a-beginners-guide/)
49-
- [Post](https://blogs.unity3d.com/2018/02/28/introducing-the-winners-of-the-first-ml-agents-challenge/) announcing the winners of our
50-
[first ML-Agents Challenge](https://connect.unity.com/challenges/ml-agents-1)
51-
- [Post](https://blogs.unity3d.com/2018/01/23/designing-safer-cities-through-simulations/)
52-
overviewing how Unity can be leveraged as a simulator to design safer cities.
45+
46+
* Overviewing reinforcement learning concepts
47+
([multi-armed bandit](https://blogs.unity3d.com/2017/06/26/unity-ai-themed-blog-entries/)
48+
and
49+
[Q-learning](https://blogs.unity3d.com/2017/08/22/unity-ai-reinforcement-learning-with-q-learning/))
50+
* [Using Machine Learning Agents in a real game: a beginner’s guide](https://blogs.unity3d.com/2017/12/11/using-machine-learning-agents-in-a-real-game-a-beginners-guide/)
51+
* [Post](https://blogs.unity3d.com/2018/02/28/introducing-the-winners-of-the-first-ml-agents-challenge/)
52+
announcing the winners of our
53+
[first ML-Agents Challenge](https://connect.unity.com/challenges/ml-agents-1)
54+
* [Post](https://blogs.unity3d.com/2018/01/23/designing-safer-cities-through-simulations/)
55+
overviewing how Unity can be leveraged as a simulator to design safer cities.
5356

5457
In addition to our own documentation, here are some additional, relevant articles:
55-
- [Unity AI - Unity 3D Artificial Intelligence](https://www.youtube.com/watch?v=bqsfkGbBU6k)
56-
- [A Game Developer Learns Machine Learning](https://mikecann.co.uk/machine-learning/a-game-developer-learns-machine-learning-intent/)
57-
- [Explore Unity Technologies ML-Agents Exclusively on Intel Architecture](https://software.intel.com/en-us/articles/explore-unity-technologies-ml-agents-exclusively-on-intel-architecture)
58+
59+
* [Unity AI - Unity 3D Artificial Intelligence](https://www.youtube.com/watch?v=bqsfkGbBU6k)
60+
* [A Game Developer Learns Machine Learning](https://mikecann.co.uk/machine-learning/a-game-developer-learns-machine-learning-intent/)
61+
* [Explore Unity Technologies ML-Agents Exclusively on Intel Architecture](https://software.intel.com/en-us/articles/explore-unity-technologies-ml-agents-exclusively-on-intel-architecture)
5862

5963
## Community and Feedback
6064

61-
The ML-Agents toolkit is an open-source project and we encourage and welcome contributions.
62-
If you wish to contribute, be sure to review our
63-
[contribution guidelines](CONTRIBUTING.md) and
65+
The ML-Agents toolkit is an open-source project and we encourage and welcome
66+
contributions. If you wish to contribute, be sure to review our
67+
[contribution guidelines](CONTRIBUTING.md) and
6468
[code of conduct](CODE_OF_CONDUCT.md).
6569

6670
You can connect with us and the broader community
6771
through Unity Connect and GitHub:
72+
6873
* Join our
69-
[Unity Machine Learning Channel](https://connect.unity.com/messages/c/035fba4f88400000)
70-
to connect with others using the ML-Agents toolkit and Unity developers enthusiastic
71-
about machine learning. We use that channel to surface updates
72-
regarding the ML-Agents toolkit (and, more broadly, machine learning in games).
73-
* If you run into any problems using the ML-Agents toolkit,
74-
[submit an issue](https://github.com/Unity-Technologies/ml-agents/issues) and
75-
make sure to include as much detail as possible.
74+
[Unity Machine Learning Channel](https://connect.unity.com/messages/c/035fba4f88400000)
75+
to connect with others using the ML-Agents toolkit and Unity developers
76+
enthusiastic about machine learning. We use that channel to surface updates
77+
regarding the ML-Agents toolkit (and, more broadly, machine learning in
78+
games).
79+
* If you run into any problems using the ML-Agents toolkit,
80+
[submit an issue](https://github.com/Unity-Technologies/ml-agents/issues) and
81+
make sure to include as much detail as possible.
7682

7783
For any other questions or feedback, connect directly with the ML-Agents
7884
@@ -86,7 +92,7 @@ of the documentation to one language (Chinese), but we hope to continue
8692
translating more pages and to other languages. Consequently,
8793
we welcome any enhancements and improvements from the community.
8894

89-
- [Chinese](docs/localized/zh-CN/)
95+
* [Chinese](docs/localized/zh-CN/)
9096

9197
## License
9298

docs/API-Reference.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# API Reference
22

33
Our developer-facing C# classes (Academy, Agent, Decision and Monitor) have been
4-
documented to be compatabile with
4+
documented to be compatible with
55
[Doxygen](http://www.stack.nl/~dimitri/doxygen/) for auto-generating HTML
66
documentation.
77

docs/Background-TensorFlow.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ to TensorFlow-related tools that we leverage within the ML-Agents toolkit.
1616
performing computations using data flow graphs, the underlying representation of
1717
deep learning models. It facilitates training and inference on CPUs and GPUs in
1818
a desktop, server, or mobile device. Within the ML-Agents toolkit, when you
19-
train the behavior of an Agent, the output is a TensorFlow model (.bytes) file
19+
train the behavior of an agent, the output is a TensorFlow model (.bytes) file
2020
that you can then embed within an Internal Brain. Unless you implement a new
2121
algorithm, the use of TensorFlow is mostly abstracted away and behind the
2222
scenes.

docs/Basic-Guide.md

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# Basic Guide
22

3-
This guide will show you how to use a pretrained model in an example Unity
3+
This guide will show you how to use a pre-trained model in an example Unity
44
environment, and show you how to train the model yourself.
55

66
If you are not familiar with the [Unity Engine](https://unity3d.com/unity), we
@@ -13,7 +13,7 @@ the basic concepts of Unity.
1313
In order to use the ML-Agents toolkit within Unity, you need to change some
1414
Unity settings first. Also [TensorFlowSharp
1515
plugin](https://s3.amazonaws.com/unity-ml-agents/0.4/TFSharpPlugin.unitypackage)
16-
is needed for you to use pretrained model within Unity, which is based on the
16+
is needed for you to use pre-trained model within Unity, which is based on the
1717
[TensorFlowSharp repo](https://github.com/migueldeicaza/TensorFlowSharp).
1818

1919
1. Launch Unity
@@ -70,14 +70,14 @@ if you want to [use an executable](Learning-Environment-Executable.md) or to
7070
`None` if you want to interact with the current scene in the Unity Editor.
7171

7272
More information and documentation is provided in the
73-
[Python API](../ml-agents/README.md) page.
73+
[Python API](Python-API.md) page.
7474

7575
## Training the Brain with Reinforcement Learning
7676

7777
### Setting the Brain to External
7878

7979
Since we are going to build this environment to conduct training, we need to set
80-
the brain used by the agents to **External**. This allows the agents to
80+
the Brain used by the Agents to **External**. This allows the Agents to
8181
communicate with the external training process when making their decisions.
8282

8383
1. In the **Scene** window, click the triangle icon next to the Ball3DAcademy
@@ -90,17 +90,23 @@ communicate with the external training process when making their decisions.
9090
### Training the environment
9191

9292
1. Open a command or terminal window.
93-
2. Nagivate to the folder where you installed the ML-Agents toolkit.
93+
2. Navigate to the folder where you cloned the ML-Agents toolkit repository.
94+
**Note**: If you followed the default [installation](Installation.md), then
95+
you should be able to run `mlagents-learn` from any directory.
9496
3. Run `mlagents-learn <trainer-config-path> --run-id=<run-identifier> --train`
95-
Where:
97+
where:
9698
- `<trainer-config-path>` is the relative or absolute filepath of the
97-
trainer configuration. The defaults used by environments in the ML-Agents
98-
SDK can be found in `config/trainer_config.yaml`.
99+
trainer configuration. The defaults used by example environments included
100+
in `MLAgentsSDK` can be found in `config/trainer_config.yaml`.
99101
- `<run-identifier>` is a string used to separate the results of different
100102
training runs
101-
- And the `--train` tells `mlagents-learn` to run a training session (rather
103+
- `--train` tells `mlagents-learn` to run a training session (rather
102104
than inference)
103-
4. When the message _"Start training by pressing the Play button in the Unity
105+
4. If you cloned the ML-Agents repo, then you can simply run
106+
```sh
107+
mlagents-learn config/trainer_config.yaml --run-id=firstRun --train
108+
```
109+
5. When the message _"Start training by pressing the Play button in the Unity
104110
Editor"_ is displayed on the screen, you can press the :arrow_forward: button
105111
in Unity to start training in the Editor.
106112

@@ -143,6 +149,7 @@ INFO:mlagents.learn:{'--curriculum': 'None',
143149
'--train': True,
144150
'--worker-id': '0',
145151
'<trainer-config-path>': 'config/trainer_config.yaml'}
152+
INFO:mlagents.envs:Start training by pressing the Play button in the Unity Editor.
146153
```
147154

148155
**Note**: If you're using Anaconda, don't forget to activate the ml-agents
@@ -152,7 +159,6 @@ If `mlagents-learn` runs correctly and starts training, you should see something
152159
like this:
153160

154161
```console
155-
INFO:mlagents.envs:Start training by pressing the Play button in the Unity Editor.
156162
INFO:mlagents.envs:
157163
'Ball3DAcademy' started successfully!
158164
Unity Academy name: Ball3DAcademy
@@ -208,7 +214,7 @@ You can press Ctrl+C to stop the training, and your trained model will be at
208214
`models/<run-identifier>/editor_<academy_name>_<run-identifier>.bytes` where
209215
`<academy_name>` is the name of the Academy GameObject in the current scene.
210216
This file corresponds to your model's latest checkpoint. You can now embed this
211-
trained model into your internal brain by following the steps below, which is
217+
trained model into your Internal Brain by following the steps below, which is
212218
similar to the steps described
213219
[above](#play-an-example-environment-using-pretrained-model).
214220

@@ -229,7 +235,7 @@ similar to the steps described
229235
page.
230236
- For a more detailed walk-through of our 3D Balance Ball environment, check out
231237
the [Getting Started](Getting-Started-with-Balance-Ball.md) page.
232-
- For a "Hello World" introduction to creating your own learning environment,
238+
- For a "Hello World" introduction to creating your own Learning Environment,
233239
check out the [Making a New Learning
234240
Environment](Learning-Environment-Create-New.md) page.
235241
- For a series of Youtube video tutorials, checkout the

0 commit comments

Comments
 (0)