INNER CODE UNIT · Python

_manifest_path

candle-org/mindnlp · src/mindact/cli/main.py:18

def _manifest_path(value: str) -> str:
    """Resolve a manifest file or run directory supplied on the CLI."""
    path = Path(value)
    if path.is_dir():
        path /= "manifest.json"
    return str(path)


def _print_manifest(path: str) -> int:
    """Print stable identity fields from an experiment manifest."""
    manifest = ExperimentManifest.read_json(path)
    data = manifest.to_dict()
    print(f"run_id: {data['run_id']}")
    print(f"experiment: {data['experiment_name']}")
    print(f"seed: {data['seed']}")
    print(f"code_revision: {data['code_revision'] or '-'}")
    for section in ("dataset", "policy", "environment", "checkpoint", "evaluation"):
        value = data[section]

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…