def shape_count_within
bendtorch-core@0.1.0.0 · src/tensor/word_conversion.bend:598
import bendtorch-core@0.1.0.0/src/tensor/word_conversion.bend as WordConversion
import Base
import bendtorch-core@0.1.0.0/src/storage/arith.bend as Arith
import bendtorch-core@0.1.0.0/src/shape/core.bend as Shape
598def shape_count_within(+shape: Shape.Shape) -> {U32.is_le(Shape.count(shape), 1048576) == True{} : Bool}:
599 %Arith.u32_le(Shape.count(shape), 1048576) : {_ == True{} : Bool}
600 %Equal.sym(Nat, U32.to_nat(Shape.count(shape)), Shape.elements(shape), shape_count_exact(shape)) :
601 {Nat.is_le(_, U32.to_nat(1048576)) == True{} : Bool}
602 capacity_within(Shape.elements(shape), shape_capacity(shape))