def fitted_retains
bendtorch-core@0.1.0.0 · src/autograd/reduce_PROOF.bend:202
import bendtorch-core@0.1.0.0/src/autograd/reduce_PROOF.bend as ReducePROOF
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/reduce.bend as Reduce
import bendtorch-core@0.1.0.0/src/autograd/reduce_LAWS.bend as Laws
202def fitted_retains(+shape: Shape.Shape, tensor: Core.Tensor<shape>, +target: Shape.Shape, +plan: Shape.BroadcastPlan, same: Bool) ->
203 Laws.Retained<Core.Packed{shape, tensor}, Reduce.fitted(Core.Packed{shape, tensor}, target, plan, same)>:
204 match same:
205 case False{}:
206 Laws.Retained{property => {==}}
207 case True{}:
208 parallel_retains(shape, tensor, target, plan, Core.new(target, 0.0))