Skip to main content

A random walk environment for Gymnasium

Project description

Random Walk

This environment reflects the Markov Reward Process (MRP) defined in Example 6.2 Random Walk of the book Reinforcement Learning An Introduction (2nd Ed) by Richard S. Sutton and Andrew G. Barto.
The Random Walk Environment is a custom Gymnasium environment that simulates a simple random walk process. The agent starts in a predefined state and moves randomly to adjacent states (left or right) at each timestep. The states are arranged in a row, with terminal states at both ends. The rightmost terminal state rewards the agent with +1, while all other transitions have a reward of 0. The environment is ideal for experiments in reinforcement learning or Markov Reward Processes (MRPs), focusing on stochastic state transitions without actions.

Installation

pip install random-walk-env

Use with gymnasium

import random_walk_env
import gymnasium as gym

env = gym.make('random_walk_env/RandomWalk-v0')

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

random_walk_env-0.0.3.tar.gz (5.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

random_walk_env-0.0.3-py2.py3-none-any.whl (4.1 kB view details)

Uploaded Python 2Python 3

File details

Details for the file random_walk_env-0.0.3.tar.gz.

File metadata

  • Download URL: random_walk_env-0.0.3.tar.gz
  • Upload date:
  • Size: 5.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.9.20

File hashes

Hashes for random_walk_env-0.0.3.tar.gz
Algorithm Hash digest
SHA256 e89922c60ec386098941ecc531a30fbde472258fda23018ff7502776502517d2
MD5 719ce7d49f7e5f2f36af05c45216adad
BLAKE2b-256 cb8380a2192525595b24baa042a2939e369c28e24a8b08b26004321cbcd7905b

See more details on using hashes here.

File details

Details for the file random_walk_env-0.0.3-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for random_walk_env-0.0.3-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 96107e36374815c17da7c52a4f5ec3778dab178a3deb5c34dd5981f1a2a85d88
MD5 be5b89df477dc6aa1e27c28a8a7a3b4c
BLAKE2b-256 589ccb9325dddb26353d35265a741cc15abadbcdf31ef119bd9da4d132c55b4a

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