Skip to main content

so much room for activities

Project description

bettermdptools

Check out our docs here!

Getting Started

About

Bettermdptools is a package designed to help users get started with gymnasium, a maintained fork of OpenAI’s Gym library. Bettermdptools includes planning and reinforcement learning algorithms, useful utilities and plots, environment models for blackjack and cartpole, and starter code for working with gymnasium.

Install

pip install or git clone bettermdptools.

pip install bettermdptools
git clone https://github.com/jlm429/bettermdptools

Starter code to get up and running on the gymnasium frozen lake environment. See bettermdptools/notebooks for more.

import gymnasium as gym
from bettermdptools.algorithms.planner import Planner
from bettermdptools.utils.plots import Plots

# make gym environment 
frozen_lake = gym.make('FrozenLake8x8-v1', render_mode=None)

# run VI
V, V_track, pi = Planner(frozen_lake.P).value_iteration()

#plot state values
size=(8,8)
Plots.values_heat_map(V, "Frozen Lake\nValue Iteration State Values", size)

grid_state_values

Documentation

In order to document our code, we use pdoc (NOT pdoc3). This generates .html files that can be hosted via the docs/ directory.

To generate new docs, run:

pdoc --include-undocumented -d numpy -t docs-templates --output-dir docs bettermdptools

Contributing

Pull requests are welcome. All docstrings should be numpy-style so they are parse-able by our autodocumentation tool.

  • Fork bettermdptools.
  • Create a branch (git checkout -b branch_name)
  • Commit changes (git commit -m "Comments")
  • Push to branch (git push origin branch_name)
  • Open a pull request

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bettermdptools-0.8.3.tar.gz (1.2 MB view details)

Uploaded Source

File details

Details for the file bettermdptools-0.8.3.tar.gz.

File metadata

  • Download URL: bettermdptools-0.8.3.tar.gz
  • Upload date:
  • Size: 1.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.8.0 colorama/0.4.4 importlib-metadata/4.6.4 keyring/23.5.0 pkginfo/1.8.2 readme-renderer/34.0 requests-toolbelt/0.9.1 requests/2.25.1 rfc3986/1.5.0 tqdm/4.66.1 urllib3/1.26.5 CPython/3.10.12

File hashes

Hashes for bettermdptools-0.8.3.tar.gz
Algorithm Hash digest
SHA256 cd2ea381a52472cf1a91a10b5c3743aea09fde3c3e014197d8b1fef6b2d652f6
MD5 6616d632cc4964768234f46c65505e75
BLAKE2b-256 6f2b354b8089ecbd9426c5653e37d06971735d930a8a27b8295450438014a240

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page