pub struct ConnectedStats<B: Backend> {
pub area: Tensor<B, 1, Int>,
pub top: Tensor<B, 1, Int>,
pub left: Tensor<B, 1, Int>,
pub right: Tensor<B, 1, Int>,
pub bottom: Tensor<B, 1, Int>,
pub max_label: Tensor<B, 1, Int>,
}Expand description
Stats collected by the connected components analysis
Disabled analyses may be aliased to labels
Fields§
§area: Tensor<B, 1, Int>Total area of each component
top: Tensor<B, 1, Int>Topmost y coordinate in the component
left: Tensor<B, 1, Int>Leftmost x coordinate in the component
right: Tensor<B, 1, Int>Rightmost x coordinate in the component
bottom: Tensor<B, 1, Int>Bottommost y coordinate in the component
max_label: Tensor<B, 1, Int>Scalar tensor of the max label
Implementations§
Source§impl<B: Backend> ConnectedStats<B>
impl<B: Backend> ConnectedStats<B>
Sourcepub fn into_primitive(self) -> ConnectedStatsPrimitive<B>
pub fn into_primitive(self) -> ConnectedStatsPrimitive<B>
Convert a connected stats into the corresponding primitive
Trait Implementations§
Source§impl<B: Clone + Backend> Clone for ConnectedStats<B>
impl<B: Clone + Backend> Clone for ConnectedStats<B>
Source§fn clone(&self) -> ConnectedStats<B>
fn clone(&self) -> ConnectedStats<B>
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl<B: Backend> From<ConnectedStatsPrimitive<B>> for ConnectedStats<B>
impl<B: Backend> From<ConnectedStatsPrimitive<B>> for ConnectedStats<B>
Source§fn from(value: ConnectedStatsPrimitive<B>) -> Self
fn from(value: ConnectedStatsPrimitive<B>) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl<B> Freeze for ConnectedStats<B>
impl<B> RefUnwindSafe for ConnectedStats<B>
impl<B> Send for ConnectedStats<B>
impl<B> Sync for ConnectedStats<B>
impl<B> Unpin for ConnectedStats<B>
impl<B> UnwindSafe for ConnectedStats<B>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more