ReluLAWS.scalar_relu_left_below: law of bendtorch-core@0.1.0.0 Import: import bendtorch-core@0.1.0.0/src/tensor/relu_LAWS.bend as ReluLAWS Lines 72-80 of bendtorch-core@0.1.0.0/src/tensor/relu_LAWS.bend: https://jend.leeeet.dev/read.txt?path=bendtorch-core@0.1.0.0/src/tensor/relu_LAWS.bend&start_line=72&end_line=80 import Base import bendtorch-core@0.1.0.0/src/tensor/elementwise.bend as Elementwise # ReluLeft is PyTorch's relu, clamp_min(x, 0), on the left word: +0.0 where # the word is below zero, and the word itself otherwise, so -0.0 stays -0.0 # and a NaN keeps its sign and payload. The right word is ignored: the # forward is the pointwise product with a rank-0 +0.0. law scalar_relu_left_below: for +left: F32 for +right: F32 for below: {Elementwise.below_zero(left) == True{} : Bool} {Elementwise.scalar(Elementwise.ReluLeft{}, left, right) == 0.0 : F32} Uses (7): https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Bool https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=Equal.sym https://jend.leeeet.dev/definition.txt?path=Base/base.bend&name=F32 https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/tensor/elementwise.bend&name=Operation https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/tensor/elementwise.bend&name=below_zero https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/tensor/elementwise.bend&name=scalar https://jend.leeeet.dev/definition.txt?path=bendtorch-core@0.1.0.0/src/tensor/elementwise.bend&name=zero_if