pub struct MultiDevicesTrainStep<LC: LearningComponentsTypes> { /* private fields */ }Expand description
Multi devices train step.
Implementations§
Source§impl<LC: LearningComponentsTypes> MultiDevicesTrainStep<LC>
impl<LC: LearningComponentsTypes> MultiDevicesTrainStep<LC>
Sourcepub fn new(devices: &[Device<TrainingBackend<LC>>]) -> Self
pub fn new(devices: &[Device<TrainingBackend<LC>>]) -> Self
Sourcepub fn step<'a>(
&self,
dataloaders: &mut [Box<dyn DataLoaderIterator<<<LC as LearningComponentsTypes>::TrainingModel as TrainStep>::Input> + 'a>],
model: &TrainingModel<LC>,
) -> (Vec<MultiTrainOutput<<<LC as LearningComponentsTypes>::TrainingModel as TrainStep>::Output>>, Progress)
pub fn step<'a>( &self, dataloaders: &mut [Box<dyn DataLoaderIterator<<<LC as LearningComponentsTypes>::TrainingModel as TrainStep>::Input> + 'a>], model: &TrainingModel<LC>, ) -> (Vec<MultiTrainOutput<<<LC as LearningComponentsTypes>::TrainingModel as TrainStep>::Output>>, Progress)
Auto Trait Implementations§
impl<LC> Freeze for MultiDevicesTrainStep<LC>
impl<LC> RefUnwindSafe for MultiDevicesTrainStep<LC>
impl<LC> Send for MultiDevicesTrainStep<LC>
impl<LC> !Sync for MultiDevicesTrainStep<LC>
impl<LC> Unpin for MultiDevicesTrainStep<LC>
impl<LC> UnwindSafe for MultiDevicesTrainStep<LC>
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more