def dynamic_read_source

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

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

481def dynamic_read_source(+shape: Shape.Shape, -tensor: Tensor<shape>, +index: U32, certificate: SourceRead<shape, tensor, index>) ->
482  DynamicSourceRead<Packed{shape, tensor}, index>:
483  SourceRead{meaning} = certificate
484  DynamicSourceRead{Equal.trans(Maybe<&2, F32>, dynamic_read_value(read_dynamic(Packed{shape, tensor}, index)),
485    read_value(shape, read_flat(shape, tensor, index)), checked_observe(shape, tensor, index),
486    dynamic_result_value(shape, read_flat(shape, tensor, index)), meaning)}

Uses (15)

Used by (2)