class_docstr: Linearly increases learning rate from 0 to 1 over `warmup` fraction of training steps.
  Decreases learning rate from 1. to 0. over remaining `1 - warmup` steps following a cosine curve.
  If `cycles` (default=0.5) is different from default, learning rate follows cosine function after warmup.
docstr: :param warmup:      see LRSchedule
  :param t_total:     see LRSchedule
  :param cycles:      number of cycles. Default: 0.5, corresponding to cosine decay from 1. at progress==warmup and 0 at progress==1.
  :param kw:
code: def __init__(self, warmup=0.002, t_total=-1, cycles=0.5, **kw):
      """
      :param warmup:      see LRSchedule
      :param t_total:     see LRSchedule
      :param cycles:      number of cycles. Default: 0.5, corresponding to cosine decay from 1. at progress==warmup and 0 at progress==1.
      :param kw:
      """
      super(WarmupCosineSchedule, self).__init__(
          warmup=warmup, t_total=t_total, **kw
      )
      self.cycles = cycles
  
imports: import math
  import torch
  from torch.optim import Optimizer
  from torch.optim.optimizer import required
  from torch.nn.utils import clip_grad_norm_
  import logging
  import abc
  import sys
label_desc: Use image node_id 1 to create a new WarmupCosineSchedule object from inherited base classes: _LRSchedule with example: obj = WarmupCosineSchedule(warmup, t_total, cycles)