evorl.envs.env¶
Module Contents¶
Classes¶
Unified EvoRL Env API. |
|
Base class for an environment adapter. |
|
State of the environment. |
Data¶
API¶
- class evorl.envs.env.Env[source]¶
Bases:
abc.ABCUnified EvoRL Env API.
- abstract property action_space: evorl.envs.space.Space¶
Get the action space of the environment.
- abstract property obs_space: evorl.envs.space.Space¶
Get the observation space of the environment.
- abstract reset(key: chex.PRNGKey) evorl.envs.env.EnvState[source]¶
Reset the environment to initial state.
- abstract step(state: evorl.envs.env.EnvState, action: evorl.types.Action) evorl.envs.env.EnvState[source]¶
Take a step in the environment.
- class evorl.envs.env.EnvAdapter(env: Any)[source]¶
Bases:
evorl.envs.env.EnvBase class for an environment adapter.
Convert envs from other packages to EvoRL’s Env API.
- property unwrapped: Any¶
- evorl.envs.env.EnvResetFn¶
None
- class evorl.envs.env.EnvState[source]¶
Bases:
evorl.types.PyTreeDataState of the environment.
Include all the data needed to represent the state of the environment.
- Variables:
env_state – The internal state of the environment.
obs – The observation of the environment.
reward – The reward of the environment.
done – Whether the environment is done.
info – Extra info from the environment.
_internal – Extra internal data for the environment.
- done: evorl.types.Done¶
None
- env_state: evorl.types.EnvInternalState¶
None
- info: evorl.types.PyTreeDict¶
‘pytree_field(…)’
- obs: evorl.types.Observation¶
None
- reward: evorl.types.Reward¶
None
- evorl.envs.env.EnvStepFn¶
None