dacbench.envs.modea
Module Contents
Classes
Abstract template for environments |
- class dacbench.envs.modea.ModeaEnv(config)
Bases:
dacbench.AbstractEnvAbstract template for environments
- reset(self)
Reset environment
- Returns
Environment state
- Return type
state
- step(self, action)
Execute environment step
- Parameters
action – Action to take
- Returns
state – Environment state
reward – Environment reward
done (bool) – Run finished flag
info (dict) – Additional metainfo
- update_parameters(self)
- restart(self)
- determineRegime(self)
- get_default_state(self, _)
- get_default_reward(self, _)
- close(self)
Override close in your subclass to perform any necessary cleanup.
Environments will automatically close() themselves when garbage collected or when the program exits.
- switchConfiguration(self, opts)
- setConfigurationParameters(self, functions, parameters)
- ensureFullLengthRepresentation(self, representation)
Given a (partial) representation, ensure that it is padded to become a full length customizedES representation, consisting of the required number of structure, population and parameter values. >>> ensureFullLengthRepresentation([]) [0,0,0,0,0,0,0,0,0,0,0, None,None, None,None,None,None,None,None,None,None,None,None,None,None,None] :param representation: List representation of a customizedES instance to check and pad if needed :return: Guaranteed full-length version of the representation