dacbench.wrappers.observation_wrapper
Module Contents
Classes
Wrapper covert observations spaces to spaces.Box for convenience |
- class dacbench.wrappers.observation_wrapper.ObservationWrapper(env)
Bases:
gym.WrapperWrapper covert observations spaces to spaces.Box for convenience Currently only supports Dict -> Box
- __setattr__(self, name, value)
Set attribute in wrapper if available and in env if not
- Parameters
name (str) – Attribute to set
value – Value to set attribute to
- __getattribute__(self, name)
Get attribute value of wrapper if available and of env if not
- Parameters
name (str) – Attribute to get
- Returns
Value of given name
- Return type
value
- step(self, action)
Execute environment step and record distance
- Parameters
action (int) – action to execute
- Returns
state, reward, done, metainfo
- Return type
np.array, float, bool, dict
- reset(self)
Execute environment step and record distance
- Returns
state
- Return type
np.array
- flatten(self, state_dict)