Mask

Type Alias Mask 

Source
pub type Mask = Array2<u8>;
Expand description

A boolean mask indicating for each pixel whether it belongs to the object or not.

Aliased Type§

pub struct Mask { /* private fields */ }

Trait Implementations§

Source§

impl From<&Rle> for Mask

Source§

fn from(rle: &Rle) -> Self

Converts a RLE to its uncompressed mask.

Source§

impl TryFrom<&PolygonsRS> for Mask

Source§

fn try_from(poly_ann: &PolygonsRS) -> Result<Self, Self::Error>

Create a mask from a compressed polygon representation.

Source§

type Error = MaskError

The type returned in the event of a conversion error.
Source§

impl TryFrom<&Segmentation> for Mask

Source§

type Error = MaskError

The type returned in the event of a conversion error.
Source§

fn try_from(coco_segmentation: &Segmentation) -> Result<Self, Self::Error>

Performs the conversion.