collect_render_rollouts#
- torchrl.render.collect_render_rollouts(env: Any, policy: Any, config: RenderConfig) RenderResult[source]#
Collects sequential render rollouts.
EnvBaseenvironments are rolled out throughrollout(); other environments fall back to a duck-typed reset/step loop. Captured frames span the initial state through the terminal state of each trajectory.- Parameters:
env – Environment returned by
torchrl.render.make_render_env().policy – TensorDict-compatible policy.
config – Render configuration.
- Returns:
A render result containing trajectories and in-memory frames.