diff --git a/benchmarks/accelerate_opt/benchfile.py b/benchmarks/accelerate_opt/benchfile.py index b0ad099cd..78022125c 100644 --- a/benchmarks/accelerate_opt/benchfile.py +++ b/benchmarks/accelerate_opt/benchfile.py @@ -20,7 +20,7 @@ class AccelerateBenchmark(Package): def make_env(self): env = super().make_env() - value = resolve_placeholder(pack, "--cpus_per_gpu") + value = resolve_placeholder(self, "--cpus_per_gpu") env["OMP_NUM_THREADS"] = str(value) return env diff --git a/benchmate/benchmate/monitor.py b/benchmate/benchmate/monitor.py index d277c29d8..e21931458 100644 --- a/benchmate/benchmate/monitor.py +++ b/benchmate/benchmate/monitor.py @@ -24,7 +24,7 @@ def monitor_fn(): } for gpu in get_gpu_info()["gpus"].values() } - mblog({"task": "main", "gpudata": data}) + mblog({"task": "train", "gpudata": data}) monitor_fn() monitor = Monitor(3, monitor_fn) @@ -74,7 +74,7 @@ def monitor_fn(): } for gpu in get_gpu_info()["gpus"].values() } - return {"task": "main", "gpudata": data, "time": time.time(), "units": "s"} + return {"task": "train", "gpudata": data, "time": time.time(), "units": "s"} monitor = CustomMonitor(0.5, monitor_fn) diff --git a/milabench/_version.py b/milabench/_version.py index bdd9c4326..f09618832 100644 --- a/milabench/_version.py +++ b/milabench/_version.py @@ -1,5 +1,5 @@ """This file is generated, do not modify""" -__tag__ = "v0.1.0-20-g7246295a" -__commit__ = "7246295a356186b55fa4b2b75480e3700c279b15" -__date__ = "2024-06-20 09:18:17 -0400" +__tag__ = "v0.1.0-30-g94b27a71" +__commit__ = "94b27a71145d3ba754a2713aeca60e5a28be4bc5" +__date__ = "2024-06-25 13:49:52 -0400" diff --git a/milabench/log.py b/milabench/log.py index 80fec44a4..602fd02d9 100644 --- a/milabench/log.py +++ b/milabench/log.py @@ -148,7 +148,7 @@ def __call__(self, entry): elif event == "config": def _show(k, entry): - if k.startswith("config.system") or k: + if k.startswith("config.system"): return if isinstance(entry, dict): diff --git a/milabench/scripts/milabench_run.bash b/milabench/scripts/milabench_run.bash index 7ec73480e..051f764ab 100755 --- a/milabench/scripts/milabench_run.bash +++ b/milabench/scripts/milabench_run.bash @@ -29,6 +29,7 @@ BASE="$LOC/base" ENV="./env" REMAINING_ARGS="" FUN="run" +OUTPUT="$HOME/$SLURM_JOB_ID" while getopts ":hm:p:e:b:o:c:f:" opt; do case $opt in @@ -117,6 +118,9 @@ function setup() { export PYTHONUNBUFFERED=1 export MILABENCH_BASE=$BASE export MILABENCH_CONFIG=$CONFIG + export MILABENCH_VENV=$ENV + export BENCHMARK_VENV="$BASE/venv/torch" + # # Fetch the repo # @@ -161,7 +165,7 @@ function run() { cat $SYSTEM module load gcc/9.3.0 - module load cuda/11.8 + module load cuda/12.3.2 echo "" echo "Install" @@ -178,11 +182,12 @@ function run() { echo "---" milabench run --config $CONFIG --system $SYSTEM --base $BASE $REMAINING_ARGS - echo "" - echo "Report" - echo "------" + mv $BASE/runs $OUTPUT - milabench write_report_to_pr --remote $ORIGIN --branch $BRANCH --config $CONFIG + # echo "" + # echo "Report" + # echo "------" + # milabench write_report_to_pr --remote $ORIGIN --branch $BRANCH --config $CONFIG echo "----" echo "Done after $SECONDS" @@ -196,4 +201,4 @@ case "$FUN" in pin) pin ;; -esac \ No newline at end of file +esac