def from_values

bendtorch-core@0.1.0.0 · src/tensor/core.bend:407

import bendtorch-core@0.1.0.0/src/tensor/core.bend as Core
import Base
import bendtorch-core@0.1.0.0/src/shape/core.bend as Shape

407def from_values(+shape: Shape.Shape, +values: List<&2, F32>) -> Result<&2, &1, Error, Tensor<shape>>:
408  from_values_counted(shape, values,
409    Shape.bool_case(Nat.is_eq(List.length(&2, F32, values), Shape.elements(shape))))

Uses (11)

Used by (14)