qgym.templates.state module
Generic abstract base class for States of RL environments.
All states should inherit from State
.
- class qgym.templates.state.State[source]
Bases:
Generic
[ObservationT
,ActionT
]RL State containing the current state of the problem.
- abstract obtain_observation()[source]
Observation based on the current state.
- Return type:
TypeVar
(ObservationT
)
- property rng: Generator
Return the random number generator of this environment. If none is set yet, this will generate a new one using
numpy.random.default_rng
.- Returns:
Random number generator used by this
Environment
.