mirror of
https://github.com/Farama-Foundation/Gymnasium.git
synced 2025-08-19 13:32:03 +00:00
Co-authored-by: Kallinteris Andreas <30759571+Kallinteris-Andreas@users.noreply.github.com> Co-authored-by: Jet <38184875+jjshoots@users.noreply.github.com> Co-authored-by: Omar Younis <42100908+younik@users.noreply.github.com>
69 lines
1.6 KiB
Markdown
69 lines
1.6 KiB
Markdown
---
|
|
title: Vector
|
|
---
|
|
|
|
# Vector environments
|
|
|
|
```{toctree}
|
|
:hidden:
|
|
vector/wrappers
|
|
vector/async_vector_env
|
|
vector/sync_vector_env
|
|
vector/utils
|
|
```
|
|
|
|
## Gymnasium.vector.VectorEnv
|
|
|
|
```{eval-rst}
|
|
.. autoclass:: gymnasium.vector.VectorEnv
|
|
```
|
|
|
|
### Methods
|
|
|
|
```{eval-rst}
|
|
.. automethod:: gymnasium.vector.VectorEnv.reset
|
|
.. automethod:: gymnasium.vector.VectorEnv.step
|
|
.. automethod:: gymnasium.vector.VectorEnv.close
|
|
```
|
|
|
|
### Attributes
|
|
|
|
```{eval-rst}
|
|
.. autoattribute:: gymnasium.vector.VectorEnv.num_envs
|
|
|
|
The number of sub-environments in the vector environment.
|
|
|
|
.. autoattribute:: gymnasium.vector.VectorEnv.action_space
|
|
|
|
The (batched) action space. The input actions of `step` must be valid elements of `action_space`.
|
|
|
|
.. autoattribute:: gymnasium.vector.VectorEnv.observation_space
|
|
|
|
The (batched) observation space. The observations returned by `reset` and `step` are valid elements of `observation_space`.
|
|
|
|
.. autoattribute:: gymnasium.vector.VectorEnv.single_action_space
|
|
|
|
The action space of a sub-environment.
|
|
|
|
.. autoattribute:: gymnasium.vector.VectorEnv.single_observation_space
|
|
|
|
The observation space of an environment copy.
|
|
|
|
.. autoattribute:: gymnasium.vector.VectorEnv.spec
|
|
|
|
The ``EnvSpec`` of the environment normally set during :py:meth:`gymnasium.make_vec`
|
|
```
|
|
|
|
### Additional Methods
|
|
|
|
```{eval-rst}
|
|
.. autoproperty:: gymnasium.vector.VectorEnv.unwrapped
|
|
.. autoproperty:: gymnasium.vector.VectorEnv.np_random
|
|
```
|
|
|
|
## Making Vector Environments
|
|
|
|
```{eval-rst}
|
|
To create vector environments, gymnasium provides :func:`gymnasium.make_vec` as an equivalent function to :func:`gymnasium.make`.
|
|
```
|