Skip to main content

Morphology

Trait Morphology 

pub trait Morphology {
    // Required methods
    fn erode(self, kernel: Tensor<2, Bool>, opts: MorphOptions) -> Self;
    fn dilate(self, kernel: Tensor<2, Bool>, opts: MorphOptions) -> Self;
}
Expand description

Morphology tensor operations

Required Methods§

fn erode(self, kernel: Tensor<2, Bool>, opts: MorphOptions) -> Self

Erodes this tensor using the specified kernel. Assumes NHWC layout.

fn dilate(self, kernel: Tensor<2, Bool>, opts: MorphOptions) -> Self

Dilates this tensor using the specified kernel. Assumes NHWC layout.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§

§

impl Morphology for Tensor<3, Bool>

§

impl Morphology for Tensor<3, Int>

§

impl Morphology for Tensor<3>