def MatT.softmax_rows
import bend-tensors@0.0.0.2/bend_tensors.bend as BendTensorsimport Base
1072# softmax along each row: exp(row - max row) / sum
1073def MatT.softmax_rows(+r: Nat, +c: Nat, +m: MatT(r, c)) -> MatT(r, c):
1074 MatT.softmax_rows.fin(r, c, MatT.exp(r, c, MatT.sub_col(r, c, m, MatT.max_rows(r, c, m))))
Uses (6)
Used by (0)
No other definition uses this definition.