main() blog

プログラムやゲーム、旅、愛する家族について綴っていきます。

Unityで機械学習を行う「ML-Agents」を試してみよう!(Mac編)

Unityで機械学習を行うためのライブラリが公開されているので試してみました。
サンプルのプロジェクトも収録されているので、
今回はサンプルを実行するところまで紹介します。

f:id:takezoh_1127:20181129193235p:plain

実行環境は以下のバージョンで試してみました。

Unity 2018.2.9f1
ML-Agents v0.5.0

Python3.6のインストール

Pythonの環境がインストールされている必要があります。
Python3とpip3がインストールされている必要があるので、
最低限の環境構築の方法を書いておきます。

公式サイト

Welcome to Python.org

Downloads → Mac OSX → Python3.6.7をダウンロードします。

ダウンロードしたファイルを開くとインストールが始まります。

f:id:takezoh_1127:20181129192454p:plain

手順に沿って進めるとインストールが完了します。

f:id:takezoh_1127:20181129192854p:plain

インストールした状態だとターミナルからpython3と入力すると実行できます。

$ python3 --version
Python 3.6.7

pip3のインストール

pipというのはpythonライブラリをインストール・管理する仕組みです。
今回はTenserFlowなどをインストールするのに必要となります。

公式サイトでPython3をインストールするとpip3もインストールされる様です。
以下のコマンドでpip3がインストールされているか確認してみましょう。

$ pip3 --version

$ pip3 --version
pip 10.0.1 from /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages/pip (python 3.6)

ML-Agentsのダウンロード

GitHubのML-AgentsのページにアクセスしてリポジトリからCloneもしくはzipをダウンロードします。

GitHub - Unity-Technologies/ml-agents: Unity Machine Learning Agents Toolkit

今回はzipファイルをダウンロードします。
解凍したフォルダを任意の場所に移動します。

必要なライブラリのインストール

ml-agents-master/ml-agents/以下に移動して、以下のコマンドを実行します。

$ cd Documents/product/unity/ml-agents-master/ml-agents/
$ pip3 install .

必要なライブラリのインストールが行われます。

