oa::ml::EnvironmentSpec

Complete single-agent environment schema shared by native and adapter paths.

StRust public API

Declaration

pub struct EnvironmentSpec { /* private fields */ }
Public Rust declaration.

Public Methods

pub const fn observation(&self) -> &EnvironmentSpace
pub const fn action(&self) -> &EnvironmentSpace
pub const fn reward(&self) -> &EnvironmentSpace
pub const fn terminated(&self) -> &EnvironmentSpace
pub const fn truncated(&self) -> &EnvironmentSpace
pub fn validate_reset( &self, observation: &Matrix, environments: u32, ) -> Result<()>
pub fn validate_action(&self, action: &Matrix, environments: u32) -> Result<()>
pub fn validate_transition( &self, action: &Matrix, transition: &EnvironmentTransition, environments: u32, ) -> Result<()>
fn clone(&self) -> EnvironmentSpec
fn fmt(&self, f: &mut Formatter<'_>) -> Result

Associated Functions

pub fn new( observation: EnvironmentSpace, action: EnvironmentSpace, reward: EnvironmentSpace, terminated: EnvironmentSpace, truncated: EnvironmentSpace, ) -> Result<Self>

Public Method Documentation

pub const fn observation( &self ) -> &EnvironmentSpace
No public source comment is attached to this declaration.
pub const fn action( &self ) -> &EnvironmentSpace
No public source comment is attached to this declaration.
pub const fn reward( &self ) -> &EnvironmentSpace
No public source comment is attached to this declaration.
pub const fn terminated( &self ) -> &EnvironmentSpace
No public source comment is attached to this declaration.
pub const fn truncated( &self ) -> &EnvironmentSpace
No public source comment is attached to this declaration.
pub fn validate_reset( &self, observation: &Matrix, environments: u32, ) -> Result<()>
No public source comment is attached to this declaration.
pub fn validate_action(&self, action: &Matrix, environments: u32) -> Result<()>
No public source comment is attached to this declaration.
pub fn validate_transition( &self, action: &Matrix, transition: &EnvironmentTransition, environments: u32, ) -> Result<()>
No public source comment is attached to this declaration.
fn clone( &self ) -> EnvironmentSpec
No public source comment is attached to this declaration.
fn fmt( &self, f: &mut Formatter<'_> ) -> Result
No public source comment is attached to this declaration.
pub fn new( observation: EnvironmentSpace, action: EnvironmentSpace, reward: EnvironmentSpace, terminated: EnvironmentSpace, truncated: EnvironmentSpace ) -> Result<Self>
No public source comment is attached to this declaration.