Skip to content

Instantly share code, notes, and snippets.

@nafeesb
Created November 21, 2018 19:00
Show Gist options
  • Save nafeesb/ddd02eaa3585844f91a9b8371d043c0d to your computer and use it in GitHub Desktop.
Save nafeesb/ddd02eaa3585844f91a9b8371d043c0d to your computer and use it in GitHub Desktop.

Revisions

  1. nafeesb created this gist Nov 21, 2018.
    33 changes: 33 additions & 0 deletions openaigym_install.md
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,33 @@
    ## Anaconda Configuration
    ```bash
    conda create -n tensorflow tensorflow-gpu pip python=3.6
    conda install ipython matplotlib cython mkl_random mkl mkl-devel swig
    ```

    ## Install OpenAI Gym
    Install from source: https://github.com/openai/gym
    ```bash
    pip install -e .

    ```
    ### Install Optional Modules
    ```bash
    pip install box2d-py
    pip install git+https://github.com/Kojoley/atari-py.git
    ```

    ### Test Box2D
    ```bash
    python gym\envs\box2d\bipedal_walker.py
    ```

    ### Test Atari
    ```python
    import gym
    env = gym.make('SpaceInvaders-v0')
    env.reset()
    for _ in range(1000):
    env.step(env.action_space.sample())
    env.render('human')
    env.close()
    ```