$ pip3 install .
Processing /Users/takezoh/Documents/product/unity/ml-agents-master/ml-agents
Collecting tensorflow<1.8,>=1.7 (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/d3/90/f73789d9f6ecbd629ef646e234af9d15a6fadf81a928f9ae4332ba85fd76/tensorflow-1.7.1-cp36-cp36m-macosx_10_11_x86_64.whl (45.5MB)
    100% |████████████████████████████████| 45.5MB 1.1MB/s 
Collecting Pillow>=4.2.1 (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/d1/21/bef2816809fac16754e07ed935469fc65f42ced1a94766de7c804179311d/Pillow-5.3.0-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (3.6MB)
    100% |████████████████████████████████| 3.6MB 5.2MB/s 
Collecting matplotlib (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/28/6c/addb3560777f454b1d56f0020f89e901eaf68a62593d4795e38ddf24bbd6/matplotlib-3.0.2-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (14.1MB)
    100% |████████████████████████████████| 14.1MB 306kB/s 
Collecting numpy<=1.14.5,>=1.13.3 (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/f6/cd/b2c50b5190b66c711c23ef23c41d450297eb5a54d2033f8dcb3b8b13ac85/numpy-1.14.5-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (4.7MB)
    100% |████████████████████████████████| 4.7MB 6.4MB/s 
Collecting jupyter (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/83/df/0f5dd132200728a86190397e1ea87cd76244e42d39ec5e88efd25b2abd7e/jupyter-1.0.0-py2.py3-none-any.whl
Collecting pytest>=3.2.2 (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/bb/d5/7601c468ded9a59478dcb39d21e24d58bb375681c64a06fbb629d2bc2ac3/pytest-4.0.0-py2.py3-none-any.whl (217kB)
    100% |████████████████████████████████| 225kB 6.3MB/s 
Collecting docopt (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/a2/55/8f8cab2afd404cf578136ef2cc5dfb50baa1761b68c9da1fb1e4eed343c9/docopt-0.6.2.tar.gz
Collecting pyyaml (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/9e/a3/1d13970c3f36777c583f136c136f804d70f500168edc1edea6daa7200769/PyYAML-3.13.tar.gz (270kB)
    100% |████████████████████████████████| 276kB 6.0MB/s 
Collecting protobuf<3.7,>=3.6 (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/c7/27/133f225035b9539f2dcfebcdf9a69ff0152f56e0120160ec5c972ea7deb9/protobuf-3.6.1-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (1.2MB)
    100% |████████████████████████████████| 1.2MB 10.1MB/s 
Collecting grpcio<1.12.0,>=1.11.0 (from mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/2a/4c/a2995d9350a80de94bf10f84353aee68849c0fe4cfe4979733494ef9693f/grpcio-1.11.1-cp36-cp36m-macosx_10_7_intel.whl (1.8MB)
    100% |████████████████████████████████| 1.8MB 12.1MB/s 
Collecting tensorboard<1.8.0,>=1.7.0 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/0b/ec/65d4e8410038ca2a78c09034094403d231228d0ddcae7d470b223456e55d/tensorboard-1.7.0-py3-none-any.whl (3.1MB)
    100% |████████████████████████████████| 3.1MB 3.6MB/s 
Collecting wheel>=0.26 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/ff/47/1dfa4795e24fd6f93d5d58602dd716c3f101cfd5a77cd9acbe519b44a0a9/wheel-0.32.3-py2.py3-none-any.whl
Collecting astor>=0.6.0 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/35/6b/11530768cac581a12952a2aad00e1526b89d242d0b9f59534ef6e6a1752f/astor-0.7.1-py2.py3-none-any.whl
Collecting absl-py>=0.1.6 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/0c/63/f505d2d4c21db849cf80bad517f0065a30be6b006b0a5637f1b95584a305/absl-py-0.6.1.tar.gz (94kB)
    100% |████████████████████████████████| 102kB 5.6MB/s 
Collecting gast>=0.2.0 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/5c/78/ff794fcae2ce8aa6323e789d1f8b3b7765f601e7702726f430e814822b96/gast-0.2.0.tar.gz
Collecting termcolor>=1.1.0 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/8a/48/a76be51647d0eb9f10e2a4511bf3ffb8cc1e6b14e9e4fab46173aa79f981/termcolor-1.1.0.tar.gz
Collecting six>=1.10.0 (from tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/67/4b/141a581104b1f6397bfa78ac9d43d8ad29a7ca43ea90a2d863fe3056e86a/six-1.11.0-py2.py3-none-any.whl
Collecting kiwisolver>=1.0.1 (from matplotlib->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/fb/96/619db9bf08f652790fa9f3c3884a67dc43da4bdaa185a5aa2117eb4651e1/kiwisolver-1.0.1-cp36-cp36m-macosx_10_6_intel.macosx_10_9_intel.macosx_10_9_x86_64.macosx_10_10_intel.macosx_10_10_x86_64.whl (108kB)
    100% |████████████████████████████████| 112kB 3.1MB/s 
Collecting cycler>=0.10 (from matplotlib->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/f7/d2/e07d3ebb2bd7af696440ce7e754c59dd546ffe1bbe732c8ab68b9c834e61/cycler-0.10.0-py2.py3-none-any.whl
Collecting pyparsing!=2.0.4,!=2.1.2,!=2.1.6,>=2.0.1 (from matplotlib->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/71/e8/6777f6624681c8b9701a8a0a5654f3eb56919a01a78e12bf3c73f5a3c714/pyparsing-2.3.0-py2.py3-none-any.whl (59kB)
    100% |████████████████████████████████| 61kB 15.7MB/s 
Collecting python-dateutil>=2.1 (from matplotlib->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/74/68/d87d9b36af36f44254a8d512cbfc48369103a3b9e474be9bdfe536abfc45/python_dateutil-2.7.5-py2.py3-none-any.whl (225kB)
    100% |████████████████████████████████| 235kB 4.8MB/s 
Collecting notebook (from jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/a2/5d/d1907cd32ac00b5ead56f6e61d9794fa60ef105a22ac5da6e7556011580f/notebook-5.7.2-py2.py3-none-any.whl (9.0MB)
    100% |████████████████████████████████| 9.0MB 2.9MB/s 
Collecting nbconvert (from jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/b5/bb/94c493051d60e5b9c0f7f9a368b324201818c1b1c4cae85d1e49a41846c7/nbconvert-5.4.0-py2.py3-none-any.whl (405kB)
    100% |████████████████████████████████| 409kB 2.7MB/s 
Collecting ipykernel (from jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/d8/b0/f0be5c5ab335196f5cce96e5b889a4fcf5bfe462eb0acc05cd7e2caf65eb/ipykernel-5.1.0-py3-none-any.whl (113kB)
    100% |████████████████████████████████| 122kB 24.8MB/s 
Collecting jupyter-console (from jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/cb/ee/6374ae8c21b7d0847f9c3722dcdfac986b8e54fa9ad9ea66e1eb6320d2b8/jupyter_console-6.0.0-py2.py3-none-any.whl
Collecting ipywidgets (from jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/30/9a/a008c7b1183fac9e52066d80a379b3c64eab535bd9d86cdc29a0b766fd82/ipywidgets-7.4.2-py2.py3-none-any.whl (111kB)
    100% |████████████████████████████████| 112kB 21.3MB/s 
Collecting qtconsole (from jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/e0/7a/8aefbc0ed078dec7951ac9a06dcd1869243ecd7bcbce26fa47bf5e469a8f/qtconsole-4.4.3-py2.py3-none-any.whl (113kB)
    100% |████████████████████████████████| 122kB 24.7MB/s 
Collecting pluggy>=0.7 (from pytest>=3.2.2->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/1c/e7/017c262070af41fe251401cb0d0e1b7c38f656da634cd0c15604f1f30864/pluggy-0.8.0-py2.py3-none-any.whl
Collecting attrs>=17.4.0 (from pytest>=3.2.2->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/3a/e1/5f9023cc983f1a628a8c2fd051ad19e76ff7b142a0faf329336f9a62a514/attrs-18.2.0-py2.py3-none-any.whl
Collecting more-itertools>=4.0.0 (from pytest>=3.2.2->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/79/b1/eace304ef66bd7d3d8b2f78cc374b73ca03bc53664d78151e9df3b3996cc/more_itertools-4.3.0-py3-none-any.whl (48kB)
    100% |████████████████████████████████| 51kB 17.4MB/s 
Collecting py>=1.5.0 (from pytest>=3.2.2->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/3e/c7/3da685ef117d42ac8d71af525208759742dd235f8094221fdaafcd3dba8f/py-1.7.0-py2.py3-none-any.whl (83kB)
    100% |████████████████████████████████| 92kB 20.8MB/s 
Requirement already satisfied: setuptools in /Library/Frameworks/Python.framework/Versions/3.6/lib/python3.6/site-packages (from pytest>=3.2.2->mlagents==0.5.0) (39.0.1)
Collecting atomicwrites>=1.0 (from pytest>=3.2.2->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/3a/9a/9d878f8d885706e2530402de6417141129a943802c084238914fa6798d97/atomicwrites-1.2.1-py2.py3-none-any.whl
Collecting markdown>=2.6.8 (from tensorboard<1.8.0,>=1.7.0->tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/7a/6b/5600647404ba15545ec37d2f7f58844d690baf2f81f3a60b862e48f29287/Markdown-3.0.1-py2.py3-none-any.whl (89kB)
    100% |████████████████████████████████| 92kB 18.7MB/s 
Collecting bleach==1.5.0 (from tensorboard<1.8.0,>=1.7.0->tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/33/70/86c5fec937ea4964184d4d6c4f0b9551564f821e1c3575907639036d9b90/bleach-1.5.0-py2.py3-none-any.whl
Collecting html5lib==0.9999999 (from tensorboard<1.8.0,>=1.7.0->tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/ae/ae/bcb60402c60932b32dfaf19bb53870b29eda2cd17551ba5639219fb5ebf9/html5lib-0.9999999.tar.gz (889kB)
    100% |████████████████████████████████| 890kB 4.3MB/s 
Collecting werkzeug>=0.11.10 (from tensorboard<1.8.0,>=1.7.0->tensorflow<1.8,>=1.7->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/20/c4/12e3e56473e52375aa29c4764e70d1b8f3efa6682bef8d0aae04fe335243/Werkzeug-0.14.1-py2.py3-none-any.whl (322kB)
    100% |████████████████████████████████| 327kB 5.4MB/s 
Collecting terminado>=0.8.1 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/2e/20/a26211a24425923d46e1213b376a6ee60dc30bcdf1b0c345e2c3769deb1c/terminado-0.8.1-py2.py3-none-any.whl
Collecting Send2Trash (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/49/46/c3dc27481d1cc57b9385aff41c474ceb7714f7935b1247194adae45db714/Send2Trash-1.5.0-py3-none-any.whl
Collecting tornado>=4 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/e6/78/6e7b5af12c12bdf38ca9bfe863fcaf53dc10430a312d0324e76c1e5ca426/tornado-5.1.1.tar.gz (516kB)
    100% |████████████████████████████████| 522kB 3.7MB/s 
Collecting ipython-genutils (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/fa/bc/9bd3b5c2b4774d5f33b2d544f1460be9df7df2fe42f352135381c347c69a/ipython_genutils-0.2.0-py2.py3-none-any.whl
Collecting nbformat (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/da/27/9a654d2b6cc1eaa517d1c5a4405166c7f6d72f04f6e7eea41855fe808a46/nbformat-4.4.0-py2.py3-none-any.whl (155kB)
    100% |████████████████████████████████| 163kB 5.6MB/s 
Collecting traitlets>=4.2.1 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/93/d6/abcb22de61d78e2fc3959c964628a5771e47e7cc60d53e9342e21ed6cc9a/traitlets-4.3.2-py2.py3-none-any.whl (74kB)
    100% |████████████████████████████████| 81kB 11.7MB/s 
Collecting prometheus-client (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/61/84/9aa657b215b04f21a72ca8e50ff159eef9795096683e4581a357baf4dde6/prometheus_client-0.4.2.tar.gz
Collecting jinja2 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/7f/ff/ae64bacdfc95f27a016a7bed8e8686763ba4d277a78ca76f32659220a731/Jinja2-2.10-py2.py3-none-any.whl (126kB)
    100% |████████████████████████████████| 133kB 3.8MB/s 
Collecting jupyter-client>=5.2.0 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/94/dd/fe6c4d683b09eb05342bd2816b7779663f71762b4fa9c2d5203d35d17354/jupyter_client-5.2.3-py2.py3-none-any.whl (89kB)
    100% |████████████████████████████████| 92kB 21.5MB/s 
Collecting jupyter-core>=4.4.0 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/1d/44/065d2d7bae7bebc06f1dd70d23c36da8c50c0f08b4236716743d706762a8/jupyter_core-4.4.0-py2.py3-none-any.whl (126kB)
    100% |████████████████████████████████| 133kB 4.5MB/s 
Collecting pyzmq>=17 (from notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/24/a9/7619afa48606e6cfe345c124f31942698c0c066f133c98c2dcbe72018349/pyzmq-17.1.2-cp36-cp36m-macosx_10_6_intel.whl (1.3MB)
    100% |████████████████████████████████| 1.3MB 4.5MB/s 
Collecting pygments (from nbconvert->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/02/ee/b6e02dc6529e82b75bb06823ff7d005b141037cb1416b10c6f00fc419dca/Pygments-2.2.0-py2.py3-none-any.whl (841kB)
    100% |████████████████████████████████| 849kB 4.3MB/s 
Collecting mistune>=0.8.1 (from nbconvert->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/09/ec/4b43dae793655b7d8a25f76119624350b4d65eb663459eb9603d7f1f0345/mistune-0.8.4-py2.py3-none-any.whl
Collecting entrypoints>=0.2.2 (from nbconvert->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/cc/8b/4eefa9b47f1910b3d2081da67726b066e379b04ca897acfe9f92bac56147/entrypoints-0.2.3-py2.py3-none-any.whl
Collecting pandocfilters>=1.4.1 (from nbconvert->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/4c/ea/236e2584af67bb6df960832731a6e5325fd4441de001767da328c33368ce/pandocfilters-1.4.2.tar.gz
Collecting defusedxml (from nbconvert->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/87/1c/17f3e3935a913dfe2a5ca85fa5ccbef366bfd82eb318b1f75dadbf0affca/defusedxml-0.5.0-py2.py3-none-any.whl
Collecting testpath (from nbconvert->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/be/a4/162f9ebb6489421fe46dcca2ae420369edfee4b563c668d93cb4605d12ba/testpath-0.4.2-py2.py3-none-any.whl (163kB)
    100% |████████████████████████████████| 163kB 5.4MB/s 
Collecting ipython>=5.0.0 (from ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/1b/e2/ffb8c1b574f972cf4183b0aac8f16b57f1e3bbe876b31555b107ea3fd009/ipython-7.1.1-py3-none-any.whl (764kB)
    100% |████████████████████████████████| 768kB 4.4MB/s 
Collecting prompt-toolkit<2.1.0,>=2.0.0 (from jupyter-console->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/d1/e6/adb3be5576f5d27c6faa33f1e9fea8fe5dbd9351db12148de948507e352c/prompt_toolkit-2.0.7-py3-none-any.whl (338kB)
    100% |████████████████████████████████| 348kB 4.9MB/s 
Collecting widgetsnbextension~=3.4.0 (from ipywidgets->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/8a/81/35789a3952afb48238289171728072d26d6e76649ddc8b3588657a2d78c1/widgetsnbextension-3.4.2-py2.py3-none-any.whl (2.2MB)
    100% |████████████████████████████████| 2.2MB 3.8MB/s 
Collecting ptyprocess; os_name != "nt" (from terminado>=0.8.1->notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/d1/29/605c2cc68a9992d18dada28206eeada56ea4bd07a239669da41674648b6f/ptyprocess-0.6.0-py2.py3-none-any.whl
Collecting jsonschema!=2.5.0,>=2.4 (from nbformat->notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/77/de/47e35a97b2b05c2fadbec67d44cfcdcd09b8086951b331d82de90d2912da/jsonschema-2.6.0-py2.py3-none-any.whl
Collecting decorator (from traitlets>=4.2.1->notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/bc/bb/a24838832ba35baf52f32ab1a49b906b5f82fb7c76b2f6a7e35e140bac30/decorator-4.3.0-py2.py3-none-any.whl
Collecting MarkupSafe>=0.23 (from jinja2->notebook->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/da/fc/2979c425ad23d528d6ac2e1f3efdc28e572fa1e1fbd5a75171cbdd7ddaa5/MarkupSafe-1.1.0-cp36-cp36m-macosx_10_6_intel.whl
Collecting jedi>=0.10 (from ipython>=5.0.0->ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/7a/1a/9bd24a185873b998611c2d8d4fb15cd5e8a879ead36355df7ee53e9111bf/jedi-0.13.1-py2.py3-none-any.whl (177kB)
    100% |████████████████████████████████| 184kB 2.8MB/s 
Collecting pickleshare (from ipython>=5.0.0->ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/9a/41/220f49aaea88bc6fa6cba8d05ecf24676326156c23b991e80b3f2fc24c77/pickleshare-0.7.5-py2.py3-none-any.whl
Collecting pexpect; sys_platform != "win32" (from ipython>=5.0.0->ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/89/e6/b5a1de8b0cc4e07ca1b305a4fcc3f9806025c1b651ea302646341222f88b/pexpect-4.6.0-py2.py3-none-any.whl (57kB)
    100% |████████████████████████████████| 61kB 15.0MB/s 
Collecting appnope; sys_platform == "darwin" (from ipython>=5.0.0->ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/87/a9/7985e6a53402f294c8f0e8eff3151a83f1fb901fa92909bb3ff29b4d22af/appnope-0.1.0-py2.py3-none-any.whl
Collecting backcall (from ipython>=5.0.0->ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/84/71/c8ca4f5bb1e08401b916c68003acf0a0655df935d74d93bf3f3364b310e0/backcall-0.1.0.tar.gz
Collecting wcwidth (from prompt-toolkit<2.1.0,>=2.0.0->jupyter-console->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/7e/9f/526a6947247599b084ee5232e4f9190a38f398d7300d866af3ab571a5bfe/wcwidth-0.1.7-py2.py3-none-any.whl
Collecting parso>=0.3.0 (from jedi>=0.10->ipython>=5.0.0->ipykernel->jupyter->mlagents==0.5.0)
  Downloading https://files.pythonhosted.org/packages/09/51/9c48a46334be50c13d25a3afe55fa05c445699304c5ad32619de953a2305/parso-0.3.1-py2.py3-none-any.whl (88kB)
    100% |████████████████████████████████| 92kB 4.8MB/s 
Installing collected packages: markdown, six, html5lib, bleach, wheel, numpy, protobuf, werkzeug, tensorboard, astor, absl-py, gast, termcolor, grpcio, tensorflow, Pillow, kiwisolver, cycler, pyparsing, python-dateutil, matplotlib, ptyprocess, tornado, terminado, Send2Trash, pygments, jsonschema, decorator, ipython-genutils, traitlets, jupyter-core, nbformat, mistune, entrypoints, pandocfilters, defusedxml, testpath, MarkupSafe, jinja2, nbconvert, parso, jedi, pickleshare, pexpect, appnope, backcall, wcwidth, prompt-toolkit, ipython, pyzmq, jupyter-client, ipykernel, prometheus-client, notebook, jupyter-console, widgetsnbextension, ipywidgets, qtconsole, jupyter, pluggy, attrs, more-itertools, py, atomicwrites, pytest, docopt, pyyaml, mlagents
  Running setup.py install for html5lib ... done
  Running setup.py install for absl-py ... done
  Running setup.py install for gast ... done
  Running setup.py install for termcolor ... done
  Running setup.py install for tornado ... done
  Running setup.py install for pandocfilters ... done
  Running setup.py install for backcall ... done
  Running setup.py install for prometheus-client ... done
  Running setup.py install for docopt ... done
  Running setup.py install for pyyaml ... done
  Running setup.py install for mlagents ... done
Successfully installed MarkupSafe-1.1.0 Pillow-5.3.0 Send2Trash-1.5.0 absl-py-0.6.1 appnope-0.1.0 astor-0.7.1 atomicwrites-1.2.1 attrs-18.2.0 backcall-0.1.0 bleach-1.5.0 cycler-0.10.0 decorator-4.3.0 defusedxml-0.5.0 docopt-0.6.2 entrypoints-0.2.3 gast-0.2.0 grpcio-1.11.1 html5lib-0.9999999 ipykernel-5.1.0 ipython-7.1.1 ipython-genutils-0.2.0 ipywidgets-7.4.2 jedi-0.13.1 jinja2-2.10 jsonschema-2.6.0 jupyter-1.0.0 jupyter-client-5.2.3 jupyter-console-6.0.0 jupyter-core-4.4.0 kiwisolver-1.0.1 markdown-3.0.1 matplotlib-3.0.2 mistune-0.8.4 mlagents-0.5.0 more-itertools-4.3.0 nbconvert-5.4.0 nbformat-4.4.0 notebook-5.7.2 numpy-1.14.5 pandocfilters-1.4.2 parso-0.3.1 pexpect-4.6.0 pickleshare-0.7.5 pluggy-0.8.0 prometheus-client-0.4.2 prompt-toolkit-2.0.7 protobuf-3.6.1 ptyprocess-0.6.0 py-1.7.0 pygments-2.2.0 pyparsing-2.3.0 pytest-4.0.0 python-dateutil-2.7.5 pyyaml-3.13 pyzmq-17.1.2 qtconsole-4.4.3 six-1.11.0 tensorboard-1.7.0 tensorflow-1.7.1 termcolor-1.1.0 terminado-0.8.1 testpath-0.4.2 tornado-5.1.1 traitlets-4.3.2 wcwidth-0.1.7 werkzeug-0.14.1 wheel-0.32.3 widgetsnbextension-3.4.2
You are using pip version 10.0.1, however version 18.1 is available.
You should consider upgrading via the 'pip install --upgrade pip' command.

pipが古いとか言われている様ですがとりあえず必要なライブラリなどのインストール、セットアップは成功した様です。

正しくセットアップが完了しているか確認してみましょう。

$ mlagents-learn --help

    
                        ▄▄▄▓▓▓▓
                   ╓▓▓▓▓▓▓█▓▓▓▓▓
              ,▄▄▄m▀▀▀'  ,▓▓▓▀▓▓▄                           ▓▓▓  ▓▓▌
            ▄▓▓▓▀'      ▄▓▓▀  ▓▓▓      ▄▄     ▄▄ ,▄▄ ▄▄▄▄   ,▄▄ ▄▓▓▌▄ ▄▄▄    ,▄▄
          ▄▓▓▓▀        ▄▓▓▀   ▐▓▓▌     ▓▓▌   ▐▓▓ ▐▓▓▓▀▀▀▓▓▌ ▓▓▓ ▀▓▓▌▀ ^▓▓▌  ╒▓▓▌
        ▄▓▓▓▓▓▄▄▄▄▄▄▄▄▓▓▓      ▓▀      ▓▓▌   ▐▓▓ ▐▓▓    ▓▓▓ ▓▓▓  ▓▓▌   ▐▓▓▄ ▓▓▌
        ▀▓▓▓▓▀▀▀▀▀▀▀▀▀▀▓▓▄     ▓▓      ▓▓▌   ▐▓▓ ▐▓▓    ▓▓▓ ▓▓▓  ▓▓▌    ▐▓▓▐▓▓
          ^█▓▓▓        ▀▓▓▄   ▐▓▓▌     ▓▓▓▓▄▓▓▓▓ ▐▓▓    ▓▓▓ ▓▓▓  ▓▓▓▄    ▓▓▓▓`
            '▀▓▓▓▄      ^▓▓▓  ▓▓▓       └▀▀▀▀ ▀▀ ^▀▀    `▀▀ `▀▀   '▀▀    ▐▓▓▌
               ▀▀▀▀▓▄▄▄   ▓▓▓▓▓▓,                                      ▓▓▓▓▀
                   `▀█▓▓▓▓▓▓▓▓▓▌
                        ¬`▀▀▀█▓

        
    Usage:
      mlagents-learn <trainer-config-path> [options]
      mlagents-learn --help

    Options:
      --env=<file>               Name of the Unity executable [default: None].
      --curriculum=<directory>   Curriculum json directory for environment [default: None].
      --keep-checkpoints=<n>     How many model checkpoints to keep [default: 5].
      --lesson=<n>               Start learning from this lesson [default: 0].
      --load                     Whether to load the model or randomly initialize [default: False].
      --run-id=<path>            The directory name for model and summary statistics [default: ppo].
      --num-runs=<n>             Number of concurrent training sessions [default: 1]. 
      --save-freq=<n>            Frequency at which to save model [default: 50000].
      --seed=<n>                 Random seed used for training [default: -1].
      --slow                     Whether to run the game at training speed [default: False].
      --train                    Whether to train model, or only run inference [default: False].
      --worker-id=<n>            Number to add to communication port (5005) [default: 0].
      --docker-target-name=<dt>  Docker volume to store training-specific files [default: None].
      --no-graphics              Whether to run the environment in no-graphics mode [default: False].

学習用の実行環境をビルドする

Unityを起動して以下のフォルダを開きます。

ml-agents-master/UnitySDK/

プロジェクトが開いたら次にシーンを開きます。
とりあえず3DBallというサンプルを開いてみます。
Projectタブから [Assets] → [ML-Agents] → [Examples] → [3DBall] → [Scenes] にある 3DBall を開きます。

[Hierarchy]タブの [Ball3DAcademy] → [Ball3DBrain] を選択します。
[Inspector]の Brain Type を "External" に変更して保存します。

メインメニューの [File] → [BuildSettings] を開いて Platform が [PC, Mac & Linux Standalone] になっていることを確認します。
出力先を以下のフォルダに指定してビルドします。

ml-agents-master/ml-agents/3DBall.app

学習させてみる

サンプルを学習させてみましょう。
以下のコマンドを実行します。

$ mlagents-learn ../config/trainer_config.yaml --env=3DBall --run-id=firstRun --train

学習用の小さいウィンドウの実行環境が起動して、ひたすら学習を繰り返します。
デフォルトの設定では50000回試行を繰り返します。

f:id:takezoh_1127:20181129193000p:plain

$ mlagents-learn ../config/trainer_config.yaml --env=3DBall --run-id=firstRun --train

    
                        ▄▄▄▓▓▓▓
                   ╓▓▓▓▓▓▓█▓▓▓▓▓
              ,▄▄▄m▀▀▀'  ,▓▓▓▀▓▓▄                           ▓▓▓  ▓▓▌
            ▄▓▓▓▀'      ▄▓▓▀  ▓▓▓      ▄▄     ▄▄ ,▄▄ ▄▄▄▄   ,▄▄ ▄▓▓▌▄ ▄▄▄    ,▄▄
          ▄▓▓▓▀        ▄▓▓▀   ▐▓▓▌     ▓▓▌   ▐▓▓ ▐▓▓▓▀▀▀▓▓▌ ▓▓▓ ▀▓▓▌▀ ^▓▓▌  ╒▓▓▌
        ▄▓▓▓▓▓▄▄▄▄▄▄▄▄▓▓▓      ▓▀      ▓▓▌   ▐▓▓ ▐▓▓    ▓▓▓ ▓▓▓  ▓▓▌   ▐▓▓▄ ▓▓▌
        ▀▓▓▓▓▀▀▀▀▀▀▀▀▀▀▓▓▄     ▓▓      ▓▓▌   ▐▓▓ ▐▓▓    ▓▓▓ ▓▓▓  ▓▓▌    ▐▓▓▐▓▓
          ^█▓▓▓        ▀▓▓▄   ▐▓▓▌     ▓▓▓▓▄▓▓▓▓ ▐▓▓    ▓▓▓ ▓▓▓  ▓▓▓▄    ▓▓▓▓`
            '▀▓▓▓▄      ^▓▓▓  ▓▓▓       └▀▀▀▀ ▀▀ ^▀▀    `▀▀ `▀▀   '▀▀    ▐▓▓▌
               ▀▀▀▀▓▄▄▄   ▓▓▓▓▓▓,                                      ▓▓▓▓▀
                   `▀█▓▓▓▓▓▓▓▓▓▌
                        ¬`▀▀▀█▓

        
INFO:mlagents.trainers:{'--curriculum': 'None',
 '--docker-target-name': 'None',
 '--env': '3DBall',
 '--help': False,
 '--keep-checkpoints': '5',
 '--lesson': '0',
 '--load': False,
 '--no-graphics': False,
 '--num-runs': '1',
 '--run-id': 'firstRun',
 '--save-freq': '50000',
 '--seed': '-1',
 '--slow': False,
 '--train': True,
 '--worker-id': '0',
 '<trainer-config-path>': '../config/trainer_config.yaml'}
CrashReporter: initialized
Mono path[0] = '/Users/takezoh/Documents/product/unity/ml-agents-master/ml-agents/3DBall.app/Contents/Resources/Data/Managed'
Mono config path = '/Users/takezoh/Documents/product/unity/ml-agents-master/ml-agents/3DBall.app/Contents/MonoBleedingEdge/etc'
INFO:mlagents.envs:
'Ball3DAcademy' started successfully!
Unity Academy name: Ball3DAcademy
        Number of Brains: 1
        Number of External Brains : 1
        Reset Parameters :
        
Unity brain name: Ball3DBrain
        Number of Visual Observations (per agent): 0
        Vector Observation space size (per agent): 8
        Number of stacked Vector Observation: 1
        Vector Action space type: continuous
        Vector Action space size (per agent): [2]
        Vector Action descriptions: , 
2018-11-23 11:48:38.502440: I tensorflow/core/platform/cpu_feature_guard.cc:140] Your CPU supports instructions that this TensorFlow binary was not compiled to use: AVX2 FMA
INFO:mlagents.envs:Hyperparameters for the PPO Trainer of brain Ball3DBrain: 
    batch_size: 64
    beta:   0.001
    buffer_size:    12000
    epsilon:    0.2
    gamma:  0.995
    hidden_units:   128
    lambd:  0.99
    learning_rate:  0.0003
    max_steps:  5.0e4
    normalize:  True
    num_epoch:  3
    num_layers: 2
    time_horizon:   1000
    sequence_length:    64
    summary_freq:   1000
    use_recurrent:  False
    graph_scope:    
    summary_path:   ./summaries/firstRun-0
    memory_size:    256
    use_curiosity:  False
    curiosity_strength: 0.01
    curiosity_enc_size: 128
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 1000. Mean Reward: 1.230. Std of Reward: 0.691. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 2000. Mean Reward: 1.343. Std of Reward: 0.689. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 3000. Mean Reward: 1.624. Std of Reward: 0.936. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 4000. Mean Reward: 2.339. Std of Reward: 1.491. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 5000. Mean Reward: 3.799. Std of Reward: 2.948. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 6000. Mean Reward: 6.096. Std of Reward: 5.431. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 7000. Mean Reward: 8.803. Std of Reward: 8.535. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 8000. Mean Reward: 13.147. Std of Reward: 11.828. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 9000. Mean Reward: 32.203. Std of Reward: 25.492. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 10000. Mean Reward: 52.310. Std of Reward: 33.449. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 11000. Mean Reward: 65.917. Std of Reward: 37.350. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 12000. Mean Reward: 84.487. Std of Reward: 27.574. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 13000. Mean Reward: 81.887. Std of Reward: 25.280. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 14000. Mean Reward: 100.000. Std of Reward: 0.000. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 15000. Mean Reward: 90.258. Std of Reward: 21.918. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 16000. Mean Reward: 79.829. Std of Reward: 34.560. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 17000. Mean Reward: 93.223. Std of Reward: 15.343. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 18000. Mean Reward: 96.100. Std of Reward: 11.015. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 19000. Mean Reward: 82.669. Std of Reward: 31.036. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 20000. Mean Reward: 85.664. Std of Reward: 26.782. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 21000. Mean Reward: 83.436. Std of Reward: 28.500. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 22000. Mean Reward: 81.273. Std of Reward: 34.778. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 23000. Mean Reward: 97.642. Std of Reward: 7.822. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 24000. Mean Reward: 98.325. Std of Reward: 3.792. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 25000. Mean Reward: 66.756. Std of Reward: 41.673. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 26000. Mean Reward: 72.700. Std of Reward: 38.289. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 27000. Mean Reward: 100.000. Std of Reward: 0.000. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 28000. Mean Reward: 85.515. Std of Reward: 29.961. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 29000. Mean Reward: 91.857. Std of Reward: 25.077. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 30000. Mean Reward: 84.929. Std of Reward: 32.173. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 31000. Mean Reward: 74.700. Std of Reward: 38.516. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 32000. Mean Reward: 80.664. Std of Reward: 37.163. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 33000. Mean Reward: 92.123. Std of Reward: 26.043. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 34000. Mean Reward: 75.225. Std of Reward: 42.485. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 35000. Mean Reward: 92.931. Std of Reward: 24.489. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 36000. Mean Reward: 89.385. Std of Reward: 26.903. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 37000. Mean Reward: 100.000. Std of Reward: 0.000. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 38000. Mean Reward: 87.136. Std of Reward: 31.519. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 39000. Mean Reward: 95.162. Std of Reward: 16.761. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 40000. Mean Reward: 86.300. Std of Reward: 33.576. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 41000. Mean Reward: 75.771. Std of Reward: 38.771. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 42000. Mean Reward: 82.331. Std of Reward: 32.022. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 43000. Mean Reward: 72.575. Std of Reward: 41.392. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 44000. Mean Reward: 82.969. Std of Reward: 28.544. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 45000. Mean Reward: 83.950. Std of Reward: 34.012. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 46000. Mean Reward: 87.743. Std of Reward: 30.242. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 47000. Mean Reward: 84.314. Std of Reward: 34.053. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 48000. Mean Reward: 93.154. Std of Reward: 23.716. Training.
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 49000. Mean Reward: 72.807. Std of Reward: 40.860. Training.
INFO:mlagents.envs:Saved Model
INFO:mlagents.trainers: firstRun-0: Ball3DBrain: Step: 50000. Mean Reward: 93.336. Std of Reward: 16.888. Training.
INFO:mlagents.envs:Saved Model
INFO:mlagents.envs:List of nodes to export :
INFO:mlagents.envs: action
INFO:mlagents.envs: value_estimate
INFO:mlagents.envs: action_probs
INFO:mlagents.envs: value_estimate
INFO:tensorflow:Restoring parameters from ./models/firstRun-0/model-50001.cptk
INFO:tensorflow:Froze 16 variables.
Converted 16 variables to const ops.

無事に学習を終えました。

学習結果を反映させてみる

その前にTensorFlowSharpプラグインのインポートする必要があります。

https://s3.amazonaws.com/unity-ml-agents/0.5/TFSharpPlugin.unitypackage

ダウンロードしたパッケージを任意のフォルダに移動して、
メインメニューの [Assets] [ImportPackage] [CustomPackage] を選択してダウンロードしたパッケージをインポートします。

先程学習した結果のファイルは以下のフォルダに出力されています。

ml-agents/models/firstRun-0/3DBall_firstRun-0.bytes

それを以下のフォルダにコピーします。

UnitySDK/Assets/ML-Agents/Examples/3DBall/TFModels/

先程の Barin Type を [Internal] に変更します。
GraphModelの項目に先程コピーした 3DBall_firstRun-0 を指定します。

この状態で再生ボタンを押すとボールを落とさない挙動が確認できると思います。

f:id:takezoh_1127:20181129193736p:plain

その他に以下の様なサンプルがあるので色々と試してみると楽しかも知れません。

  • BananaCollectors
    複数のプレイヤーが青いバナナを避けながら黄色いバナナを多く取る。

f:id:takezoh_1127:20181129232430p:plain

  • Bouncer
    ジャンプしながら黄色バナナを取る。

f:id:takezoh_1127:20181129232513p:plain

  • Crawler
    4足歩行を覚えさせる。

f:id:takezoh_1127:20181129232547p:plain

  • GridWorld
    障害物を避けながらゴールに向かう。

f:id:takezoh_1127:20181129232624p:plain

  • Hallway
    置かれた箱の色を認識して同じ色のゴールに向かう。

f:id:takezoh_1127:20181129232821p:plain

  • PushBlock
    オレンジの箱をチェックのゴールまで運ぶとクリア。

f:id:takezoh_1127:20181129232855p:plain

  • Pyramids
    床に置かれた赤いスイッチを踏むと、一つだけ黄色に変化するピラミッドがあるので、
    それを崩して上に乗っている箱を取るとクリア。

f:id:takezoh_1127:20181129232939p:plain

  • Reacher
    2関節のジョイントアームをゴール位置に移動させる。

f:id:takezoh_1127:20181129233027p:plain

  • Scoccer
    2vs2のサッカーゲーム
    それぞれのチームでオフェンス、ディフェンスを学習させている。

f:id:takezoh_1127:20181129233118p:plain

  • Tennis
    二人のプレイヤーがボールを落とさない様にラリーを続ける。

f:id:takezoh_1127:20181129233202p:plain

  • Walker
    そのままだと倒れてしまうキャラクタに2足歩行を覚えさせる。

f:id:takezoh_1127:20181129233244p:plain

  • WallJump
    箱を使って壁を飛び越えてゴールに向かう。

f:id:takezoh_1127:20181129233332p:plain