class_docstr: Fixed learning rate scheduler with optional linear warm-up strategy
code: def __init__(self, opts, **kwargs) -> None:
      is_iter_based = getattr(
          opts, "scheduler.is_iteration_based", True
      )
      super(FixedLRScheduler, self).__init__(opts=opts)
  
      max_iterations = getattr(opts, "scheduler.max_iterations", 150000)
  
      self.fixed_lr = getattr(opts, "scheduler.fixed.lr", None)
      assert self.fixed_lr is not None
  
      if self.warmup_iterations > 0:
          self.warmup_step = (
              self.fixed_lr - self.warmup_init_lr
          ) / self.warmup_iterations
  
      self.period = (
          max_iterations - self.warmup_iterations + 1
          if is_iter_based
          else getattr(opts, "scheduler.max_epochs", 350)
      )
  
      self.is_iter_based = is_iter_based
  
file_path: ml-cvnets/optim/scheduler/fixed.py
imports: import argparse
  from optim.scheduler import SCHEDULER_REGISTRY
  from optim.scheduler.base_scheduler import BaseLRScheduler
label_desc: Use image node_id 1 to create a new FixedLRScheduler object from inherited base classes: BaseLRScheduler with example: obj = FixedLRScheduler(opts)