class_docstr: Executes the provided policies in an Agent Deployment setting.
  
  Policies are executed until the rollout_done event is set, indicating that the rollout has been finished.
  Then, a final reset is sent and execution stops. Expected to be run on a separate thread alongside the
  agent deployment running on the main thread.
  
  :param env: Environment to step.
  :param policy: Structured policy working with structured environments.
  :param rollout_done_event: event indicating that the rollout has been finished.
code: def __init__(
      self,
      env: ExternalCoreEnv,
      policy: Policy,
      rollout_done_event: Event,
      exception_queue: Queue,
  ):
      self.env = env
      self.policy = policy
      self.rollout_done_event = rollout_done_event
      self.exception_queue = exception_queue
  
file_path: maze/maze/core/agent_deployment/policy_executor.py
imports: import traceback
  from collections import namedtuple
  from queue import Queue
  from threading import Event
  from maze.core.agent.policy import Policy
  from maze.core.agent_deployment.external_core_env import ExternalCoreEnv
  from maze.core.log_stats.log_stats_env import LogStatsEnv
label_desc: Use image node_id 1 to create a new PolicyExecutor object  with example: obj = PolicyExecutor(env, policy, rollout_done_event, exception_queue)