Trait renforce::environment::Environment
[−]
[src]
pub trait Environment {
type State: Space;
type Action: Space;
fn state_space(&self) -> Self::State;
fn action_space(&self) -> Self::Action;
fn step(&mut self,
action: &Self::Action::Element)
-> Observation<Self::State>;
fn reset(&mut self) -> Observation<Self::State>;
fn render(&self);
}Environment Trait
Represents an interactive environment
Associated Types
type State: Space
The type of State Space used by this Environment
type Action: Space
The type of Action Space used by this Environment
Required Methods
fn state_space(&self) -> Self::State
Returns the state space used by this Environment
fn action_space(&self) -> Self::Action
Returns the action space used by this Environment
fn step(&mut self, action: &Self::Action::Element) -> Observation<Self::State>
Performs action in environment and returns the observed result
fn reset(&mut self) -> Observation<Self::State>
Resets the environment to its initial configuration
fn render(&self)
Displays the environment