Skip to content

Commit

Permalink
Update spaces utils section in docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Toni-SM committed Oct 4, 2024
1 parent 2e0182b commit f77c9dc
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions docs/source/api/utils/spaces.rst
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,44 @@ Utilities to operate on gymnasium `spaces <https://gymnasium.farama.org/api/spac

<br><hr>

.. list-table::
:header-rows: 1

* - Input
- Function
- Output
* - Space sample with
|br| NumPy values
- :py:func:`~skrl.utils.spaces.torch.tensorize_space`
- Space sample with
|br| PyTorch / JAX values
* - Space sample with
|br| PyTorch / JAX values
- :py:func:`~skrl.utils.spaces.torch.untensorize_space`
- Space sample with
|br| NumPy values
* - Space sample with
|br| PyTorch / JAX values
- :py:func:`~skrl.utils.spaces.torch.flatten_tensorized_space`
- PyTorch tensor / JAX array
* - PyTorch tensor / JAX array
- :py:func:`~skrl.utils.spaces.torch.unflatten_tensorized_space`
- Space sample with
|br| PyTorch / JAX values

API (PyTorch)
-------------

.. autofunction:: skrl.utils.spaces.torch.compute_space_size

.. autofunction:: skrl.utils.spaces.torch.convert_gym_space

.. autofunction:: skrl.utils.spaces.torch.flatten_tensorized_space

.. autofunction:: skrl.utils.spaces.torch.sample_space

.. autofunction:: skrl.utils.spaces.torch.tensorize_space

.. autofunction:: skrl.utils.spaces.torch.unflatten_tensorized_space

.. autofunction:: skrl.utils.spaces.torch.untensorize_space

0 comments on commit f77c9dc

Please sign in to comment.