law accumulate_mapping

bendtorch-core@0.1.0.0 · src/autograd/gradient_LAWS.bend:121

import bendtorch-core@0.1.0.0/src/autograd/gradient_LAWS.bend as GradientLAWS
import Base
import bendtorch-core@0.1.0.0/src/shape/core.bend as Shape
import bendtorch-core@0.1.0.0/src/tensor/core.bend as Core
import bendtorch-core@0.1.0.0/src/autograd/gradient.bend as Gradient

121# On success the slot holds a gradient with the slot's dimensions. At every
122# in-bounds position, the first contribution moves in unchanged and every
123# later one is added to the held total with one F32 add, total first.
124law accumulate_mapping:
125  for +shape: Shape.Shape
126  for slot: Gradient.Slot
127  for contribution: Core.Dynamic
128  MappingModel<slot, contribution, shape, Gradient.accumulate(shape, slot, contribution)>

Uses (11)

Used by (0)

No other definition uses this definition.