proroklab / VectorizedMultiAgentSimulator

VMAS is a vectorized differentiable simulator designed for efficient Multi-Agent Reinforcement Learning benchmarking. It is comprised of a vectorized 2D physics engine written in PyTorch and a set of challenging multi-robot scenarios. Additional scenarios can be implemented through a simple and modular interface.
https://vmas.readthedocs.io
GNU General Public License v3.0
335 stars 69 forks source link

[Feature] Adding pre and post step to BaseScenario #112

Closed Zartris closed 4 months ago

Zartris commented 4 months ago

fixes https://github.com/proroklab/VectorizedMultiAgentSimulator/issues/110

Zartris commented 4 months ago

Should maybe remove the returns however the flake8 was not happy about empty methods.

matteobettini commented 4 months ago

Looks good!

Can we simplify the docstring of poststep? I don’t think we need to go into cat and unsqueeze, just appending to a list is fine

matteobettini commented 4 months ago

Also maybe an underscore in the name like post_step

Zartris commented 4 months ago

Done

matteobettini commented 4 months ago

Fabulous, last addition I missed: can you add them to the BaseScenarion docstring under the optional methods?

Zartris commented 4 months ago

Like this?

matteobettini commented 4 months ago

Yeah just remove the added line