Skip to content

Instantly share code, notes, and snippets.

View RajGhugare19's full-sized avatar

Raj Ghugare RajGhugare19

View GitHub Profile
@RajGhugare19
RajGhugare19 / env_probes.py
Created January 20, 2023 07:56
Probe environments for basic sanity check of RL algorithms based on Andy Jones post, Debugging RL, Without the Agonizing Pain
import numpy as np
from collections import defaultdict
# Thank you https://andyljones.com/
# Taken from https://andyljones.com/posts/rl-debugging.html#probe
class level_one_env(object):
# One action, zero observation, one timestep long, +1 reward every timestep:
def __init__(self, episode_length=1):
# Set episode length