env_wrapper
EnvironmentWrapper
Bases: Wrapper
, Registerable
Base class for all environment wrappers in OmniGibson. In general, reset(), step(), and observation_spec() should be overwritten
Parameters:
Name | Type | Description | Default |
---|---|---|---|
env |
OmniGibsonEnv
|
The environment to wrap. |
required |
Source code in omnigibson/envs/env_wrapper.py
observation_spec()
By default, grabs the normal environment observation_spec
Returns:
Name | Type | Description |
---|---|---|
dict |
Observations from the environment |
reset()
By default, run the normal environment reset() function
Returns:
Name | Type | Description |
---|---|---|
dict |
Environment observation space after reset occurs |
step(action)
By default, run the normal environment step() function
Parameters:
Name | Type | Description | Default |
---|---|---|---|
action |
array
|
action to take in environment |
required |
Returns:
Type | Description |
---|---|
4-tuple: - (dict) observations from the environment - (float) reward from the environment - (bool) whether the current episode is completed or not - (dict) misc information |
Source code in omnigibson/envs/env_wrapper.py
create_wrapper(env)
Wraps environment @env with wrapper defined by env.wrapper_config