code: def wrap_deepmind(env, episode_life=True, clip_rewards=True, frame_stack=False, scale=False):
      
      if episode_life:
          env = EpisodicLifeEnv(env)
      if 'FIRE' in env.unwrapped.get_action_meanings():
          env = FireResetEnv(env)
      env = WarpFrame(env)
      if scale:
          env = ScaledFloatFrame(env)
      if clip_rewards:
          env = ClipRewardEnv(env)
      if frame_stack:
          env = FrameStack(env, 4)
      return env
docs: Configure environment for DeepMind-style Atari.