Skip to content

[Feature Request] Allow custom video settings to be passed into CSVExperiment.add_video #2258

@N00bcak

Description

@N00bcak

Motivation

Please outline the motivation for the proposal.
Is your feature request related to a problem? e.g., "I'm always frustrated when [...]".
If this is related to another issue, please link here too.

NOTE: This relates to a personal issue encountered with a custom TorchRL environment which has a known good render function.

Currently, VideoRecorder (and its downstream logger CSVLogger) does not allow for custom video settings to be passed when dumping environment rollouts (via pyAV/torchvision)

These video settings are actually FFmpeg settings which may have undesirable defaults from pyAV/torchvision, resulting in blurry/low-quality videos.

Among the various other reasons there may be to play with the video dumping settings, it may conversely be desirable to lower the visual fidelity of the video for better performance.

Solution

A clear and concise description of what you want to happen.

Expose kwargs in CSVExperiment.add_video to torchvision.io.write_video, allowing end-user to pass FFmpeg kwargs when recording rollouts.

Checklist

  • I have checked that there is no similar issue in the repo (required)

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions