BendMlTensorFork.softmax_ce: def of bend-ml-tensor-fork@0.1.6.0 Import: import bend-ml-tensor-fork@0.1.6.0/main.bend as BendMlTensorFork Lines 421-424 of bend-ml-tensor-fork@0.1.6.0/main.bend: https://jend.leeeet.dev/read.txt?path=bend-ml-tensor-fork@0.1.6.0/main.bend&start_line=421&end_line=424 import Base import bend-ml-tensor-array@0.1.19.0/main.bend as TA # mean cross-entropy and its gradient, TA.Mat.softmax_ce's arguments and bits, with the rows in up to 2^par blocks # (par = 0: tensor-array's own loop) def softmax_ce(+n: Nat, +c: Nat, +par: Nat, z: TA.Mat, labels: List<&2, Nat>) -> TA.MCE: softmax_ce2(Bool.or(Nat.is_eq(par, 0n), Nat.is_eq(c, 0n)), n, c, par, z, labels) Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool.or https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=List https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Nat.is_eq https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor-array@0.1.19.0/main.bend&name=MCE https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor-array@0.1.19.0/main.bend&name=Mat https://jend.leeeet.dev/definition.txt?path=bend-ml-tensor-fork@0.1.6.0/main.bend&name=softmax_ce2