code: def _apply_average_op(self, train_op, var, apply_state):
      apply_state = apply_state or {}
      local_apply_state = apply_state.get(
          (var.device, var.dtype.base_dtype)
      )
      if local_apply_state is None:
          local_apply_state = self._fallback_apply_state(
              var.device, var.dtype.base_dtype
          )
      average_var = self.get_slot(var, "average")
      return self.average_op(var, average_var, local_apply_state)
  
imports: import abc
  import warnings
  import tensorflow
  from tensorflow_addons.optimizers import KerasLegacyOptimizer
  from tensorflow_addons.utils import types
  from typeguard import typechecked
label_desc: Use image node_id 7 for calling the AveragedOptimizerWrapper obj's underlying member method code with example usage: obj._apply_average_op(train_op, var, apply_state) and returns: self