def forward_layout
import bendtorch-core@0.1.0.0/src/tensor/batched_matmul.bend as BatchedMatmulimport Base
import bendtorch-core@0.1.0.0/src/tensor/matmul.bend as Matrix
206# left @ right: left [.., rows, inner] read by rows, right [.., inner,
207# columns] read by columns, as `matmul` reads them.
208def forward_layout(+plan: Plan) -> Layout:
209 Plan{output, batch, +rows, +inner, +columns, +l1, +l2, +r1, +r2, o1, +o2, lv, rv} = plan
210 Layout{Matrix.Kept{}, Matrix.Swapped{}, inner, rows, columns, l1, l2, r1, r2, o2}