Attend the Women in ML Symposium on December 7 Register now

tf_agents.utils.tensor_normalizer.kahan_summation

Stay organized with collections Save and categorize content based on your preferences.

Calculate stable acculated sum using compensation for low-bits.

For more details:

https://en.wikipedia.org/wiki/Kahan_summation_algorithm

accumulator Accumulator.
carry Carry for lost low-order bits.
value New value to accumlate.

A tuple (accumulator, carry) such that accumulator is the new accumulated value and carry is the new compensation value.