You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/Using-Docker.md
+8-8Lines changed: 8 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,7 @@
1
-
# Using Docker For ML-Agents (Experimental)
1
+
# Using Docker For ML-Agents
2
+
3
+
We currently offer a solution for Windows and Mac users who would like to do training or inference using Docker. This option may be appealing to those who would like to avoid installing Python and TensorFlow themselves. The current setup forces both TensorFlow and Unity to _only_ rely on the CPU for computations. Consequently, our Docker simulation does not use a GPU and uses [`Xvfb`](https://en.wikipedia.org/wiki/Xvfb) to do visual rendering. `Xvfb` is a utility that enables `ML-Agents` (or any other application) to do rendering virtually i.e. it does not assume that the machine running `ML-Agents` has a GPU or a display attached to it. This means that rich environments which involve agents using camera-based visual observations might be slower.
2
4
3
-
We currently offer an experimental solution for Windows and Mac users who would like to do training or inference using Docker. This option may be appealing to those who would like to avoid installing Python and TensorFlow themselves. The current setup forces both TensorFlow and Unity to _only_ rely on the CPU for computations. Consequently, our Docker support is limited to environments whose agents **do not** use camera-based visual observations. For example, the [GridWorld](Learning-Environment-Examples.md#gridworld) environment is **not** supported.
4
5
5
6
## Requirements
6
7
- Unity _Linux Build Support_ Component
@@ -26,13 +27,12 @@ Since Docker typically runs a container sharing a (linux) kernel with the host m
26
27
Unity environment **has** to be built for the **linux platform**. When building a Unity environment, please select the following options from the the Build Settings window:
27
28
- Set the _Target Platform_ to `Linux`
28
29
- Set the _Architecture_ to `x86_64`
29
-
-`Uncheck` the _Development Build_ option
30
-
-`Check` the _Headless Mode_ option. (_This is required because the Unity binary will run in a container that does not have graphics drivers installed_.)
31
-
32
-

30
+
- If the environment does not contain visual observations, you can select the `headless` option here.
33
31
34
32
Then click `Build`, pick an environment name (e.g. `3DBall`) and set the output directory to `unity-volume`. After building, ensure that the file `<environment-name>.x86_64` and subdirectory `<environment-name>_Data/` are created under `unity-volume`.
35
33
34
+

35
+
36
36
### Build the Docker Container
37
37
38
38
First, make sure the Docker engine is running on your machine. Then build the Docker container by calling the following command at the top-level of the repository:
@@ -66,7 +66,7 @@ For the `3DBall` environment, for example this would be:
@@ -77,7 +77,7 @@ For more detail on Docker mounts, check out [these](https://docs.docker.com/stor
77
77
78
78
### Stopping Container and Saving State
79
79
80
-
If you are satisfied with the training progress, you can stop the Docker container while saving state using the following command:
80
+
If you are satisfied with the training progress, you can stop the Docker container while saving state by either using `Ctrl+C` or `⌘+C` (Mac) or by using the following command:
0 commit comments