Skip to main content

A minimal FrozenLake environment with custom BaseEnv

Project description

FrozenLake Demo

A minimal, clean implementation of the FrozenLake environment, inspired by Gymnasium.

Installation

You can install this package locally using pip:

pip install -e .

Usage

import gymnasium as gym
from frozenlake_demo import FrozenLakeEnv

# Initialize environment
env = FrozenLakeEnv(render_mode="human")
obs, info = env.reset(seed=42)

# Run a simple loop
for _ in range(10):
    action = env.action_space.sample()  # Random action
    obs, reward, terminated, truncated, info = env.step(action)
    
    if terminated or truncated:
        obs, info = env.reset()

env.close()

Environment Details

  • Action Space: Discrete(4) (Left=0, Down=1, Right=2, Up=3)
  • Observation Space: Discrete(16) (Grid index 0-15)
  • Map: 4x4 Grid with Start(S), Frozen(F), Hole(H), and Goal(G).

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

frozenlake_demo-0.0.2.tar.gz (3.7 kB view details)

Uploaded Source

Built Distribution

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

frozenlake_demo-0.0.2-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file frozenlake_demo-0.0.2.tar.gz.

File metadata

  • Download URL: frozenlake_demo-0.0.2.tar.gz
  • Upload date:
  • Size: 3.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.9

File hashes

Hashes for frozenlake_demo-0.0.2.tar.gz
Algorithm Hash digest
SHA256 0229a80885a7cddc8d6313bc225f5a680ad5929c810f81d24ee30bcb5eb2ab64
MD5 ba986f7455a465fbdacc2ac91c51992f
BLAKE2b-256 e7d8fe43b95b69e66f5370e1049b2cd50d27e7f4253d5189d9b899eac23c022f

See more details on using hashes here.

File details

Details for the file frozenlake_demo-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for frozenlake_demo-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 744769215dbbef14bc715710fa3510e10410d3e110d5bee6a3644abbaabc1985
MD5 951715970ff4cdb40a438d29cc90f5d0
BLAKE2b-256 185daf66f1c82460e6ea9c1a66d7c7af0f7ba8e20dd5a703055e06668bca1e87

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