class_docstr: Represents a recorded metric value.
class_docstr_tok: ["Represents","a","recorded","metric","value","."]
docstr: Create a metric record.
  
  Args:
      name: Name of the metric.
      typ: Type of metric.
      value: Value of the metric (can be anything: scalar, tensor, image, etc.).
      global_step: The time_step of the log. This should be incremented the next time this metric is logged again. E.g. if you log every epoch, set the global_step to the current epoch.
      walltime: Time of recording this metric.
docstr_tok: ["Create","a","metric","record",".","Args",":","name",":","Name","of","the","metric",".","typ",":","Type","of","metric",".","value",":","Value","of","the","metric","(","can","be","anything",":","scalar",",","tensor",",","image",",","etc.",")",".","global_step",":","The","time_step","of","the","log",".","This","should","be","incremented","the","next","time","this","metric","is","logged","again",".","E.g",".","if","you","log","every","epoch",",","set","the","global_step","to","the","current","epoch",".","walltime",":","Time","of","recording","this","metric","."]
code: def __init__(
      self,
      name: Union[Iterable[str], str],
      value: Any,
      global_step: int,
      typ: RecordType,
      *,
      walltime: Optional[float] = None,
  ) -> None:
      """Create a metric record.
  
      Args:
          name: Name of the metric.
          typ: Type of metric.
          value: Value of the metric (can be anything: scalar, tensor, image, etc.).
          global_step: The time_step of the log. This should be incremented the next time this metric is logged again. E.g. if you log every epoch, set the global_step to the current epoch.
          walltime: Time of recording this metric.
      """
      self.name: MetricName = MetricName(name)
      self.typ: RecordType = typ
      self.value: Any = value
      self.global_step: int = global_step
      self.walltime: float = (
          walltime if walltime is not None else time.time()
      )
  
imports: import time
  from dataclasses import dataclass
  from enum import Enum
  from typing import Any, Iterable, Iterator, Optional, Tuple, Union
label_desc: Use image node_id 1 to create a new MetricRecord object  with example: obj = MetricRecord(name, value, global_step, typ)