Struct pointcloud::label_sources::VecLabels [−][src]
pub struct VecLabels { /* fields omitted */ }
Uses a vector to label your data. It can be 1 hot encoded, but if you do that you should use SmallIntLabels
Implementations
impl VecLabels
[src]
impl VecLabels
[src]pub fn new(
labels: Vec<f32>,
label_dim: usize,
mask: Option<Vec<bool>>
) -> VecLabels
[src]
labels: Vec<f32>,
label_dim: usize,
mask: Option<Vec<bool>>
) -> VecLabels
Creates a new vec label.
pub fn dim(&self) -> usize
[src]
The dimension of the vectors this labelset contains
pub fn one_hot_to_int(&self) -> SmallIntLabels
[src]
coverts a one-hot encoding to a integer label set
pub fn binary_to_int(&self) -> SmallIntLabels
[src]
coverts a binary encoding to a integer label set
Trait Implementations
impl LabelSet for VecLabels
[src]
impl LabelSet for VecLabels
[src]type Label = [f32]
Underlying type.
type LabelSummary = VecSummary
Summary of a set of labels
fn len(&self) -> usize
[src]
fn is_empty(&self) -> bool
[src]
fn label(&self, pn: usize) -> PointCloudResult<Option<&Self::Label>>
[src]
fn label_summary(
&self,
pns: &[usize]
) -> PointCloudResult<SummaryCounter<Self::LabelSummary>>
[src]
&self,
pns: &[usize]
) -> PointCloudResult<SummaryCounter<Self::LabelSummary>>
Auto Trait Implementations
impl RefUnwindSafe for VecLabels
impl RefUnwindSafe for VecLabels
impl UnwindSafe for VecLabels
impl UnwindSafe for VecLabels