def LogicalArr

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

import bendtorch-core@0.1.0.0/src/tensor/matmul_parallel_proof.bend as MatmulParallelProof
import Base
import bendtorch-core@0.1.0.0/src/tensor/dot_fold.bend as DotFold

18# The factor pairs the terms `cursor .. cursor + fuel` of cell (row, column)
19# read: left[row * inner + k] and right[k * columns + column].
20def LogicalArr(+fuel: Nat, +dl: Nat, +dr: Nat, -A: Array<F32>, -B: Array<F32>, +inner: Nat, +columns: Nat,
21  +row: Nat, +column: Nat, +cursor: Nat, values: List<&2, DotFold.Factors>) -> Data:
22  match fuel values:
23    case 0n Nil{}:
24      Unit
25    case 1n+tail DotFold.Factors{lv, rv} <> rest:
26      ArrStep<tail, dl, dr, A, B, inner, columns, row, column, cursor, lv, rv, rest>
27    case 0n DotFold.Factors{lv, rv} <> rest:
28      Empty
29    case 1n+tail Nil{}:
30      Empty

Uses (8)

Used by (4)