Skip to main content

check_shape

Function check_shape 

Source
pub fn check_shape(
    r: &TensorRef,
    expected: &[u32],
    op: &'static str,
) -> Result<(), TensorRefError>
Expand description

Verify a TensorRef matches the expected shape; returns TensorRefError::ShapeMismatch on mismatch.