Skip to main content

ThresholdOtsuExt

Trait ThresholdOtsuExt 

Source
pub trait ThresholdOtsuExt<T> {
    type Output;

    // Required method
    fn threshold_otsu(&self) -> Result<Self::Output, Error>;
}
Expand description

Runs the Otsu thresholding algorithm on a type T.

Required Associated Types§

Source

type Output

The Otsu thresholding output is a binary image.

Required Methods§

Source

fn threshold_otsu(&self) -> Result<Self::Output, Error>

Run the Otsu threshold algorithm.

Due to Otsu threshold algorithm specifying a greyscale image, all current implementations assume a single channel image; otherwise, an error is returned.

§Errors

Returns a ChannelDimensionMismatch error if more than one channel exists.

Dyn Compatibility§

This trait is dyn compatible.

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

Implementations on Foreign Types§

Source§

impl<T, U> ThresholdOtsuExt<T> for ArrayBase<U, Ix3>
where U: Data<Elem = T>, T: Copy + Clone + Ord + Num + NumAssignOps + ToPrimitive + FromPrimitive,

Implementors§

Source§

impl<T, U, C> ThresholdOtsuExt<T> for ImageBase<U, C>
where U: Data<Elem = T>, Image<U, C>: Clone, T: Copy + Clone + Ord + Num + NumAssignOps + ToPrimitive + FromPrimitive + PixelBound, C: ColourModel,