def get_or_create_metrics(run):
    """Returns the "subfolder" of the HDF5 file "run/metric" where metrics may be stored."""
    if "metrics" not in run:
        run.create_group("metrics")
    return run["metrics"]