Expand description
Reductions over bfloat16 storage.
#1785 asks for sum reduction with a specified accumulation rule and for tests that distinguish
that rule from repeated rounding of the storage type. Two reductions do that here: one
accumulates in f32 and rounds once, which is the contract this crate promises, and one
rounds at every step. The second is not offered as the contract; it exists so tests can measure
the difference instead of assuming it.
Functionsยง
- product_
in_ f32_ accumulation - Product of a slice, accumulating in
f32and rounding once. - sum_
in_ f32_ accumulation - Sum a slice, accumulating in
f32and rounding once at the end. - sum_
with_ per_ step_ rounding - Sum a slice, rounding to bfloat16 after every step.