Wrappers
navground.learning.wrappers
-
class MaskWrapper(env: ParallelEnv, observation_indices: Iterable[int] = (), observation_keys: Iterable[str] = (), action_indices: Iterable[int] = ())
Bases: BaseParallelWrapper
This wrapper masks some of the observations and/or actions
- Parameters:
env (ParallelEnv) – The wrapped environment
observation_indices (Iterable[int]) – Which observation indices to keep (if array)
observation_keys (Iterable[str]) – Which observation keys to keep (if dict)
action_indices (Iterable[int]) – Which action indices to keep (if array)
-
class NameWrapper(env: ParallelEnv)
Bases: BaseParallelWrapper
This wrapper renames the agent using their navground tags
as prefix “tag1-tag2-…-tagn” or “agent” (if no tag is set).
Indices are appended to the predix, e.g.
agent_0, agent_1, … .
- Parameters:
env (ParallelEnv) – The wrapped environment