class_docstr: The model averaging is based on paper
  "Stochastic Gradient Descent for Non-smooth Optimization: Convergence
  Results and Optimal Averaging Schemes",
  (http://proceedings.mlr.press/v28/shamir13.pdf), which implements
  polynomial-decay averaging, parameterized by eta. When eta = 0, it is
  equivalent to simple average over all iterations with same weights.
docstr: Parameters
  ----------
  model
      The model to update the average.
docstr_tok: ["Parameters","--","--","--","--","--","model","The","model","to","update","the","average","."]
code: def update_average(self, model: nn.HybridBlock):
      r"""
      Parameters
      ----------
      model
          The model to update the average.
      """
      self.average_counter += 1
      if self.averaged_model is None:
          self.averaged_model = {
              k: v.list_data()[0].copy()
              for k, v in model.collect_params().items()
          }
      else:
          alpha = (self.eta + 1.0) / (self.eta + self.average_counter)
          # moving average
          for name, param_avg in self.averaged_model.items():
              param_avg[:] += alpha * (
                  model.collect_params()[name].list_data()[0]
                  - param_avg
              )
  
imports: from typing import Any, Dict, List, Optional
  import logging
  import mxnet
  import mxnet.gluon.nn
  from mxnet import gluon
  from gluonts.core.component import validated
  from .callback import Callback
label_desc: Use image node_id 4 for calling the IterationAveragingStrategy obj's underlying member method code with example usage: obj.update_average(model) without return types