Stages

Stage

class gem_controllers.stages.stage.Stage[source]

The stage is the basic module in the gem-controller structure.

__call__(state, reference)[source]

The stages control function.

Parameters
  • state (numpy.ndarray) – The denormalized state of the environment.

  • reference (numpy.ndarray) – The actual reference value for this stage.

Returns

The new reference-value for the next state.

Return type

numpy.ndarray

reset()[source]

Resets the stage to an initial state (e.g. before a new episode starts).

tune(env, env_id, **kwargs)[source]

Fits the stages parameters to the passed environment.

Parameters
  • env (gym_electric_motor.ElectricMotorEnvironment) – The environment to be controlled.

  • env_id (str) – The id of the environment.

  • **kwargs (dict) – Optional further parameters to tune the stages.