pub struct TensorInspector { /* private fields */ }Expand description
Tensor inspector for examining intermediate values.
Implementations§
Source§impl TensorInspector
impl TensorInspector
Sourcepub fn is_enabled(&self) -> bool
pub fn is_enabled(&self) -> bool
Check if inspection is enabled.
Sourcepub fn clear_watch_list(&mut self)
pub fn clear_watch_list(&mut self)
Clear the watch list.
Sourcepub fn should_inspect(&self, tensor_id: usize) -> bool
pub fn should_inspect(&self, tensor_id: usize) -> bool
Check if a tensor should be inspected.
Sourcepub fn record_stats(&mut self, stats: TensorStats)
pub fn record_stats(&mut self, stats: TensorStats)
Record tensor statistics.
Sourcepub fn get_stats(&self, tensor_id: usize) -> Option<&TensorStats>
pub fn get_stats(&self, tensor_id: usize) -> Option<&TensorStats>
Get statistics for a tensor.
Sourcepub fn get_all_stats(&self) -> &HashMap<usize, TensorStats>
pub fn get_all_stats(&self) -> &HashMap<usize, TensorStats>
Get all recorded statistics.
Sourcepub fn find_problematic_tensors(&self) -> Vec<&TensorStats>
pub fn find_problematic_tensors(&self) -> Vec<&TensorStats>
Find tensors with numerical issues.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for TensorInspector
impl RefUnwindSafe for TensorInspector
impl Send for TensorInspector
impl Sync for TensorInspector
impl Unpin for TensorInspector
impl UnwindSafe for TensorInspector
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