pub struct PerTensorScale {
pub scale: f32,
}Expand description
Per-tensor scaling factor: a single multiplicative scalar.
a_scale is computed by the caller (typically max(abs(A)) / fp8_max) and passed to cublasGemmEx via alpha = a_scale * b_scale * gemm_alpha.
Fields§
§scale: f32Trait Implementations§
Source§impl Clone for PerTensorScale
impl Clone for PerTensorScale
Source§fn clone(&self) -> PerTensorScale
fn clone(&self) -> PerTensorScale
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 PerTensorScale
impl Debug for PerTensorScale
Source§impl Default for PerTensorScale
impl Default for PerTensorScale
Source§fn default() -> PerTensorScale
fn default() -> PerTensorScale
Returns the “default value” for a type. Read more
impl Copy for PerTensorScale
Auto Trait Implementations§
impl Freeze for PerTensorScale
impl RefUnwindSafe for PerTensorScale
impl Send for PerTensorScale
impl Sync for PerTensorScale
impl Unpin for PerTensorScale
impl UnsafeUnpin for PerTensorScale
impl UnwindSafe for PerTensorScale
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