pub struct NeighborLabelFrequencies<Label, NI> {
pub frequencies: Vec<FxHashMap<Label, usize>>,
/* private fields */
}Available on crate feature
dotgraph only.Fields§
§frequencies: Vec<FxHashMap<Label, usize>>Implementations§
Source§impl<Label, NI> NeighborLabelFrequencies<Label, NI>
impl<Label, NI> NeighborLabelFrequencies<Label, NI>
pub fn from_graph<G>(graph: &G) -> Selfwhere
G: Graph<NI> + UndirectedNeighbors<NI> + UndirectedDegrees<NI> + NodeValues<NI, Label> + Send + Sync,
pub fn neighbor_frequency(&self, node: NI) -> NeighborLabelFrequency<'_, Label>
Trait Implementations§
Source§impl<Label, G, NI> From<&G> for NeighborLabelFrequencies<Label, NI>where
NI: Idx,
Label: Idx + Hash,
G: Graph<NI> + UndirectedNeighbors<NI> + UndirectedDegrees<NI> + NodeValues<NI, Label> + Send + Sync,
impl<Label, G, NI> From<&G> for NeighborLabelFrequencies<Label, NI>where
NI: Idx,
Label: Idx + Hash,
G: Graph<NI> + UndirectedNeighbors<NI> + UndirectedDegrees<NI> + NodeValues<NI, Label> + Send + Sync,
Auto Trait Implementations§
impl<Label, NI> Freeze for NeighborLabelFrequencies<Label, NI>
impl<Label, NI> RefUnwindSafe for NeighborLabelFrequencies<Label, NI>where
NI: RefUnwindSafe,
Label: RefUnwindSafe,
impl<Label, NI> Send for NeighborLabelFrequencies<Label, NI>
impl<Label, NI> Sync for NeighborLabelFrequencies<Label, NI>
impl<Label, NI> Unpin for NeighborLabelFrequencies<Label, NI>
impl<Label, NI> UnsafeUnpin for NeighborLabelFrequencies<Label, NI>
impl<Label, NI> UnwindSafe for NeighborLabelFrequencies<Label, NI>where
NI: UnwindSafe,
Label: UnwindSafe,
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> 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