Skip to content

MultithreadedEnvs and Trajectories #920

Open
@HenriDeh

Description

@HenriDeh

I'm creating this issue to pin down that MultiThreadedEnvs do not currently work.

It steps each inner env in parallel and stores the traces, but there's nothing that can be done with that currently as we would need to store each separate trajectory (in the seminal sense of "trajectory") contiguously in the replay buffer. Right now with the caching implementation, they can only be mixed up in the storage.

Options I see to address that

  1. extend trajectories to have N (number of parallel envs) containers, each will pertain to one env and have a capacity of 1/Nth the total capacity of the trajectory.
  2. partition the container into N partitions.
  3. Create a small Trajectory for each env and append to the main Trajectory at the end of an episode.

I clearly prefer the first option, it is straightfoward and probably the most efficient.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions