def q8_byte
import bendtorch@1.3.0.0/dtype.bend as Dtypeimport Base
319# an integer -127..127 (as an F32) to its two's complement byte, and back
320def q8_byte(+q: F32) -> U32:
321 ((F32.to_u32((q + 128.0 : F32)) + 128 : U32) .&. 255 : U32)
import bendtorch@1.3.0.0/dtype.bend as Dtypeimport Base
319# an integer -127..127 (as an F32) to its two's complement byte, and back
320def q8_byte(+q: F32) -> U32:
321 ((F32.to_u32((q + 128.0 : F32)) + 128 : U32) .&. 255 : U32)