Python gym.RewardWrapper() Examples
The following are 30
code examples of gym.RewardWrapper().
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example.
You may also want to check out all available functions/classes of the module
gym
, or try the search function
.
Example #1
Source File: atari_wrappers.py From ape-x with Apache License 2.0 | 6 votes |
def _render(self, mode='human', close=False): if close: return if mode == 'human': from gym.envs.classic_control import rendering if self.viewer is None: self.viewer = rendering.SimpleImageViewer() self.viewer.imshow(np.max(np.stack(self._obs_buffer), axis=0)) return np.max(np.stack(self._obs_buffer), axis=0) else: return np.max(np.stack(self._obs_buffer), axis=0) # class ClipRewardEnv(gym.RewardWrapper): # def _reward(self, reward): # """Bin reward to {+1, 0, -1} by its sign.""" # return np.sign(reward)
Example #2
Source File: env_wrappers.py From sample-factory with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #3
Source File: atari_wrappers.py From rl_algorithms with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #4
Source File: atari_wrappers.py From pytorch-pommerman-rl with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #5
Source File: atari_wrappers.py From sonic_contest with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #6
Source File: wrappers.py From RLs with Apache License 2.0 | 5 votes |
def __init__(self, env): """ clips the reward to {+1, 0, -1} by its sign. :param env: (Gym Environment) the environment """ gym.RewardWrapper.__init__(self, env)
Example #7
Source File: atari.py From ia-course with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #8
Source File: atari.py From ia-course with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #9
Source File: openai_atari_wrapper.py From cherry with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #10
Source File: reward_clipper_wrapper.py From cherry with Apache License 2.0 | 5 votes |
def __init__(self, env): super(Wrapper, self).__init__(env) gym.RewardWrapper.__init__(self, env)
Example #11
Source File: atari_wrappers.py From ray with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #12
Source File: atari_wrappers.py From ray with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #13
Source File: atari_wrappers.py From self-imitation-learning with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #14
Source File: ppo_atari_visual.py From cleanrl with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #15
Source File: run_humanoid.py From baselines with MIT License | 5 votes |
def __init__(self, env, scale): gym.RewardWrapper.__init__(self, env) self.scale = scale
Example #16
Source File: atari_wrappers.py From baselines with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #17
Source File: atari.py From Hands-On-Intelligent-Agents-with-OpenAI-Gym with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #18
Source File: atari.py From Hands-On-Intelligent-Agents-with-OpenAI-Gym with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #19
Source File: atari.py From rl with MIT License | 5 votes |
def __init__(self, env): """ clips the reward to {+1, 0, -1} by its sign. :param env: (Gym Environment) the environment """ gym.RewardWrapper.__init__(self, env)
Example #20
Source File: wrappers.py From football with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #21
Source File: wrappers.py From football with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env) self._collected_checkpoints = {} self._num_checkpoints = 10 self._checkpoint_reward = 0.1
Example #22
Source File: atari_wrappers.py From nnabla-examples with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #23
Source File: env_wrappers.py From RLcycle with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #24
Source File: atari_wrappers.py From vel with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #25
Source File: atari_wrappers.py From DRL_DeliveryDuel with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #26
Source File: run_humanoid.py From HardRLWithYoutube with MIT License | 5 votes |
def __init__(self, env, scale): gym.RewardWrapper.__init__(self, env) self.scale = scale
Example #27
Source File: atari_wrappers.py From HardRLWithYoutube with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #28
Source File: atari_wrappers.py From chainerrl with MIT License | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #29
Source File: atari_wrappers.py From Reinforcement_Learning_for_Traffic_Light_Control with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)
Example #30
Source File: atari_wrappers.py From Reinforcement_Learning_for_Traffic_Light_Control with Apache License 2.0 | 5 votes |
def __init__(self, env): gym.RewardWrapper.__init__(self, env)