Skip to main content

ConvOps

Trait ConvOps 

Source
pub trait ConvOps: ConvIO {
    type InputArray;
    type OutputArray;
    type FilterArray;

    const INPUT_SIZE: usize;
    const OUTPUT_SIZE: usize;
    const FILTER_SIZE: usize;

    // Required methods
    fn init() -> Self;
    fn forward_flat(
        &self,
        input: &Self::InputArray,
        output: &mut Self::OutputArray,
    );
    fn input_from_fn<F: FnMut(usize) -> Float>(f: F) -> Self::InputArray;
    fn output_zeroed() -> Self::OutputArray;
}
Expand description

Flat-array convenience trait for generic conv code.

Required Associated Constants§

Required Associated Types§

Required Methods§

Source

fn init() -> Self

Source

fn forward_flat(&self, input: &Self::InputArray, output: &mut Self::OutputArray)

Source

fn input_from_fn<F: FnMut(usize) -> Float>(f: F) -> Self::InputArray

Source

fn output_zeroed() -> Self::OutputArray

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§

Source§

impl<const IW: usize, const IH: usize, const IC: usize, const FH: usize, const FW: usize, const OC: usize, const S: usize, const P: usize> ConvOps for Conv<IW, IH, IC, FH, FW, OC, S, P>
where [(); { _ }]:, (): ConvGeometryIsValid<IH, IW, FH, FW, S, P>,