pub struct SparseConfig {
pub sparsity_threshold: Float,
pub preferred_format: SparseFormat,
pub use_parallel: bool,
pub max_memory_usage: usize,
}Expand description
Configuration for sparse operations
Fields§
§sparsity_threshold: FloatDensity threshold below which to use sparse operations
preferred_format: SparseFormatPreferred sparse format for operations
use_parallel: boolEnable parallel sparse operations
max_memory_usage: usizeMaximum memory usage for sparse operations (bytes)
Implementations§
Source§impl SparseConfig
impl SparseConfig
pub fn new() -> Self
pub fn with_sparsity_threshold(self, threshold: Float) -> Self
pub fn with_preferred_format(self, format: SparseFormat) -> Self
pub fn with_parallel(self, enabled: bool) -> Self
pub fn with_max_memory(self, bytes: usize) -> Self
Trait Implementations§
Source§impl Clone for SparseConfig
impl Clone for SparseConfig
Source§fn clone(&self) -> SparseConfig
fn clone(&self) -> SparseConfig
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 SparseConfig
impl Debug for SparseConfig
Auto Trait Implementations§
impl Freeze for SparseConfig
impl RefUnwindSafe for SparseConfig
impl Send for SparseConfig
impl Sync for SparseConfig
impl Unpin for SparseConfig
impl UnwindSafe for SparseConfig
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