class_docstr: Trainer extension to gradually initialize an optimizer attribute.
  
  This extension changes an optimizer attribute evenly at the
  beginning of one training.
  
  For example, suppose that this extension is called at every iteration,
  and warmup_start = x , init = y, warmup_iter = t.
  Then this extension will set the corresponding attribute to from
  ``x`` to ``y`` evenly in first ``t`` iterations.
  
  This extension is also called before the training loop starts by default.
  
  Args:
      attr (str): Name of the optimizer attribute to adjust.
      warmup_start (float): the value of the attr at the beginning
          of one training.
      init (float): the value of the attr after warm up iterations.
      warmup_iter (int): the number of the iterations in which the
          attr changes from ``warmup_start`` to ``init``.
      optimizer (~chainer.Optimizer): Target optimizer object.
          If it is None, the main optimizer of the trainer is used.
code: def serialize(self, serializer):
      self._t = serializer("_t", self._t)
  
file_path: chainer/chainer/training/extensions/warmup_shift.py
imports: from __future__ import division
  from chainer.training import extension
label_desc: Use image node_id 4 for calling the WarmupShift obj's underlying member method code with example usage: obj.serialize(serializer) without return types