class_docstr: An in-progress episode.
  
  Compared to EpisodeBatch, this datatype does less checking, only
  contains one episodes, and uses lists instead of numpy arrays to make
  stepping faster.
  
  Args:
      env (Environment): The environment the trajectory is being collected
          in.
      initial_observation (np.ndarray): The first observation. If None, the
          environment will be reset to generate this observation.
      episode_info (dict[str, np.ndarray]): Info for this episode.
  
  Raises:
      ValueError: if either initial_observation and episode_info is passed in
          but not the other. Either both or neither should be passed in.
docstr: Step the episode using an action from an agent.
  
  Args:
      action (np.ndarray): The action taken by the agent.
      agent_info (dict[str, np.ndarray]): Extra agent information.
  
  Returns:
      np.ndarray: The new observation from the environment.
docstr_tok: ["Step","the","episode","using","an","action","from","an","agent",".","Args",":","action","(","np.ndarray",")",":","The","action","taken","by","the","agent",".","agent_info","(","dict","[","str",",","np.ndarray","]",")",":","Extra","agent","information",".","Returns",":","np.ndarray",":","The","new","observation","from","the","environment","."]
code: def step(self, action, agent_info):
      """Step the episode using an action from an agent.
  
      Args:
          action (np.ndarray): The action taken by the agent.
          agent_info (dict[str, np.ndarray]): Extra agent information.
  
      Returns:
          np.ndarray: The new observation from the environment.
  
      """
      es = self.env.step(action)
  
      self.observations.append(es.observation)
      self.rewards.append(es.reward)
      self.actions.append(es.action)
      for k, v in agent_info.items():
          self.agent_infos[k].append(v)
      for k, v in es.env_info.items():
          self.env_infos[k].append(v)
      self.step_types.append(es.step_type)
      return es.observation
  
imports: import collections
  import numpy
  from garage import EpisodeBatch, StepType
label_desc: Use image node_id 2 for calling the InProgressEpisode obj's underlying member method code with example usage: obj.step(action, agent_info) and returns: es