Expand description
Minimum pool with 2d kernel that operates on images (3d) and batches of images (4d). Each patch reduces to the minimum of the values in the patch.
Generics:
KERNEL_SIZE
: The size of the kernel applied to both width and height of the images.STRIDE
: How far to move the kernel each step. Defaults to1
PADDING
: How much zero padding to add around the images. Defaults to0
.
Trait Implementations
sourceimpl<const K: usize, const S: usize, const P: usize> CanUpdateWithGradients for MinPool2D<K, S, P>
impl<const K: usize, const S: usize, const P: usize> CanUpdateWithGradients for MinPool2D<K, S, P>
sourcefn update<G: GradientProvider>(&mut self, _: &mut G, _: &mut UnusedTensors)
fn update<G: GradientProvider>(&mut self, _: &mut G, _: &mut UnusedTensors)
Updates self given the GradientProvider. When any parameters that
are NOT present in
G
, then this function should
add the tensor’s UniqueId to UnusedTensors. Read moresourceimpl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Clone for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Clone for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
sourceimpl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Debug for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Debug for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
sourceimpl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Default for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Default for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
sourceimpl<const K: usize, const S: usize, const P: usize> LoadFromNpz for MinPool2D<K, S, P>
impl<const K: usize, const S: usize, const P: usize> LoadFromNpz for MinPool2D<K, S, P>
sourceimpl<const K: usize, const S: usize, const P: usize, const C: usize, const H: usize, const W: usize, T: Tape> Module<Tensor3D<C, H, W, T>> for MinPool2D<K, S, P>
impl<const K: usize, const S: usize, const P: usize, const C: usize, const H: usize, const W: usize, T: Tape> Module<Tensor3D<C, H, W, T>> for MinPool2D<K, S, P>
sourceimpl<const K: usize, const S: usize, const P: usize, const B: usize, const C: usize, const H: usize, const W: usize, T: Tape> Module<Tensor4D<B, C, H, W, T>> for MinPool2D<K, S, P>
impl<const K: usize, const S: usize, const P: usize, const B: usize, const C: usize, const H: usize, const W: usize, T: Tape> Module<Tensor4D<B, C, H, W, T>> for MinPool2D<K, S, P>
sourceimpl<T, const K: usize, const S: usize, const P: usize> ModuleMut<T> for MinPool2D<K, S, P>where
Self: Module<T>,
impl<T, const K: usize, const S: usize, const P: usize> ModuleMut<T> for MinPool2D<K, S, P>where
Self: Module<T>,
Auto Trait Implementations
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> RefUnwindSafe for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Send for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Sync for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> Unpin for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
impl<const KERNEL_SIZE: usize, const STRIDE: usize, const PADDING: usize> UnwindSafe for MinPool2D<KERNEL_SIZE, STRIDE, PADDING>
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more