def prepare_env_eval(self, env):
        """
            Applies custom wrapper to the environment as necessary
            Only changes eval behavior
        """
        limit_episode_length = self.env_config.limit_episode_length
        if limit_episode_length > 0:
            env = MaxStepWrapper(env, limit_episode_length)

        if self.agent_mode not in ['eval_deterministic_local', 'eval_stochastic_local']:
            env = EvalTensorplexMonitor(
                env,
                eval_id=self.agent_id,
                fetch_parameter=self.fetch_parameter,
                session_config=self.session_config,
            )

        env_category = self.env_config.env_name.split(':')[0]
        if self.env_config.video.record_video and self.agent_id == 0:
            # gym video recording not supported due to bug in OpenAI gym
            # https://github.com/openai/gym/issues/1050
            env = VideoWrapper(env, self.env_config, self.session_config)
        return env

            Applies custom wrapper to the environment as necessary
            Only changes eval behavior
        
surreal/agent/base.py