Skip to main content

binary

Function binary 

Source
pub fn binary<T: Copy, U, F>(
    lhs: &[T],
    lhs_l: &Layout,
    rhs: &[T],
    rhs_l: &Layout,
    f: F,
) -> Vec<U>
where F: Fn(T, T) -> U,
Expand description

out[i] = f(lhs[i], rhs[i]) over two (possibly non-contiguous) views of the same logical shape. Mirrors luma-core compute_binary_op.