class_docstr: Gradient accumulation utility.
  When used with a distribution strategy, the accumulator should be called in a
  replica context. Gradients will be accumulated locally on each replica and
  without synchronization. Users should then call ``.gradients``, scale the
  gradients if required, and pass the result to ``apply_gradients``.
docstr: Initializes the accumulator.
docstr_tok: ["Initializes","the","accumulator","."]
code: def __init__(self):
      """Initializes the accumulator."""
      self._gradients = []
      self._accum_steps = None
  
imports: import re
  from typing import Callable, List, Optional, Union
  import tensorflow
  from packaging import version
label_desc: Use image node_id 1 to create a new GradientAccumulator object from inherited base classes: object with example: obj = GradientAccumulator()