Skip to content

Local Logging & Tracking

This repository uses local-only logging:

MLflow (file backend)

  • Default: MLFLOW_TRACKING_URI is set to file:./mlruns when using helpers in logging_utils.py.
  • To customize:
export MLFLOW_TRACKING_URI="file:/absolute/path/to/mlruns"

References: MLflow file backend / tracking URIs. (mlflow.org)

TensorBoard

Use PyTorch’s SummaryWriter:

from torch.utils.tensorboard import SummaryWriter
writer = SummaryWriter("./runs")
writer.add_scalar("loss", 0.123, 1)

Reference: PyTorch TensorBoard utilities. (docs.pytorch.org)

NDJSON & CSV outputs

  • NDJSON: one JSON object per line; prefer the .ndjson extension. (GitHub)
  • The evaluation logger now reuses the training NDJSON sink, supporting file rotation (ndjson_max_bytes, ndjson_backup_count) and optional GPU telemetry when pynvml is installed.
  • CSV: use Python’s csv.DictWriter for tabular outputs. (docs.python.org)