laermannjan / nip-deeprl-project

Student project in deep reinforcement learning with the OpenAI Gym. We evaluated and analyzed how different model architectures performed as agents in various games.
0 stars 0 forks source link

Swig_constant_randint #17

Closed laermannjan closed 7 years ago

laermannjan commented 7 years ago

Box2D needs swig3.0 to properly compile. Ubuntu 14.10 and above should behave correctly. 14.04 Trusty Tahr does not have swig3.0 in default repositories, therefore we need to make backport repos available According to Greg Brockman (these commands remove any installed older versions of Swig):

$ echo deb http://archive.ubuntu.com/ubuntu trusty-backports main restricted universe multiverse | sudo tee /etc/apt/sources.list.d/box2d-py-swig.list
$ apt-get update && install -t trusty-backports swig3.0
$ apt-get remove swig swig2.0
$ ln -s /usr/bin/swig3.0 /usr/bin/swig

Additionally we can install a prebuilt binary of Box2D to eliminate another source of compile complications:

# Create conda env with python version 3.3, 3.4 or 3.5
$ conda create -n py35 python=3.5
$ source activate py35
# Install binaries
$ conda install -c https://conda.anaconda.org/kne pybox2d