Shortcuts

FrameSkipTransform

class torchrl.envs.transforms.FrameSkipTransform(frame_skip: int = 1)[source]

A frame-skip transform.

This transform applies the same action repeatedly in the parent environment, which improves stability on certain training sota-implementations.

Parameters:

frame_skip (int, optional) – a positive integer representing the number of frames during which the same action must be applied.

forward(tensordict)[source]

Reads the input tensordict, and for the selected keys, applies the transform.

Docs

Access comprehensive developer documentation for PyTorch

View Docs

Tutorials

Get in-depth tutorials for beginners and advanced developers

View Tutorials

Resources

Find development resources and get your questions answered

View Resources