pub struct Relu;Implementations§
Trait Implementations§
source§impl Module for Relu
impl Module for Relu
type Input = Tensor
type Output = Tensor
fn forward(&self, input: &Self::Input) -> Self::Output
fn gather_params(&self, params: &mut HashMap<usize, Tensor>)
fn update_params(&self, params: &mut HashMap<usize, Tensor>)
fn gather_named_params( &self, prefix: &str, params: &mut HashMap<String, Tensor> )
fn update_named_params( &self, prefix: &str, params: &mut HashMap<String, Tensor> )
fn params(&self) -> HashMap<usize, Tensor>
fn named_params(&self, prefix: &str) -> HashMap<String, Tensor>
fn to_safetensors<P>(&self, filename: P)
fn update_by_safetensors<P>(&self, filenames: &[P], device: impl AsDevice)
impl Copy for Relu
impl NonTrainableModule for Relu
Auto Trait Implementations§
impl Freeze for Relu
impl RefUnwindSafe for Relu
impl Send for Relu
impl Sync for Relu
impl Unpin for Relu
impl UnwindSafe for Relu
Blanket Implementations§
source§impl<T, M> ApplyModule<M> for Twhere
M: Module<Input = T>,
impl<T, M> ApplyModule<M> for Twhere
M: Module<Input = T>,
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