Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hotfix/fix frame skip random #235

Merged
Merged
Show file tree
Hide file tree
Changes from 3 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions supersuit/generic_wrappers/frame_skip.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
class frame_skip_gym(gymnasium.Wrapper):
def __init__(self, env, num_frames):
super().__init__(env)
self.np_random = env.unwrapped.np_random
self.num_frames = check_transform_frameskip(num_frames)

def step(self, action):
Expand Down
4 changes: 2 additions & 2 deletions supersuit/generic_wrappers/utils/shared_wrapper_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@

import gymnasium
from pettingzoo.utils import BaseParallelWrapper
from pettingzoo.utils.wrappers import OrderEnforcingWrapper as PettingzooWrap
from pettingzoo.utils.wrappers import OrderEnforcingWrapper as BaseWrapper

from supersuit.utils.wrapper_chooser import WrapperChooser


class shared_wrapper_aec(PettingzooWrap):
class shared_wrapper_aec(BaseWrapper):
elliottower marked this conversation as resolved.
Show resolved Hide resolved
def __init__(self, env, modifier_class):
super().__init__(env)

Expand Down
4 changes: 2 additions & 2 deletions supersuit/utils/base_aec_wrapper.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from pettingzoo.utils.wrappers import OrderEnforcingWrapper as PettingzooWrap
from pettingzoo.utils.wrappers import OrderEnforcingWrapper as PZBaseWrapper


class BaseWrapper(PettingzooWrap):
class BaseWrapper(PZBaseWrapper):
def __init__(self, env):
"""
Creates a wrapper around `env`. Extend this class to create changes to the space.
Expand Down
Loading