pub struct LeidenOptions {
pub objective: LeidenObjective,
pub resolution: f64,
pub beta: f64,
pub n_iterations: i32,
pub seed: u64,
pub start: Option<Vec<u32>>,
}Expand description
Full set of options for leiden_with_options. Construct via
LeidenOptions::default() and then mutate the fields you care
about, mirroring the way upstream C exposes per-parameter defaults.
Fields§
§objective: LeidenObjectiveQuality function. Default LeidenObjective::Modularity.
resolution: f64Resolution parameter γ. Default 1.0. For CPM, sensible values
are very small (e.g. 0.05); for modularity, 1.0 is the
classical choice.
beta: f64Refinement randomness. Default LEIDEN_DEFAULT_BETA.
n_iterations: i32Number of outer iterations to run. Negative ⇒ iterate until a
pass produces no change. Default LEIDEN_DEFAULT_ITERATIONS.
seed: u64PRNG seed (drives both the local-moving shuffle and the
refinement sampling). Default 0.
start: Option<Vec<u32>>If Some, start from this membership vector instead of the
singleton partition. Length must equal vcount.
Trait Implementations§
Source§impl Clone for LeidenOptions
impl Clone for LeidenOptions
Source§fn clone(&self) -> LeidenOptions
fn clone(&self) -> LeidenOptions
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 Debug for LeidenOptions
impl Debug for LeidenOptions
Auto Trait Implementations§
impl Freeze for LeidenOptions
impl RefUnwindSafe for LeidenOptions
impl Send for LeidenOptions
impl Sync for LeidenOptions
impl Unpin for LeidenOptions
impl UnsafeUnpin for LeidenOptions
impl UnwindSafe for LeidenOptions
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