pub struct TreeConfig {
pub max_depth: usize,
pub fanout: usize,
pub min_cluster_size: usize,
}Expand description
Configuration for building a RAPTOR tree.
Fields§
§max_depth: usizeMaximum depth of the tree (number of summary levels).
fanout: usizeTarget number of items per cluster (fanout).
min_cluster_size: usizeMinimum items needed to form a cluster.
Implementations§
Source§impl TreeConfig
impl TreeConfig
Sourcepub fn with_max_depth(self, depth: usize) -> Self
pub fn with_max_depth(self, depth: usize) -> Self
Set maximum depth.
Sourcepub fn with_fanout(self, fanout: usize) -> Self
pub fn with_fanout(self, fanout: usize) -> Self
Set target fanout (items per cluster).
Sourcepub fn with_min_cluster_size(self, size: usize) -> Self
pub fn with_min_cluster_size(self, size: usize) -> Self
Set minimum cluster size.
Trait Implementations§
Source§impl Clone for TreeConfig
impl Clone for TreeConfig
Source§fn clone(&self) -> TreeConfig
fn clone(&self) -> TreeConfig
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 TreeConfig
impl Debug for TreeConfig
Auto Trait Implementations§
impl Freeze for TreeConfig
impl RefUnwindSafe for TreeConfig
impl Send for TreeConfig
impl Sync for TreeConfig
impl Unpin for TreeConfig
impl UnsafeUnpin for TreeConfig
impl UnwindSafe for TreeConfig
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> 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