class_docstr: Logs the loss, optimizer LR, and meters. Logs at the end of a phase.
docstr: Log the LR every log_freq batches, if log_freq is not None.
code: def on_step(self, task) -> None:
      """
      Log the LR every log_freq batches, if log_freq is not None.
      """
      if self.log_freq is None or not task.train:
          return
      batches = len(task.losses)
      if batches and batches % self.log_freq == 0:
          self._log_loss_lr_meters(task, prefix="Approximate meters: ")
  
file_path: ClassyVision/classy_vision/hooks/loss_lr_meter_logging_hook.py
imports: import logging
  from typing import Optional
  from classy_vision.generic.distributed_util import get_rank
  from classy_vision.hooks import register_hook
  from classy_vision.hooks.classy_hook import ClassyHook
label_desc: Use image node_id 4 for calling the LossLrMeterLoggingHook obj's underlying member method code with example usage: obj.on_step(task) without return types