Skip to content

Instantly share code, notes, and snippets.

View jgarcia-bonsai's full-sized avatar

John Garcia jgarcia-bonsai

View GitHub Profile
$ python mountaincar_simulator.py --train-brain=mountaincar-brain --headless
[2016-10-28 23:21:59,815] Making new env: MountainCar-v0
[2016-10-28 23:21:59,823] Running simulator mountaincar_simulator for training
[2016-10-28 23:21:59,823] About to connect to wss://api.bons.ai/v1/jgarcia/mountaincar-brain/sims/ws
Episode 1 reward is -1036.0
$ bonsai brain train start mountaincar-brain
About to PUT https://api.bons.ai/v1/jgarcia/mountaincar-brain/train for train
Training started.
When training completes, connect simulators to wss://api.bons.ai/v1/jgarcia/mountaincar-brain/2/predictions/ws for predictions
$ bonsai brain load mountaincar-brain mountaincar.ink
About to POST https://api.bons.ai/v1/jgarcia/mountaincar-brain/ink to load inkling
Load request succeeded; a new brain version was created.
@jgarcia-bonsai
jgarcia-bonsai / gist:170d1af02fa0316b80f121ff22643b76
Last active October 28, 2016 19:10
Clone the gym-mountaincar-sample repo
$ git clone https://github.com/BonsaiAI/gym-mountaincar-sample
Cloning into 'gym-mountaincar-sample'...
remote: Counting objects: 40, done.
remote: Compressing objects: 100% (4/4), done.
remote: Total 40 (delta 0), reused 0 (delta 0), pack-reused 35
Unpacking objects: 100% (40/40), done.
Checking connectivity... done.
$ cd gym-mountaincar-sample
@jgarcia-bonsai
jgarcia-bonsai / gist:6bdcd4b5e1c0ec32c27cfc0acaab9adc
Last active October 28, 2016 00:28
Configuring the local bonsai-cli
$ bonsai configure
You can get the access key at https://beta.bons.ai/accounts/key
Access Key (typing will be hidden):
Validating access key...
request to https://beta.bons.ai/v1/validate
Success! Your username is user
@jgarcia-bonsai
jgarcia-bonsai / gist:b164b6580916c5f40caaee96682e14c0
Created October 28, 2016 00:12
Install the Bonsai CLI via pip
$ pip install -U bonsai-cli
Collecting bonsai-cli
Using cached bonsai_cli-0.4.2-py2.py3-none-any.whl
Collecting tabulate>=0.7.5 (from bonsai-cli)
Using cached tabulate-0.7.5.tar.gz
Collecting bonsai-config>=0.3.0 (from bonsai-cli)
Using cached bonsai_config-0.3.1-py2.py3-none-any.whl
Collecting requests>=2.11 (from bonsai-cli)
Using cached requests-2.11.1-py2.py3-none-any.whl
Collecting click>=6.6 (from bonsai-cli)