Skip to main content

filter2d

Function filter2d 

Source
pub fn filter2d(input: &Tensor, kernel: &Tensor) -> Result<Tensor, ImgProcError>
Expand description

Generic 2D convolution with a custom kernel. 2D convolution of a single-channel [H, W, 1] image with an arbitrary kernel [KH, KW, 1].

Zero-pads the borders. Output has the same shape as input.