class_docstr: Callback that sets the learning rate of each
  parameter group according to some policy.
  
  Parameters
  ----------
  
  policy : str or _LRScheduler class (default='WarmRestartLR')
    Learning rate policy name or scheduler to be used.
  
  monitor : str or callable (default=None)
    Value of the history to monitor or function/callable. In
    the latter case, the callable receives the net instance as
    argument and is expected to return the score (float) used to
    determine the learning rate adjustment.
  
  event_name: str, (default='event_lr')
    Name of event to be placed in history when the scheduler takes a step.
    Pass ``None`` to disable placing events in history.
    **Note:** This feature works only for pytorch version >=1.4
  
  step_every: str, (default='epoch')
    Value for when to apply the learning scheduler step. Can be either 'batch'
     or 'epoch'.
  
  kwargs
    Additional arguments passed to the lr scheduler.
docstr: Helper method to step the lr scheduler.
  
  This takes care of two things:
  
  1. If the lr scheduler is ReduceLROnPlateau, we need to pass the score.
  2. If the net is uses AccelerateMixin, stepping has to be skipped in
     certain conditions.
  
  For more info on the latter, see:
  https://huggingface.co/docs/accelerate/quicktour#mixed-precision-training
docstr_tok: ["Helper","method","to","step","the","lr","scheduler",".","This","takes","care","of","two","things",":","1",".","If","the","lr","scheduler","is","ReduceLROnPlateau",",","we","need","to","pass","the","score",".","2",".","If","the","net","is","uses","AccelerateMixin",",","stepping","has","to","be","skipped","in","certain","conditions",".","For","more","info","on","the","latter",",","see",":","https",":","\/\/huggingface.co\/docs\/accelerate\/quicktour","#","mixed-precision-training"]
code: def _step(self, net, lr_scheduler, score=None):
      """Helper method to step the lr scheduler.
  
      This takes care of two things:
  
      1. If the lr scheduler is ReduceLROnPlateau, we need to pass the score.
      2. If the net is uses AccelerateMixin, stepping has to be skipped in
         certain conditions.
  
      For more info on the latter, see:
      https://huggingface.co/docs/accelerate/quicktour#mixed-precision-training
  
      """
      accelerator_maybe = getattr(net, "accelerator", None)
      accelerator_step_skipped = (
          accelerator_maybe
          and accelerator_maybe.optimizer_step_was_skipped
      )
      if accelerator_step_skipped:
          return
  
      if score is None:
          lr_scheduler.step()
      else:
          lr_scheduler.step(score)
  
imports: import sys
  import warnings
  import numpy
  import torch
  from torch.optim.lr_scheduler import _LRScheduler
  from torch.optim.lr_scheduler import CosineAnnealingLR
  from torch.optim.lr_scheduler import CyclicLR
  from torch.optim.lr_scheduler import ExponentialLR
  from torch.optim.lr_scheduler import LambdaLR
  from torch.optim.lr_scheduler import MultiStepLR
  from torch.optim.lr_scheduler import ReduceLROnPlateau
  from torch.optim.lr_scheduler import StepLR
  from torch.optim.optimizer import Optimizer
  from skorch.callbacks import Callback
label_desc: Use image node_id 7 for calling the LRScheduler obj's underlying member method code with example usage: obj._step(net, lr_scheduler, score) without return types