PreProcessingWrapper

class maze.core.wrappers.observation_preprocessing.preprocessing_wrapper.PreProcessingWrapper(env: StructuredEnvSpacesMixin, pre_processor_mapping: List[Dict[str, Any]])

An observation pre-processing wrapper. It provides functionality for:

  • pre-processing observations (flattening, one-hot encoding, …)

  • adopting the observation spaces accordingly

Parameters:
  • env – Environment/wrapper to wrap.

  • pre_processor_mapping – The pre-processing configuration. Example mappings can be found in our reference documentation.

clone_from(env: PreProcessingWrapper) None

(overrides SimulatedEnvMixin)

implementation of SimulatedEnvMixin.

observation(observation: Any) Any

(overrides ObservationWrapper)

Pre-processes observations.

param observation:

The observation to be pre-processed.

return:

The pre-processed observation.