This repository contains tutorial material on Doing DeepRL with PPO in GDG DevFest 2017 Seoul.
Doing_RL_with_PPO.pdf ์ ๋๋ค.
์ค์น์ ์์ roboschool์ Mac๊ณผ Linux ์ด์์ฒด์ ๋ง ์ง์ํฉ๋๋ค.
๊ฐ์ฅ ๋จผ์ roboshcool์ ๊นํ์์ ๋ค์ด๋ฐ์ต๋๋ค.
git clone https://github.com/openai/roboschool
๊ทธ๋ฆฌ๊ณ ๋จผ์ ROBOSCHOOL_PATH๋ฅผ ์ค์ ํด์ผ ํฉ๋๋ค. ์ด ์ค์ ์ ์ค์น๋๋ง ์ด์ฉํ๊ธฐ ๋๋ฌธ์ ํ์ฌ shell์์๋ง ์ ์ฉ๋๋๋ก ๊ฒฝ๋ก๋ฅผ ์ค์ ํด ์ค๋๋ค. /path/to/roboschool ๋์ ์์ ์ด ๋ค์ด๋ฐ์ roboschool ๊ฒฝ๋ก๋ฅผ ์ค์ ํฉ๋๋ค.
ROBOSCHOOL_PATH=/path/to/roboschool
์ด์ roboschool ์ค์น์ ํ์ํ ํจํค์ง๋ค์ ์ค์นํฉ๋๋ค. ๊ฐ๊ฐ์ ์ด์์ฒด์ ์ ๋ง๋ ์ค์น๋ฅผ ์ด์ฉํ๋ฉด ๋ฉ๋๋ค.
- Linux
sudo apt install cmake ffmpeg pkg-config qtbase5-dev libqt5opengl5-dev libpython3.5-dev libboost-python-dev libtinyxml-dev
- Mac
# Will not work on Mavericks: unsupported by homebrew, some libraries won't compile, upgrade first
brew install python3
brew install cmake tinyxml assimp ffmpeg qt
brew install boost-python --without-python --with-python3 --build-from-source
export PATH=/usr/local/bin:/usr/local/opt/qt5/bin:$PATH
export PKG_CONFIG_PATH=/usr/local/opt/qt5/lib/pkgconfig
- Mac, Anaconda with Python 3
brew install cmake tinyxml assimp ffmpeg
brew install boost-python --without-python --with-python3 --build-from-source
conda install qt
export PKG_CONFIG_PATH=$(dirname $(dirname $(which python)))/lib/pkgconfig
๊ทธ ๋ค์์ roboschool์ ๋๋ฆฌ๋๋ฐ ํ์ํ ๋ฌผ๋ฆฌ์์ง์ธ bullet3๋ฅผ ์ค์นํด์ผ ํฉ๋๋ค. ๋จผ์ bullet3๋ฅผ ๋จผ์ ๊นํ์์ ๋ฐ์์์ ๋น๋๋ฅผ ํด์ผํฉ๋๋ค. ** git cloneํ roboschool ๋๋ ํ ๋ฆฌ์์ bullet3๋ฅผ ์ค์นํด์ฃผ์ธ์.
git clone https://github.com/olegklimov/bullet3 -b roboschool_self_collision
mkdir bullet3/build
cd bullet3/build
cmake -DBUILD_SHARED_LIBS=ON -DUSE_DOUBLE_PRECISION=1 _DCMAKE_INSTALL_PREFIX:PATH=$ROBOSCHOOL_PATH/roboschool/cpp-household/bullet_local_install -DBUILD_CPU_DEMOS=OFF -DBUILD_BULLET2_DEMOS=OFF -DBUILD_EXTRAS=OFF -DBUILD_UNIT_TESTS=OFF -DBUILD_CLSOCKET=OFF -DBUILD_ENET=OFF -DBUILD_OPENGL3_DEMOS=OFF ..
make -j4
make install
cd ../..
๋ง์ง๋ง์ผ๋ก gym๊ณผ roboschool์ ์ค์นํ๋ฉด ๋ฉ๋๋ค. (python2 ๋ฒ์ ์ ์ด์ฉํ๋ค๋ฉด pip๋ฅผ ์ด์ฉํ๋ฉด ๋ฉ๋๋ค.)
pip3 install gym
pip3 install -e $ROBOSCHOOL_PATH