pub struct TosaFp32OperatorCase {
pub name: &'static str,
pub artifact: &'static [u8],
pub inputs: &'static [Fp32TierTensor],
pub output: Fp32TierTensor,
pub absolute_tolerance: f32,
pub relative_tolerance: f32,
}Expand description
One FP32-tier operator case shared by host backends: a stable TOSA 1.0 graph over FP32 tensors with BOOL and INT32 auxiliaries, and a numerical oracle for its single output.
Float outputs follow the TosaFloat32Case rules: NaN matches any NaN, infinities and
zeros compare bit-exactly (signed zero included), and finite values must fall within the
absolute or relative tolerance. BOOL and INT32 outputs compare exactly.
Fields§
§name: &'static strDiagnostic case name.
artifact: &'static [u8]TOSA 1.0 FlatBuffer payload.
inputs: &'static [Fp32TierTensor]Block inputs in declared slot order.
output: Fp32TierTensorSingle block output.
absolute_tolerance: f32Maximum absolute error accepted for finite float values.
relative_tolerance: f32Maximum relative error accepted for finite float values.
Implementations§
Source§impl TosaFp32OperatorCase
impl TosaFp32OperatorCase
Sourcepub fn output_matches(self, actual: &[u8]) -> bool
pub fn output_matches(self, actual: &[u8]) -> bool
Compare raw client-visible output bytes with the typed oracle.
Trait Implementations§
Source§impl Clone for TosaFp32OperatorCase
impl Clone for TosaFp32OperatorCase
Source§fn clone(&self) -> TosaFp32OperatorCase
fn clone(&self) -> TosaFp32OperatorCase
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for TosaFp32OperatorCase
Source§impl Debug for TosaFp32OperatorCase
impl Debug for TosaFp32OperatorCase
Source§impl PartialEq for TosaFp32OperatorCase
impl PartialEq for TosaFp32OperatorCase
Source§fn eq(&self, other: &TosaFp32OperatorCase) -> bool
fn eq(&self, other: &TosaFp32OperatorCase) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for TosaFp32OperatorCase
Auto Trait Implementations§
impl Freeze for TosaFp32OperatorCase
impl RefUnwindSafe for TosaFp32OperatorCase
impl Send for TosaFp32OperatorCase
impl Sync for TosaFp32OperatorCase
impl Unpin for TosaFp32OperatorCase
impl UnsafeUnpin for TosaFp32OperatorCase
impl UnwindSafe for TosaFp32OperatorCase
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