semvec/pypi-packages huggingface dataset:
bonsai-gym-common 0.7.4
A library to integrate Bonsai BRAIN with OpenAI Gym environments
License: BSD
Keywords: bonsai

Bonsai Gym Common
=================

A python library for integrating Bonsai BRAIN with Open AI Gym
environments.

Installation
------------

Install the latest stable from PyPI:

::

    $ pip install bonsai-gym-common

Install the latest in-development version:

::

    $ pip install https://github.com/BonsaiAI/bonsai-gym-common

Usage
-----

Once installed, import ``bonsai_gym_common`` in order to access base
class ``GymSimulator`` and ``GymImageSimulator``, which implement all of
the environment-independent Bonsai SDK integrations necessary to train a
Bonsai BRAIN to play an OpenAI Gym simulator.

::

    import gym

    from bonsai_gym_common import GymSimulator

    class CartPoleSimulator(GymSimulator):
        # Perform cartpole-specific integrations here.
bonsai-config 0.4.5
A python library reading and writing bonsai configuration files
License: BSD
Keywords: bonsai

Bonsai Config
=============

A python library reading and writing bonsai configuration files.

Installation
------------

Install the latest stable from PyPI:

::

    $ pip install bonsai-config

Install the latest in-development version:

::

    $ pip install https://github.com/BonsaiAI/bonsai-config

Usage
-----

Once installed, import ``bonsai_config`` in order to access methods to
read and write configuration files used by
`bonsai-cli <https://github.com/BonsaiAI/bonsai-cli>`__ and
`bonsai-python <https://github.com/BonsaiAI/bonsai-python>`__.

::

    from bonsai_config import BonsaiConfig

    # Read properties from the main bonsai config file:
    bonsai_config = BonsaiConfig()
    print(bonsai_config.username())
    print(bonsai_config.access_key())

    # Write properties to the main bonsai config file:
    bonsai_config = BonsaiConfig()
    bonsai_config.update_access_key_and_username('new_access_key', 'new_username')