BendMlAutograd.linear: def of bend-ml-autograd@0.1.1.0 Import: import bend-ml-autograd@0.1.1.0/main.bend as BendMlAutograd Lines 211-213 of bend-ml-autograd@0.1.1.0/main.bend: https://jend.leeeet.dev/read.txt?path=bend-ml-autograd@0.1.1.0/main.bend&start_line=211&end_line=213 import Base import bend-ml-tensor@0.1.0.0/main.bend as T # y = x·W + b x: n x i, W: i x o, b: o -> y: n x o def linear(-n: Nat, +i: Nat, +o: Nat, x: T.Mat, w: T.Mat, b: T.Vec) -> T.Mat: T.Mat.add_row(n, o, T.Mat.matmul(n, i, o, x, w), b) Uses (5): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor@0.1.2.0/main.bend&name=Mat https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor@0.1.2.0/main.bend&name=Mat.add_row https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor@0.1.2.0/main.bend&name=Mat.matmul https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor@0.1.2.0/main.bend&name=Vec