iocrn_stepper
RL4CRN.agent2env_interface.iocrn_stepper
Concrete stepper for IO-CRN environments.
This stepper applies an action by adding a reaction to the environment state
via state.add_reaction(action) and then calling state.compile().
Limitations
Parameter-setting is not implemented. If the state reports unknown parameters
(state.num_unknown_params > 0), step raises NotImplementedError.
Assumptions about state :
- has attribute
num_unknown_params: int - provides methods
add_reaction(action)andcompile()
IOCRNStepper
Bases: AbstractStepper
Stepper that adds a reaction to the CRN state and recompiles it.
The action is applied through state.add_reaction(action). Afterward,
state.compile() is called to finalize the updated state.
| RAISES | DESCRIPTION |
|---|---|
NotImplementedError
|
If |
step(state, action)
Apply action to state by adding a reaction and compiling.
| PARAMETER | DESCRIPTION |
|---|---|
state
|
Environment state to be modified (see module docstring for the required interface).
|
action
|
Reaction/action object passed to
|
| RAISES | DESCRIPTION |
|---|---|
NotImplementedError
|
If the state contains unknown parameters and would
require setting them ( |