pykoop.combine_episodes

combine_episodes(episodes, episode_feature=False)

Combine episodes into a data matrix.

Parameters:
  • episodes (List[Tuple[float, np.ndarray]]) – List of episode tuples. The first element of each tuple contains the episode index. The second element contains the episode data.

  • episode_feature (bool) – True if first feature of output should indicate which episode a timestep is from.

Returns:

Combined data matrix.

Return type:

np.ndarray