Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] BatchedEnv crashes when EnvBase has non-empty batch_size #773

Closed
matteobettini opened this issue Dec 31, 2022 · 0 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@matteobettini
Copy link
Contributor

Describe the bug

In the function get_metadata() of _BatchedEnv the tensordict expand method is called in a wrong manner:

self.meta_data = get_env_metadata(
                create_env_fn[0], create_env_kwargs[0]
            ).expand(self.num_workers)

As per docs, expand should be called with an argument which is the concatenation of the new dims to the old dims

To Reproduce

Create a ParallelEnv from a BaseEnv with non-empy batch_size

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants