class_docstr: Logs the loss, optimizer LR, and meters. Logs at the end of a phase.
docstr: The constructor method of LossLrMeterLoggingHook.
  
  Args:
      log_freq: if specified, also logs every ``log_freq`` batches.
code: def __init__(self, log_freq: Optional[int] = None) -> None:
      """The constructor method of LossLrMeterLoggingHook.
  
      Args:
          log_freq: if specified, also logs every ``log_freq`` batches.
  
      """
      super().__init__()
      assert log_freq is None or isinstance(
          log_freq, int
      ), "log_freq must be an int or None"
      self.log_freq: Optional[int] = log_freq
  
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 1 to create a new LossLrMeterLoggingHook object from inherited base classes: ClassyHook with example: obj = LossLrMeterLoggingHook(log_freq)