class_docstr: The WarmupReduceLROnPlateau scheduler.
  
  This scheduler is the combination of WarmupLR and ReduceLROnPlateau:
  
  WarmupLR:
      lr = optimizer.lr * warmup_step ** 0.5
           * min(step ** -0.5, step * warmup_step ** -1.5)
  WarmupReduceLROnPlateau:
      if step <= warmup_step:
          lr = optimizer.lr * warmup_step ** 0.5
               * min(step ** -0.5, step * warmup_step ** -1.5)
      else:
          lr = (
              optimizer.lr * factor
              if no improvement for a 'patience' number of epochs
              else optimizer.lr
          )
  
  Note that the maximum lr equals to optimizer.lr in this scheduler.
class_docstr_tok: ["The","WarmupReduceLROnPlateau","scheduler",".","This","scheduler","is","the","combination","of","WarmupLR","and","ReduceLROnPlateau",":","WarmupLR",":","lr","=","optimizer.lr","*","warmup_step","*","*","0.5","*","min","(","step","*","*","-0.5",",","step","*","warmup_step","*","*","-1.5",")","WarmupReduceLROnPlateau",":","if","step","<","=","warmup_step",":","lr","=","optimizer.lr","*","warmup_step","*","*","0.5","*","min","(","step","*","*","-0.5",",","step","*","warmup_step","*","*","-1.5",")","else",":","lr","=","(","optimizer.lr","*","factor","if","no","improvement","for","a","'patience","'","number","of","epochs","else","optimizer.lr",")","Note","that","the","maximum","lr","equals","to","optimizer.lr","in","this","scheduler","."]
code: def __repr__(self):
      return (
          f"{self.__class__.__name__}(warmup_steps={self.warmup_steps}, "
          f"mode={self.mode}, factor={self.factor}, patience={self.patience}"
      )
  
file_path: espnet/espnet2/schedulers/warmup_reducelronplateau.py
imports: from typing import Union
  import torch
  from torch import inf
  from typeguard import check_argument_types
  from espnet2.schedulers.abs_scheduler import AbsBatchStepScheduler, AbsValEpochStepScheduler
label_desc: Use image node_id 2 for calling the WarmupReduceLROnPlateau obj's underlying member method code with example usage: obj.__repr__() and returns: self, str, self, str, self, str, self, str, self