Struct border_core::TrainerConfig
source · pub struct TrainerConfig { /* private fields */ }
Expand description
Configuration of Trainer
.
Implementations§
source§impl TrainerConfig
impl TrainerConfig
sourcepub fn eval_interval(self, v: usize) -> Self
pub fn eval_interval(self, v: usize) -> Self
Sets the interval of evaluation in optimization steps.
sourcepub fn eval_threshold(self, v: f32) -> Self
pub fn eval_threshold(self, v: f32) -> Self
Sets the evaluation threshold.
sourcepub fn model_dir<T: Into<String>>(self, model_dir: T) -> Self
pub fn model_dir<T: Into<String>>(self, model_dir: T) -> Self
Sets the directory the trained model being saved.
sourcepub fn opt_interval(self, opt_interval: usize) -> Self
pub fn opt_interval(self, opt_interval: usize) -> Self
Sets the interval of optimization in environment steps.
sourcepub fn record_interval(self, record_interval: usize) -> Self
pub fn record_interval(self, record_interval: usize) -> Self
Sets the interval of recording in optimization steps.
sourcepub fn save_interval(self, save_interval: usize) -> Self
pub fn save_interval(self, save_interval: usize) -> Self
Sets the interval of saving in optimization steps.
Trait Implementations§
source§impl Clone for TrainerConfig
impl Clone for TrainerConfig
source§fn clone(&self) -> TrainerConfig
fn clone(&self) -> TrainerConfig
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for TrainerConfig
impl Debug for TrainerConfig
source§impl Default for TrainerConfig
impl Default for TrainerConfig
source§impl<'de> Deserialize<'de> for TrainerConfig
impl<'de> Deserialize<'de> for TrainerConfig
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where __D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq<TrainerConfig> for TrainerConfig
impl PartialEq<TrainerConfig> for TrainerConfig
source§fn eq(&self, other: &TrainerConfig) -> bool
fn eq(&self, other: &TrainerConfig) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for TrainerConfig
impl Serialize for TrainerConfig
impl StructuralPartialEq for TrainerConfig
Auto Trait Implementations§
impl RefUnwindSafe for TrainerConfig
impl Send for TrainerConfig
impl Sync for TrainerConfig
impl Unpin for TrainerConfig
impl UnwindSafe for TrainerConfig
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more