pub struct OptimizationStats {
pub nodes_before: usize,
pub nodes_after: usize,
pub memory_before: usize,
pub memory_after: usize,
pub compute_cost_before: f32,
pub compute_cost_after: f32,
pub fused_chains: usize,
pub optimization_time_us: u64,
}Expand description
Statistics about optimization results
Fields§
§nodes_before: usizeNumber of nodes before optimization
nodes_after: usizeNumber of nodes after optimization
memory_before: usizeMemory usage before optimization (bytes)
memory_after: usizeMemory usage after optimization (bytes)
compute_cost_before: f32Compute cost before optimization
compute_cost_after: f32Compute cost after optimization
fused_chains: usizeNumber of fused operation chains
optimization_time_us: u64Optimization time (microseconds)
Implementations§
Source§impl OptimizationStats
impl OptimizationStats
Sourcepub fn memory_reduction(&self) -> f32
pub fn memory_reduction(&self) -> f32
Calculate memory reduction percentage
Sourcepub fn compute_reduction(&self) -> f32
pub fn compute_reduction(&self) -> f32
Calculate compute cost reduction percentage
Sourcepub fn node_reduction(&self) -> f32
pub fn node_reduction(&self) -> f32
Calculate node reduction percentage
Trait Implementations§
Source§impl Clone for OptimizationStats
impl Clone for OptimizationStats
Source§fn clone(&self) -> OptimizationStats
fn clone(&self) -> OptimizationStats
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 OptimizationStats
impl Debug for OptimizationStats
Auto Trait Implementations§
impl Freeze for OptimizationStats
impl RefUnwindSafe for OptimizationStats
impl Send for OptimizationStats
impl Sync for OptimizationStats
impl Unpin for OptimizationStats
impl UnwindSafe for OptimizationStats
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