Code Monkey home page Code Monkey logo

gym-tendulum's Introduction

gym-tendulum

10th order pendulum on a cart to be used as a 3rd party gym environment

Install

git clone [email protected]:jcranney/gym-tendulum.git
cd gym-tendulum
pip install -e .

To test that the install was successful, try running:

python test_tendulum.py

Examples

LQR

To run the tendulum example using LQR as the control law, navigate to gym-tendulum/examples and run:

python tendulum_lqr.py

With any luck, the tendulum will carefully navigate back to the origin. The system is very unstable, but the default parameters saved in the example file should be sufficient to control the tendulum.

You can experiment with different orders of n-dulum, but it's not super elegant at this stage. For now, you have to go into gym-tendulum/envs/tendulum_env.py and modify self._n_order:

    def __init__(self):
        # order of the ndulum
        self._n_order = 10

to be some other number. Anything above 10 is not going to be stable without some tuning, below 10 should be OK, with 1 being the most stable.

Depending on how you installed gym-tendulum, you may need to reinstall after making this change. If you followed the instructions in the Install section, this should not be necessary.

gym-tendulum's People

Watchers

Jesse Cranney avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.