BroadcastLAWS.source_value: def of bendtorch-core@0.1.0.0 Import: import bendtorch-core@0.1.0.0/src/autograd/broadcast_LAWS.bend as BroadcastLAWS Lines 17-25 of bendtorch-core@0.1.0.0/src/autograd/broadcast_LAWS.bend: https://jend.leeeet.dev/read.txt?path=bendtorch-core@0.1.0.0/src/autograd/broadcast_LAWS.bend&start_line=17&end_line=25 import Base import bendtorch-core@0.1.0.0/src/tensor/core.bend as Core # The input value that the specification assigns to one output position: the # input offset of its right-aligned broadcast projection. def source_value(input: Core.Dynamic, offsets: Maybe<&1, U32 & U32>) -> Maybe<&2, F32>: match offsets: case None{}: None{} case Some{pair}: (input_offset, target_offset) = pair Core.checked_observe_dynamic(input, input_offset) Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=F32 https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Maybe https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Pair https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Sigma https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=U32 https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/tensor/core.bend&name=Dynamic https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/tensor/core.bend&name=checked_observe_dynamic