results: jobs/20261011-002644-large-ilqr-steer-learn/** index/episodes.jsonl leaderboard/*
Browse files- .gitattributes +5 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/breakdown.json +0 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/episodes.jsonl +3 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/done.txt +0 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/episodes.json +3 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/gautschi_launch.py +145 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/sbatch.sh +5 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/done.txt +0 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/episodes.json +3 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/gautschi_launch.py +145 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/sbatch.sh +5 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/done.txt +0 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/episodes.json +3 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/gautschi_launch.py +145 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/sbatch.sh +5 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/done.txt +0 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/episodes.json +3 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/gautschi_launch.py +145 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/sbatch.sh +5 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/job.json +133 -0
- results/jobs/20261011-002644-large-ilqr-steer-learn/summary.json +156 -0
- results/leaderboard/large-3__b37fb519b32e.json +48 -0
.gitattributes
CHANGED
|
@@ -74,3 +74,8 @@ results/jobs/20261009-102724-large-base-mppi1024/episodes.jsonl filter=lfs diff=
|
|
| 74 |
results/jobs/20261009-102724-large-base-mppi1024/gautschi/0/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 75 |
results/jobs/20261009-102724-large-base-mppi1024/gautschi/1/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 76 |
results/jobs/20261010-184358-large-ilqr-two-rate/episodes.jsonl filter=lfs diff=lfs merge=lfs -text
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 74 |
results/jobs/20261009-102724-large-base-mppi1024/gautschi/0/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 75 |
results/jobs/20261009-102724-large-base-mppi1024/gautschi/1/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 76 |
results/jobs/20261010-184358-large-ilqr-two-rate/episodes.jsonl filter=lfs diff=lfs merge=lfs -text
|
| 77 |
+
results/jobs/20261011-002644-large-ilqr-steer-learn/episodes.jsonl filter=lfs diff=lfs merge=lfs -text
|
| 78 |
+
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 79 |
+
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 80 |
+
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/episodes.json filter=lfs diff=lfs merge=lfs -text
|
| 81 |
+
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/episodes.json filter=lfs diff=lfs merge=lfs -text
|
results/jobs/20261011-002644-large-ilqr-steer-learn/breakdown.json
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
results/jobs/20261011-002644-large-ilqr-steer-learn/episodes.jsonl
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:ec32f2fffd28cfd67a7917b0802e33dfa4ced7742b5033c9b50a246a67ad2a72
|
| 3 |
+
size 42382872
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/done.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/episodes.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:b4c947b9fe414b3025163150bff5cf9d9f25bacc20cb820ac34ed4e22626fad4
|
| 3 |
+
size 23863560
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/gautschi_launch.py
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Runs on a Gautschi node (stdlib only): episodes from a queue in parallel workers, one contained Apptainer per episode."""
|
| 2 |
+
import argparse
|
| 3 |
+
import json
|
| 4 |
+
import os
|
| 5 |
+
import queue
|
| 6 |
+
import shutil
|
| 7 |
+
import subprocess
|
| 8 |
+
import threading
|
| 9 |
+
import time
|
| 10 |
+
|
| 11 |
+
RUN = ("source /opt/ros/humble/setup.bash && source /ws/install/setup.bash"
|
| 12 |
+
" && python3 -m simnode.batch /batch.json /out")
|
| 13 |
+
CUDA_LIB = "/ws/mpc_cuda/libmpc_cuda.so" # built per stack by runner/gautschi.build_stack for gautschi-gpu
|
| 14 |
+
SAMPLE_S = 15
|
| 15 |
+
STAGGER_S = 0.25 # between worker starts: the dev job's one error was a stack starved in the 96-way start burst
|
| 16 |
+
EPISODE_TIMEOUT_S = 1200 # about 4x the slowest lap; a killed episode has no outcome and is retried by the host
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
def worker_cmd(i, work, out, ep, sif, engine, stack, gpu=None):
|
| 20 |
+
"""Private /tmp, HOME, /dev/shm, IPC, PIDs and loopback per episode, plus a distinct ROS_DOMAIN_ID per worker;
|
| 21 |
+
gpu (a host CUDA device) adds the driver and the stack's CUDA MPC kernel."""
|
| 22 |
+
cuda = ["--nv", "--env", f"CUDA_VISIBLE_DEVICES={gpu}", "--env", f"MPC_CUDA_LIB={CUDA_LIB}"] if gpu is not None else []
|
| 23 |
+
if gpu is None and os.path.exists(os.path.join(stack, "mpc_cuda", "libmpc_cuda.so")):
|
| 24 |
+
cuda = ["--env", f"MPC_CUDA_LIB={CUDA_LIB}"] # CPU node: the library's native iLQR solve still loads; its MPPI falls back to numpy
|
| 25 |
+
return ["apptainer", "exec", *cuda, "--contain", "--cleanenv", "--ipc", "--pid", "--net", "--network", "none", "--workdir", work,
|
| 26 |
+
"--env", f"ROS_DOMAIN_ID={i + 1}", "--env", "ROS_HOME=/tmp/ros", "--env", "TMPDIR=/tmp",
|
| 27 |
+
"--bind", f"{engine}:/opt/sim:ro", "--bind", f"{stack}:/ws:ro", "--bind", f"{out}:/out",
|
| 28 |
+
"--bind", f"{ep}:/batch.json:ro", sif, "bash", "-lc", RUN]
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
def parse_smi(text):
|
| 32 |
+
"""nvidia-smi 'utilization.gpu, memory.used' csv rows to per-GPU lists."""
|
| 33 |
+
rows = [[int(v) for v in ln.split(",")] for ln in text.strip().splitlines() if ln.strip()]
|
| 34 |
+
return {"gpu_util": [r[0] for r in rows], "gpu_mem_mib": [r[1] for r in rows]}
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
def _solver(logdir):
|
| 38 |
+
"""pathfinder's 'MPC solver: ...' and CUDA fallback lines from the episode's ROS logs."""
|
| 39 |
+
lines = []
|
| 40 |
+
for dp, _, fns in os.walk(logdir):
|
| 41 |
+
for fn in fns:
|
| 42 |
+
try:
|
| 43 |
+
with open(os.path.join(dp, fn), errors="replace") as f:
|
| 44 |
+
lines += [ln.strip() for ln in f if "MPC solver:" in ln or "CUDA MPC unavailable" in ln]
|
| 45 |
+
except OSError:
|
| 46 |
+
pass
|
| 47 |
+
return "\n".join(dict.fromkeys(lines))
|
| 48 |
+
|
| 49 |
+
|
| 50 |
+
def main(argv=None):
|
| 51 |
+
p = argparse.ArgumentParser()
|
| 52 |
+
for a in ("episodes", "out", "sif", "engine", "stack", "work", "timeline", "done"):
|
| 53 |
+
p.add_argument("--" + a, required=True)
|
| 54 |
+
p.add_argument("--workers", type=int, required=True)
|
| 55 |
+
p.add_argument("--gpus", type=int, default=0)
|
| 56 |
+
a = p.parse_args(argv)
|
| 57 |
+
with open(a.episodes) as f:
|
| 58 |
+
q = queue.Queue()
|
| 59 |
+
for e in json.load(f): # the host already ordered them, longest first
|
| 60 |
+
q.put(e)
|
| 61 |
+
os.makedirs(a.out, exist_ok=True)
|
| 62 |
+
lock, t0 = threading.Lock(), time.time()
|
| 63 |
+
devs = [d for d in os.environ.get("CUDA_VISIBLE_DEVICES", "").split(",") if d][:a.gpus] or [str(n) for n in range(a.gpus)]
|
| 64 |
+
|
| 65 |
+
def log(**ev):
|
| 66 |
+
with lock, open(a.timeline, "a") as f:
|
| 67 |
+
f.write(json.dumps(dict(ev, t=round(time.time() - t0, 3))) + "\n")
|
| 68 |
+
|
| 69 |
+
def worker(i):
|
| 70 |
+
time.sleep(i * STAGGER_S)
|
| 71 |
+
while True:
|
| 72 |
+
try:
|
| 73 |
+
e = q.get_nowait()
|
| 74 |
+
except queue.Empty:
|
| 75 |
+
return
|
| 76 |
+
key, work = e["key"], os.path.join(a.work, e["key"])
|
| 77 |
+
stage, ep = os.path.join(work, "stage"), os.path.join(work, "ep.json")
|
| 78 |
+
os.makedirs(stage)
|
| 79 |
+
with open(ep, "w") as f:
|
| 80 |
+
json.dump([e], f)
|
| 81 |
+
log(ev="start", key=key, worker=i)
|
| 82 |
+
gpu = devs[i % len(devs)] if devs and e["resolved"].get("recipe", {}).get("sim", {}).get("cuda") else None
|
| 83 |
+
limit = EPISODE_TIMEOUT_S * max(1, e["resolved"]["scenario"].get("laps", 1)) # per lap: 5-lap episodes run 5x longer
|
| 84 |
+
try:
|
| 85 |
+
rc = subprocess.run(worker_cmd(i, work, stage, ep, a.sif, a.engine, a.stack, gpu), stdout=subprocess.DEVNULL,
|
| 86 |
+
stderr=subprocess.DEVNULL, timeout=limit).returncode
|
| 87 |
+
except subprocess.TimeoutExpired:
|
| 88 |
+
rc = "timeout"
|
| 89 |
+
solver = _solver(os.path.join(work, "tmp", "ros", "log"))
|
| 90 |
+
if solver and os.path.isdir(os.path.join(stage, key)):
|
| 91 |
+
with open(os.path.join(stage, key, "solver.txt"), "w") as f:
|
| 92 |
+
f.write(solver + "\n")
|
| 93 |
+
if os.path.exists(os.path.join(stage, key, "outcome.json")):
|
| 94 |
+
tmp, dst = os.path.join(a.out, ".tmp-" + key), os.path.join(a.out, key)
|
| 95 |
+
shutil.rmtree(tmp, ignore_errors=True)
|
| 96 |
+
shutil.copytree(os.path.join(stage, key), tmp)
|
| 97 |
+
shutil.rmtree(dst, ignore_errors=True)
|
| 98 |
+
os.rename(tmp, dst) # the host's rsync sees a key only once its directory is complete
|
| 99 |
+
with lock, open(a.done, "a") as f:
|
| 100 |
+
f.write(key + "\n")
|
| 101 |
+
shutil.rmtree(work, ignore_errors=True)
|
| 102 |
+
log(ev="end", key=key, worker=i, rc=rc, gpu=gpu,
|
| 103 |
+
solver=solver.split("MPC solver: ")[-1] if "MPC solver: " in solver else solver or None)
|
| 104 |
+
|
| 105 |
+
def sampler(stop):
|
| 106 |
+
"""Job CPU use from its cgroup, as busy cores, every SAMPLE_S."""
|
| 107 |
+
try:
|
| 108 |
+
with open("/proc/self/cgroup") as f:
|
| 109 |
+
path = "/sys/fs/cgroup" + f.read().strip().split(":")[-1] + "/cpu.stat"
|
| 110 |
+
prev = None
|
| 111 |
+
while not stop.wait(SAMPLE_S if prev else 0):
|
| 112 |
+
with open(path) as f:
|
| 113 |
+
use = next(int(ln.split()[1]) for ln in f if ln.startswith("usage_usec"))
|
| 114 |
+
now = time.time()
|
| 115 |
+
if prev:
|
| 116 |
+
log(ev="cpu", busy_cores=round((use - prev[0]) / 1e6 / (now - prev[1]), 2))
|
| 117 |
+
prev = (use, now)
|
| 118 |
+
except (OSError, StopIteration, ValueError):
|
| 119 |
+
pass
|
| 120 |
+
|
| 121 |
+
def gpu_sampler(stop):
|
| 122 |
+
"""GPU utilisation and memory of the job's GPUs, every SAMPLE_S."""
|
| 123 |
+
while not stop.wait(SAMPLE_S):
|
| 124 |
+
try:
|
| 125 |
+
p = subprocess.Popen(["nvidia-smi", "--query-gpu=utilization.gpu,memory.used", "--format=csv,noheader,nounits"],
|
| 126 |
+
stdout=subprocess.PIPE, stderr=subprocess.DEVNULL, text=True)
|
| 127 |
+
log(ev="gpu", **parse_smi(p.communicate(timeout=30)[0]))
|
| 128 |
+
except Exception: # no driver or a hung query: skip this sample
|
| 129 |
+
pass
|
| 130 |
+
|
| 131 |
+
cores = len(os.sched_getaffinity(0)) if hasattr(os, "sched_getaffinity") else os.cpu_count()
|
| 132 |
+
log(ev="launch", workers=a.workers, cores=cores)
|
| 133 |
+
stop = threading.Event()
|
| 134 |
+
threads = [threading.Thread(target=worker, args=(i,)) for i in range(a.workers)]
|
| 135 |
+
samplers = [sampler] + ([gpu_sampler] if a.gpus else [])
|
| 136 |
+
for t in threads + [threading.Thread(target=f, args=(stop,), daemon=True) for f in samplers]:
|
| 137 |
+
t.start()
|
| 138 |
+
for t in threads:
|
| 139 |
+
t.join()
|
| 140 |
+
stop.set()
|
| 141 |
+
log(ev="done")
|
| 142 |
+
|
| 143 |
+
|
| 144 |
+
if __name__ == "__main__":
|
| 145 |
+
main()
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/0/sbatch.sh
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/bin/bash
|
| 2 |
+
#SBATCH -p highmem -A lilly-rob1 -N 1 -n 1 -c 192 --time 177 -J AutoSim-large-large-ilqr-steer-learn-1 --comment 20261011-002644-large-ilqr-steer-learn -o AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/0/slurm-%j.out
|
| 3 |
+
W=/dev/shm/AutoSim-$SLURM_JOB_ID
|
| 4 |
+
trap 'rm -rf "$W"' EXIT
|
| 5 |
+
python3 $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/0/gautschi_launch.py --episodes $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/0/episodes.json --out /scratch/gautschi/manors/AutoSim/out/20261011-002644-large-ilqr-steer-learn --sif $HOME/AutoSim/images/AutoSim-99d206f40cb1.sif --engine $HOME/AutoSim/engine/b37fb519b32e564d2d8a8ea1259cbf2e695ba1a28d93504f20e4c2970a4f6f00 --stack $HOME/AutoSim/stacks/09f6048d97a12a43c7f0539e9db22b0251c622d6cafda2946841254a27f32824 --workers 96 --work $W --timeline $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/0/timeline.jsonl --done $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/0/done.txt
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/done.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/episodes.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cc42687066dd1bb4435872808f2f9ca935eb7d9467ca1d4acdccb65b7f68aa09
|
| 3 |
+
size 23863595
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/gautschi_launch.py
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Runs on a Gautschi node (stdlib only): episodes from a queue in parallel workers, one contained Apptainer per episode."""
|
| 2 |
+
import argparse
|
| 3 |
+
import json
|
| 4 |
+
import os
|
| 5 |
+
import queue
|
| 6 |
+
import shutil
|
| 7 |
+
import subprocess
|
| 8 |
+
import threading
|
| 9 |
+
import time
|
| 10 |
+
|
| 11 |
+
RUN = ("source /opt/ros/humble/setup.bash && source /ws/install/setup.bash"
|
| 12 |
+
" && python3 -m simnode.batch /batch.json /out")
|
| 13 |
+
CUDA_LIB = "/ws/mpc_cuda/libmpc_cuda.so" # built per stack by runner/gautschi.build_stack for gautschi-gpu
|
| 14 |
+
SAMPLE_S = 15
|
| 15 |
+
STAGGER_S = 0.25 # between worker starts: the dev job's one error was a stack starved in the 96-way start burst
|
| 16 |
+
EPISODE_TIMEOUT_S = 1200 # about 4x the slowest lap; a killed episode has no outcome and is retried by the host
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
def worker_cmd(i, work, out, ep, sif, engine, stack, gpu=None):
|
| 20 |
+
"""Private /tmp, HOME, /dev/shm, IPC, PIDs and loopback per episode, plus a distinct ROS_DOMAIN_ID per worker;
|
| 21 |
+
gpu (a host CUDA device) adds the driver and the stack's CUDA MPC kernel."""
|
| 22 |
+
cuda = ["--nv", "--env", f"CUDA_VISIBLE_DEVICES={gpu}", "--env", f"MPC_CUDA_LIB={CUDA_LIB}"] if gpu is not None else []
|
| 23 |
+
if gpu is None and os.path.exists(os.path.join(stack, "mpc_cuda", "libmpc_cuda.so")):
|
| 24 |
+
cuda = ["--env", f"MPC_CUDA_LIB={CUDA_LIB}"] # CPU node: the library's native iLQR solve still loads; its MPPI falls back to numpy
|
| 25 |
+
return ["apptainer", "exec", *cuda, "--contain", "--cleanenv", "--ipc", "--pid", "--net", "--network", "none", "--workdir", work,
|
| 26 |
+
"--env", f"ROS_DOMAIN_ID={i + 1}", "--env", "ROS_HOME=/tmp/ros", "--env", "TMPDIR=/tmp",
|
| 27 |
+
"--bind", f"{engine}:/opt/sim:ro", "--bind", f"{stack}:/ws:ro", "--bind", f"{out}:/out",
|
| 28 |
+
"--bind", f"{ep}:/batch.json:ro", sif, "bash", "-lc", RUN]
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
def parse_smi(text):
|
| 32 |
+
"""nvidia-smi 'utilization.gpu, memory.used' csv rows to per-GPU lists."""
|
| 33 |
+
rows = [[int(v) for v in ln.split(",")] for ln in text.strip().splitlines() if ln.strip()]
|
| 34 |
+
return {"gpu_util": [r[0] for r in rows], "gpu_mem_mib": [r[1] for r in rows]}
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
def _solver(logdir):
|
| 38 |
+
"""pathfinder's 'MPC solver: ...' and CUDA fallback lines from the episode's ROS logs."""
|
| 39 |
+
lines = []
|
| 40 |
+
for dp, _, fns in os.walk(logdir):
|
| 41 |
+
for fn in fns:
|
| 42 |
+
try:
|
| 43 |
+
with open(os.path.join(dp, fn), errors="replace") as f:
|
| 44 |
+
lines += [ln.strip() for ln in f if "MPC solver:" in ln or "CUDA MPC unavailable" in ln]
|
| 45 |
+
except OSError:
|
| 46 |
+
pass
|
| 47 |
+
return "\n".join(dict.fromkeys(lines))
|
| 48 |
+
|
| 49 |
+
|
| 50 |
+
def main(argv=None):
|
| 51 |
+
p = argparse.ArgumentParser()
|
| 52 |
+
for a in ("episodes", "out", "sif", "engine", "stack", "work", "timeline", "done"):
|
| 53 |
+
p.add_argument("--" + a, required=True)
|
| 54 |
+
p.add_argument("--workers", type=int, required=True)
|
| 55 |
+
p.add_argument("--gpus", type=int, default=0)
|
| 56 |
+
a = p.parse_args(argv)
|
| 57 |
+
with open(a.episodes) as f:
|
| 58 |
+
q = queue.Queue()
|
| 59 |
+
for e in json.load(f): # the host already ordered them, longest first
|
| 60 |
+
q.put(e)
|
| 61 |
+
os.makedirs(a.out, exist_ok=True)
|
| 62 |
+
lock, t0 = threading.Lock(), time.time()
|
| 63 |
+
devs = [d for d in os.environ.get("CUDA_VISIBLE_DEVICES", "").split(",") if d][:a.gpus] or [str(n) for n in range(a.gpus)]
|
| 64 |
+
|
| 65 |
+
def log(**ev):
|
| 66 |
+
with lock, open(a.timeline, "a") as f:
|
| 67 |
+
f.write(json.dumps(dict(ev, t=round(time.time() - t0, 3))) + "\n")
|
| 68 |
+
|
| 69 |
+
def worker(i):
|
| 70 |
+
time.sleep(i * STAGGER_S)
|
| 71 |
+
while True:
|
| 72 |
+
try:
|
| 73 |
+
e = q.get_nowait()
|
| 74 |
+
except queue.Empty:
|
| 75 |
+
return
|
| 76 |
+
key, work = e["key"], os.path.join(a.work, e["key"])
|
| 77 |
+
stage, ep = os.path.join(work, "stage"), os.path.join(work, "ep.json")
|
| 78 |
+
os.makedirs(stage)
|
| 79 |
+
with open(ep, "w") as f:
|
| 80 |
+
json.dump([e], f)
|
| 81 |
+
log(ev="start", key=key, worker=i)
|
| 82 |
+
gpu = devs[i % len(devs)] if devs and e["resolved"].get("recipe", {}).get("sim", {}).get("cuda") else None
|
| 83 |
+
limit = EPISODE_TIMEOUT_S * max(1, e["resolved"]["scenario"].get("laps", 1)) # per lap: 5-lap episodes run 5x longer
|
| 84 |
+
try:
|
| 85 |
+
rc = subprocess.run(worker_cmd(i, work, stage, ep, a.sif, a.engine, a.stack, gpu), stdout=subprocess.DEVNULL,
|
| 86 |
+
stderr=subprocess.DEVNULL, timeout=limit).returncode
|
| 87 |
+
except subprocess.TimeoutExpired:
|
| 88 |
+
rc = "timeout"
|
| 89 |
+
solver = _solver(os.path.join(work, "tmp", "ros", "log"))
|
| 90 |
+
if solver and os.path.isdir(os.path.join(stage, key)):
|
| 91 |
+
with open(os.path.join(stage, key, "solver.txt"), "w") as f:
|
| 92 |
+
f.write(solver + "\n")
|
| 93 |
+
if os.path.exists(os.path.join(stage, key, "outcome.json")):
|
| 94 |
+
tmp, dst = os.path.join(a.out, ".tmp-" + key), os.path.join(a.out, key)
|
| 95 |
+
shutil.rmtree(tmp, ignore_errors=True)
|
| 96 |
+
shutil.copytree(os.path.join(stage, key), tmp)
|
| 97 |
+
shutil.rmtree(dst, ignore_errors=True)
|
| 98 |
+
os.rename(tmp, dst) # the host's rsync sees a key only once its directory is complete
|
| 99 |
+
with lock, open(a.done, "a") as f:
|
| 100 |
+
f.write(key + "\n")
|
| 101 |
+
shutil.rmtree(work, ignore_errors=True)
|
| 102 |
+
log(ev="end", key=key, worker=i, rc=rc, gpu=gpu,
|
| 103 |
+
solver=solver.split("MPC solver: ")[-1] if "MPC solver: " in solver else solver or None)
|
| 104 |
+
|
| 105 |
+
def sampler(stop):
|
| 106 |
+
"""Job CPU use from its cgroup, as busy cores, every SAMPLE_S."""
|
| 107 |
+
try:
|
| 108 |
+
with open("/proc/self/cgroup") as f:
|
| 109 |
+
path = "/sys/fs/cgroup" + f.read().strip().split(":")[-1] + "/cpu.stat"
|
| 110 |
+
prev = None
|
| 111 |
+
while not stop.wait(SAMPLE_S if prev else 0):
|
| 112 |
+
with open(path) as f:
|
| 113 |
+
use = next(int(ln.split()[1]) for ln in f if ln.startswith("usage_usec"))
|
| 114 |
+
now = time.time()
|
| 115 |
+
if prev:
|
| 116 |
+
log(ev="cpu", busy_cores=round((use - prev[0]) / 1e6 / (now - prev[1]), 2))
|
| 117 |
+
prev = (use, now)
|
| 118 |
+
except (OSError, StopIteration, ValueError):
|
| 119 |
+
pass
|
| 120 |
+
|
| 121 |
+
def gpu_sampler(stop):
|
| 122 |
+
"""GPU utilisation and memory of the job's GPUs, every SAMPLE_S."""
|
| 123 |
+
while not stop.wait(SAMPLE_S):
|
| 124 |
+
try:
|
| 125 |
+
p = subprocess.Popen(["nvidia-smi", "--query-gpu=utilization.gpu,memory.used", "--format=csv,noheader,nounits"],
|
| 126 |
+
stdout=subprocess.PIPE, stderr=subprocess.DEVNULL, text=True)
|
| 127 |
+
log(ev="gpu", **parse_smi(p.communicate(timeout=30)[0]))
|
| 128 |
+
except Exception: # no driver or a hung query: skip this sample
|
| 129 |
+
pass
|
| 130 |
+
|
| 131 |
+
cores = len(os.sched_getaffinity(0)) if hasattr(os, "sched_getaffinity") else os.cpu_count()
|
| 132 |
+
log(ev="launch", workers=a.workers, cores=cores)
|
| 133 |
+
stop = threading.Event()
|
| 134 |
+
threads = [threading.Thread(target=worker, args=(i,)) for i in range(a.workers)]
|
| 135 |
+
samplers = [sampler] + ([gpu_sampler] if a.gpus else [])
|
| 136 |
+
for t in threads + [threading.Thread(target=f, args=(stop,), daemon=True) for f in samplers]:
|
| 137 |
+
t.start()
|
| 138 |
+
for t in threads:
|
| 139 |
+
t.join()
|
| 140 |
+
stop.set()
|
| 141 |
+
log(ev="done")
|
| 142 |
+
|
| 143 |
+
|
| 144 |
+
if __name__ == "__main__":
|
| 145 |
+
main()
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/1/sbatch.sh
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/bin/bash
|
| 2 |
+
#SBATCH -p highmem -A lilly-rob1 -N 1 -n 1 -c 192 --time 177 -J AutoSim-large-large-ilqr-steer-learn-2 --comment 20261011-002644-large-ilqr-steer-learn -o AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/1/slurm-%j.out
|
| 3 |
+
W=/dev/shm/AutoSim-$SLURM_JOB_ID
|
| 4 |
+
trap 'rm -rf "$W"' EXIT
|
| 5 |
+
python3 $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/1/gautschi_launch.py --episodes $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/1/episodes.json --out /scratch/gautschi/manors/AutoSim/out/20261011-002644-large-ilqr-steer-learn --sif $HOME/AutoSim/images/AutoSim-99d206f40cb1.sif --engine $HOME/AutoSim/engine/b37fb519b32e564d2d8a8ea1259cbf2e695ba1a28d93504f20e4c2970a4f6f00 --stack $HOME/AutoSim/stacks/09f6048d97a12a43c7f0539e9db22b0251c622d6cafda2946841254a27f32824 --workers 96 --work $W --timeline $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/1/timeline.jsonl --done $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/1/done.txt
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/done.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/episodes.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:4173afcc40a795fe3f2a0d6220b34f2ece0bf4761b10d25712002f43a1e8fbc2
|
| 3 |
+
size 23863551
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/gautschi_launch.py
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Runs on a Gautschi node (stdlib only): episodes from a queue in parallel workers, one contained Apptainer per episode."""
|
| 2 |
+
import argparse
|
| 3 |
+
import json
|
| 4 |
+
import os
|
| 5 |
+
import queue
|
| 6 |
+
import shutil
|
| 7 |
+
import subprocess
|
| 8 |
+
import threading
|
| 9 |
+
import time
|
| 10 |
+
|
| 11 |
+
RUN = ("source /opt/ros/humble/setup.bash && source /ws/install/setup.bash"
|
| 12 |
+
" && python3 -m simnode.batch /batch.json /out")
|
| 13 |
+
CUDA_LIB = "/ws/mpc_cuda/libmpc_cuda.so" # built per stack by runner/gautschi.build_stack for gautschi-gpu
|
| 14 |
+
SAMPLE_S = 15
|
| 15 |
+
STAGGER_S = 0.25 # between worker starts: the dev job's one error was a stack starved in the 96-way start burst
|
| 16 |
+
EPISODE_TIMEOUT_S = 1200 # about 4x the slowest lap; a killed episode has no outcome and is retried by the host
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
def worker_cmd(i, work, out, ep, sif, engine, stack, gpu=None):
|
| 20 |
+
"""Private /tmp, HOME, /dev/shm, IPC, PIDs and loopback per episode, plus a distinct ROS_DOMAIN_ID per worker;
|
| 21 |
+
gpu (a host CUDA device) adds the driver and the stack's CUDA MPC kernel."""
|
| 22 |
+
cuda = ["--nv", "--env", f"CUDA_VISIBLE_DEVICES={gpu}", "--env", f"MPC_CUDA_LIB={CUDA_LIB}"] if gpu is not None else []
|
| 23 |
+
if gpu is None and os.path.exists(os.path.join(stack, "mpc_cuda", "libmpc_cuda.so")):
|
| 24 |
+
cuda = ["--env", f"MPC_CUDA_LIB={CUDA_LIB}"] # CPU node: the library's native iLQR solve still loads; its MPPI falls back to numpy
|
| 25 |
+
return ["apptainer", "exec", *cuda, "--contain", "--cleanenv", "--ipc", "--pid", "--net", "--network", "none", "--workdir", work,
|
| 26 |
+
"--env", f"ROS_DOMAIN_ID={i + 1}", "--env", "ROS_HOME=/tmp/ros", "--env", "TMPDIR=/tmp",
|
| 27 |
+
"--bind", f"{engine}:/opt/sim:ro", "--bind", f"{stack}:/ws:ro", "--bind", f"{out}:/out",
|
| 28 |
+
"--bind", f"{ep}:/batch.json:ro", sif, "bash", "-lc", RUN]
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
def parse_smi(text):
|
| 32 |
+
"""nvidia-smi 'utilization.gpu, memory.used' csv rows to per-GPU lists."""
|
| 33 |
+
rows = [[int(v) for v in ln.split(",")] for ln in text.strip().splitlines() if ln.strip()]
|
| 34 |
+
return {"gpu_util": [r[0] for r in rows], "gpu_mem_mib": [r[1] for r in rows]}
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
def _solver(logdir):
|
| 38 |
+
"""pathfinder's 'MPC solver: ...' and CUDA fallback lines from the episode's ROS logs."""
|
| 39 |
+
lines = []
|
| 40 |
+
for dp, _, fns in os.walk(logdir):
|
| 41 |
+
for fn in fns:
|
| 42 |
+
try:
|
| 43 |
+
with open(os.path.join(dp, fn), errors="replace") as f:
|
| 44 |
+
lines += [ln.strip() for ln in f if "MPC solver:" in ln or "CUDA MPC unavailable" in ln]
|
| 45 |
+
except OSError:
|
| 46 |
+
pass
|
| 47 |
+
return "\n".join(dict.fromkeys(lines))
|
| 48 |
+
|
| 49 |
+
|
| 50 |
+
def main(argv=None):
|
| 51 |
+
p = argparse.ArgumentParser()
|
| 52 |
+
for a in ("episodes", "out", "sif", "engine", "stack", "work", "timeline", "done"):
|
| 53 |
+
p.add_argument("--" + a, required=True)
|
| 54 |
+
p.add_argument("--workers", type=int, required=True)
|
| 55 |
+
p.add_argument("--gpus", type=int, default=0)
|
| 56 |
+
a = p.parse_args(argv)
|
| 57 |
+
with open(a.episodes) as f:
|
| 58 |
+
q = queue.Queue()
|
| 59 |
+
for e in json.load(f): # the host already ordered them, longest first
|
| 60 |
+
q.put(e)
|
| 61 |
+
os.makedirs(a.out, exist_ok=True)
|
| 62 |
+
lock, t0 = threading.Lock(), time.time()
|
| 63 |
+
devs = [d for d in os.environ.get("CUDA_VISIBLE_DEVICES", "").split(",") if d][:a.gpus] or [str(n) for n in range(a.gpus)]
|
| 64 |
+
|
| 65 |
+
def log(**ev):
|
| 66 |
+
with lock, open(a.timeline, "a") as f:
|
| 67 |
+
f.write(json.dumps(dict(ev, t=round(time.time() - t0, 3))) + "\n")
|
| 68 |
+
|
| 69 |
+
def worker(i):
|
| 70 |
+
time.sleep(i * STAGGER_S)
|
| 71 |
+
while True:
|
| 72 |
+
try:
|
| 73 |
+
e = q.get_nowait()
|
| 74 |
+
except queue.Empty:
|
| 75 |
+
return
|
| 76 |
+
key, work = e["key"], os.path.join(a.work, e["key"])
|
| 77 |
+
stage, ep = os.path.join(work, "stage"), os.path.join(work, "ep.json")
|
| 78 |
+
os.makedirs(stage)
|
| 79 |
+
with open(ep, "w") as f:
|
| 80 |
+
json.dump([e], f)
|
| 81 |
+
log(ev="start", key=key, worker=i)
|
| 82 |
+
gpu = devs[i % len(devs)] if devs and e["resolved"].get("recipe", {}).get("sim", {}).get("cuda") else None
|
| 83 |
+
limit = EPISODE_TIMEOUT_S * max(1, e["resolved"]["scenario"].get("laps", 1)) # per lap: 5-lap episodes run 5x longer
|
| 84 |
+
try:
|
| 85 |
+
rc = subprocess.run(worker_cmd(i, work, stage, ep, a.sif, a.engine, a.stack, gpu), stdout=subprocess.DEVNULL,
|
| 86 |
+
stderr=subprocess.DEVNULL, timeout=limit).returncode
|
| 87 |
+
except subprocess.TimeoutExpired:
|
| 88 |
+
rc = "timeout"
|
| 89 |
+
solver = _solver(os.path.join(work, "tmp", "ros", "log"))
|
| 90 |
+
if solver and os.path.isdir(os.path.join(stage, key)):
|
| 91 |
+
with open(os.path.join(stage, key, "solver.txt"), "w") as f:
|
| 92 |
+
f.write(solver + "\n")
|
| 93 |
+
if os.path.exists(os.path.join(stage, key, "outcome.json")):
|
| 94 |
+
tmp, dst = os.path.join(a.out, ".tmp-" + key), os.path.join(a.out, key)
|
| 95 |
+
shutil.rmtree(tmp, ignore_errors=True)
|
| 96 |
+
shutil.copytree(os.path.join(stage, key), tmp)
|
| 97 |
+
shutil.rmtree(dst, ignore_errors=True)
|
| 98 |
+
os.rename(tmp, dst) # the host's rsync sees a key only once its directory is complete
|
| 99 |
+
with lock, open(a.done, "a") as f:
|
| 100 |
+
f.write(key + "\n")
|
| 101 |
+
shutil.rmtree(work, ignore_errors=True)
|
| 102 |
+
log(ev="end", key=key, worker=i, rc=rc, gpu=gpu,
|
| 103 |
+
solver=solver.split("MPC solver: ")[-1] if "MPC solver: " in solver else solver or None)
|
| 104 |
+
|
| 105 |
+
def sampler(stop):
|
| 106 |
+
"""Job CPU use from its cgroup, as busy cores, every SAMPLE_S."""
|
| 107 |
+
try:
|
| 108 |
+
with open("/proc/self/cgroup") as f:
|
| 109 |
+
path = "/sys/fs/cgroup" + f.read().strip().split(":")[-1] + "/cpu.stat"
|
| 110 |
+
prev = None
|
| 111 |
+
while not stop.wait(SAMPLE_S if prev else 0):
|
| 112 |
+
with open(path) as f:
|
| 113 |
+
use = next(int(ln.split()[1]) for ln in f if ln.startswith("usage_usec"))
|
| 114 |
+
now = time.time()
|
| 115 |
+
if prev:
|
| 116 |
+
log(ev="cpu", busy_cores=round((use - prev[0]) / 1e6 / (now - prev[1]), 2))
|
| 117 |
+
prev = (use, now)
|
| 118 |
+
except (OSError, StopIteration, ValueError):
|
| 119 |
+
pass
|
| 120 |
+
|
| 121 |
+
def gpu_sampler(stop):
|
| 122 |
+
"""GPU utilisation and memory of the job's GPUs, every SAMPLE_S."""
|
| 123 |
+
while not stop.wait(SAMPLE_S):
|
| 124 |
+
try:
|
| 125 |
+
p = subprocess.Popen(["nvidia-smi", "--query-gpu=utilization.gpu,memory.used", "--format=csv,noheader,nounits"],
|
| 126 |
+
stdout=subprocess.PIPE, stderr=subprocess.DEVNULL, text=True)
|
| 127 |
+
log(ev="gpu", **parse_smi(p.communicate(timeout=30)[0]))
|
| 128 |
+
except Exception: # no driver or a hung query: skip this sample
|
| 129 |
+
pass
|
| 130 |
+
|
| 131 |
+
cores = len(os.sched_getaffinity(0)) if hasattr(os, "sched_getaffinity") else os.cpu_count()
|
| 132 |
+
log(ev="launch", workers=a.workers, cores=cores)
|
| 133 |
+
stop = threading.Event()
|
| 134 |
+
threads = [threading.Thread(target=worker, args=(i,)) for i in range(a.workers)]
|
| 135 |
+
samplers = [sampler] + ([gpu_sampler] if a.gpus else [])
|
| 136 |
+
for t in threads + [threading.Thread(target=f, args=(stop,), daemon=True) for f in samplers]:
|
| 137 |
+
t.start()
|
| 138 |
+
for t in threads:
|
| 139 |
+
t.join()
|
| 140 |
+
stop.set()
|
| 141 |
+
log(ev="done")
|
| 142 |
+
|
| 143 |
+
|
| 144 |
+
if __name__ == "__main__":
|
| 145 |
+
main()
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/2/sbatch.sh
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/bin/bash
|
| 2 |
+
#SBATCH -p highmem -A lilly-rob1 -N 1 -n 1 -c 192 --time 177 --dependency=afterany:16948095 -J AutoSim-large-large-ilqr-steer-learn-3 --comment 20261011-002644-large-ilqr-steer-learn -o AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/2/slurm-%j.out
|
| 3 |
+
W=/dev/shm/AutoSim-$SLURM_JOB_ID
|
| 4 |
+
trap 'rm -rf "$W"' EXIT
|
| 5 |
+
python3 $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/2/gautschi_launch.py --episodes $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/2/episodes.json --out /scratch/gautschi/manors/AutoSim/out/20261011-002644-large-ilqr-steer-learn --sif $HOME/AutoSim/images/AutoSim-99d206f40cb1.sif --engine $HOME/AutoSim/engine/b37fb519b32e564d2d8a8ea1259cbf2e695ba1a28d93504f20e4c2970a4f6f00 --stack $HOME/AutoSim/stacks/09f6048d97a12a43c7f0539e9db22b0251c622d6cafda2946841254a27f32824 --workers 96 --work $W --timeline $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/2/timeline.jsonl --done $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/2/done.txt
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/done.txt
ADDED
|
The diff for this file is too large to render.
See raw diff
|
|
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/episodes.json
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:cc6199c1dd325ec16c9f19e273f889af224186438446d4bf963d0866f975a521
|
| 3 |
+
size 23863444
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/gautschi_launch.py
ADDED
|
@@ -0,0 +1,145 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
"""Runs on a Gautschi node (stdlib only): episodes from a queue in parallel workers, one contained Apptainer per episode."""
|
| 2 |
+
import argparse
|
| 3 |
+
import json
|
| 4 |
+
import os
|
| 5 |
+
import queue
|
| 6 |
+
import shutil
|
| 7 |
+
import subprocess
|
| 8 |
+
import threading
|
| 9 |
+
import time
|
| 10 |
+
|
| 11 |
+
RUN = ("source /opt/ros/humble/setup.bash && source /ws/install/setup.bash"
|
| 12 |
+
" && python3 -m simnode.batch /batch.json /out")
|
| 13 |
+
CUDA_LIB = "/ws/mpc_cuda/libmpc_cuda.so" # built per stack by runner/gautschi.build_stack for gautschi-gpu
|
| 14 |
+
SAMPLE_S = 15
|
| 15 |
+
STAGGER_S = 0.25 # between worker starts: the dev job's one error was a stack starved in the 96-way start burst
|
| 16 |
+
EPISODE_TIMEOUT_S = 1200 # about 4x the slowest lap; a killed episode has no outcome and is retried by the host
|
| 17 |
+
|
| 18 |
+
|
| 19 |
+
def worker_cmd(i, work, out, ep, sif, engine, stack, gpu=None):
|
| 20 |
+
"""Private /tmp, HOME, /dev/shm, IPC, PIDs and loopback per episode, plus a distinct ROS_DOMAIN_ID per worker;
|
| 21 |
+
gpu (a host CUDA device) adds the driver and the stack's CUDA MPC kernel."""
|
| 22 |
+
cuda = ["--nv", "--env", f"CUDA_VISIBLE_DEVICES={gpu}", "--env", f"MPC_CUDA_LIB={CUDA_LIB}"] if gpu is not None else []
|
| 23 |
+
if gpu is None and os.path.exists(os.path.join(stack, "mpc_cuda", "libmpc_cuda.so")):
|
| 24 |
+
cuda = ["--env", f"MPC_CUDA_LIB={CUDA_LIB}"] # CPU node: the library's native iLQR solve still loads; its MPPI falls back to numpy
|
| 25 |
+
return ["apptainer", "exec", *cuda, "--contain", "--cleanenv", "--ipc", "--pid", "--net", "--network", "none", "--workdir", work,
|
| 26 |
+
"--env", f"ROS_DOMAIN_ID={i + 1}", "--env", "ROS_HOME=/tmp/ros", "--env", "TMPDIR=/tmp",
|
| 27 |
+
"--bind", f"{engine}:/opt/sim:ro", "--bind", f"{stack}:/ws:ro", "--bind", f"{out}:/out",
|
| 28 |
+
"--bind", f"{ep}:/batch.json:ro", sif, "bash", "-lc", RUN]
|
| 29 |
+
|
| 30 |
+
|
| 31 |
+
def parse_smi(text):
|
| 32 |
+
"""nvidia-smi 'utilization.gpu, memory.used' csv rows to per-GPU lists."""
|
| 33 |
+
rows = [[int(v) for v in ln.split(",")] for ln in text.strip().splitlines() if ln.strip()]
|
| 34 |
+
return {"gpu_util": [r[0] for r in rows], "gpu_mem_mib": [r[1] for r in rows]}
|
| 35 |
+
|
| 36 |
+
|
| 37 |
+
def _solver(logdir):
|
| 38 |
+
"""pathfinder's 'MPC solver: ...' and CUDA fallback lines from the episode's ROS logs."""
|
| 39 |
+
lines = []
|
| 40 |
+
for dp, _, fns in os.walk(logdir):
|
| 41 |
+
for fn in fns:
|
| 42 |
+
try:
|
| 43 |
+
with open(os.path.join(dp, fn), errors="replace") as f:
|
| 44 |
+
lines += [ln.strip() for ln in f if "MPC solver:" in ln or "CUDA MPC unavailable" in ln]
|
| 45 |
+
except OSError:
|
| 46 |
+
pass
|
| 47 |
+
return "\n".join(dict.fromkeys(lines))
|
| 48 |
+
|
| 49 |
+
|
| 50 |
+
def main(argv=None):
|
| 51 |
+
p = argparse.ArgumentParser()
|
| 52 |
+
for a in ("episodes", "out", "sif", "engine", "stack", "work", "timeline", "done"):
|
| 53 |
+
p.add_argument("--" + a, required=True)
|
| 54 |
+
p.add_argument("--workers", type=int, required=True)
|
| 55 |
+
p.add_argument("--gpus", type=int, default=0)
|
| 56 |
+
a = p.parse_args(argv)
|
| 57 |
+
with open(a.episodes) as f:
|
| 58 |
+
q = queue.Queue()
|
| 59 |
+
for e in json.load(f): # the host already ordered them, longest first
|
| 60 |
+
q.put(e)
|
| 61 |
+
os.makedirs(a.out, exist_ok=True)
|
| 62 |
+
lock, t0 = threading.Lock(), time.time()
|
| 63 |
+
devs = [d for d in os.environ.get("CUDA_VISIBLE_DEVICES", "").split(",") if d][:a.gpus] or [str(n) for n in range(a.gpus)]
|
| 64 |
+
|
| 65 |
+
def log(**ev):
|
| 66 |
+
with lock, open(a.timeline, "a") as f:
|
| 67 |
+
f.write(json.dumps(dict(ev, t=round(time.time() - t0, 3))) + "\n")
|
| 68 |
+
|
| 69 |
+
def worker(i):
|
| 70 |
+
time.sleep(i * STAGGER_S)
|
| 71 |
+
while True:
|
| 72 |
+
try:
|
| 73 |
+
e = q.get_nowait()
|
| 74 |
+
except queue.Empty:
|
| 75 |
+
return
|
| 76 |
+
key, work = e["key"], os.path.join(a.work, e["key"])
|
| 77 |
+
stage, ep = os.path.join(work, "stage"), os.path.join(work, "ep.json")
|
| 78 |
+
os.makedirs(stage)
|
| 79 |
+
with open(ep, "w") as f:
|
| 80 |
+
json.dump([e], f)
|
| 81 |
+
log(ev="start", key=key, worker=i)
|
| 82 |
+
gpu = devs[i % len(devs)] if devs and e["resolved"].get("recipe", {}).get("sim", {}).get("cuda") else None
|
| 83 |
+
limit = EPISODE_TIMEOUT_S * max(1, e["resolved"]["scenario"].get("laps", 1)) # per lap: 5-lap episodes run 5x longer
|
| 84 |
+
try:
|
| 85 |
+
rc = subprocess.run(worker_cmd(i, work, stage, ep, a.sif, a.engine, a.stack, gpu), stdout=subprocess.DEVNULL,
|
| 86 |
+
stderr=subprocess.DEVNULL, timeout=limit).returncode
|
| 87 |
+
except subprocess.TimeoutExpired:
|
| 88 |
+
rc = "timeout"
|
| 89 |
+
solver = _solver(os.path.join(work, "tmp", "ros", "log"))
|
| 90 |
+
if solver and os.path.isdir(os.path.join(stage, key)):
|
| 91 |
+
with open(os.path.join(stage, key, "solver.txt"), "w") as f:
|
| 92 |
+
f.write(solver + "\n")
|
| 93 |
+
if os.path.exists(os.path.join(stage, key, "outcome.json")):
|
| 94 |
+
tmp, dst = os.path.join(a.out, ".tmp-" + key), os.path.join(a.out, key)
|
| 95 |
+
shutil.rmtree(tmp, ignore_errors=True)
|
| 96 |
+
shutil.copytree(os.path.join(stage, key), tmp)
|
| 97 |
+
shutil.rmtree(dst, ignore_errors=True)
|
| 98 |
+
os.rename(tmp, dst) # the host's rsync sees a key only once its directory is complete
|
| 99 |
+
with lock, open(a.done, "a") as f:
|
| 100 |
+
f.write(key + "\n")
|
| 101 |
+
shutil.rmtree(work, ignore_errors=True)
|
| 102 |
+
log(ev="end", key=key, worker=i, rc=rc, gpu=gpu,
|
| 103 |
+
solver=solver.split("MPC solver: ")[-1] if "MPC solver: " in solver else solver or None)
|
| 104 |
+
|
| 105 |
+
def sampler(stop):
|
| 106 |
+
"""Job CPU use from its cgroup, as busy cores, every SAMPLE_S."""
|
| 107 |
+
try:
|
| 108 |
+
with open("/proc/self/cgroup") as f:
|
| 109 |
+
path = "/sys/fs/cgroup" + f.read().strip().split(":")[-1] + "/cpu.stat"
|
| 110 |
+
prev = None
|
| 111 |
+
while not stop.wait(SAMPLE_S if prev else 0):
|
| 112 |
+
with open(path) as f:
|
| 113 |
+
use = next(int(ln.split()[1]) for ln in f if ln.startswith("usage_usec"))
|
| 114 |
+
now = time.time()
|
| 115 |
+
if prev:
|
| 116 |
+
log(ev="cpu", busy_cores=round((use - prev[0]) / 1e6 / (now - prev[1]), 2))
|
| 117 |
+
prev = (use, now)
|
| 118 |
+
except (OSError, StopIteration, ValueError):
|
| 119 |
+
pass
|
| 120 |
+
|
| 121 |
+
def gpu_sampler(stop):
|
| 122 |
+
"""GPU utilisation and memory of the job's GPUs, every SAMPLE_S."""
|
| 123 |
+
while not stop.wait(SAMPLE_S):
|
| 124 |
+
try:
|
| 125 |
+
p = subprocess.Popen(["nvidia-smi", "--query-gpu=utilization.gpu,memory.used", "--format=csv,noheader,nounits"],
|
| 126 |
+
stdout=subprocess.PIPE, stderr=subprocess.DEVNULL, text=True)
|
| 127 |
+
log(ev="gpu", **parse_smi(p.communicate(timeout=30)[0]))
|
| 128 |
+
except Exception: # no driver or a hung query: skip this sample
|
| 129 |
+
pass
|
| 130 |
+
|
| 131 |
+
cores = len(os.sched_getaffinity(0)) if hasattr(os, "sched_getaffinity") else os.cpu_count()
|
| 132 |
+
log(ev="launch", workers=a.workers, cores=cores)
|
| 133 |
+
stop = threading.Event()
|
| 134 |
+
threads = [threading.Thread(target=worker, args=(i,)) for i in range(a.workers)]
|
| 135 |
+
samplers = [sampler] + ([gpu_sampler] if a.gpus else [])
|
| 136 |
+
for t in threads + [threading.Thread(target=f, args=(stop,), daemon=True) for f in samplers]:
|
| 137 |
+
t.start()
|
| 138 |
+
for t in threads:
|
| 139 |
+
t.join()
|
| 140 |
+
stop.set()
|
| 141 |
+
log(ev="done")
|
| 142 |
+
|
| 143 |
+
|
| 144 |
+
if __name__ == "__main__":
|
| 145 |
+
main()
|
results/jobs/20261011-002644-large-ilqr-steer-learn/gautschi/3/sbatch.sh
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/bin/bash
|
| 2 |
+
#SBATCH -p highmem -A lilly-rob1 -N 1 -n 1 -c 192 --time 177 --dependency=afterany:16948096 -J AutoSim-large-large-ilqr-steer-learn-4 --comment 20261011-002644-large-ilqr-steer-learn -o AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/3/slurm-%j.out
|
| 3 |
+
W=/dev/shm/AutoSim-$SLURM_JOB_ID
|
| 4 |
+
trap 'rm -rf "$W"' EXIT
|
| 5 |
+
python3 $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/3/gautschi_launch.py --episodes $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/3/episodes.json --out /scratch/gautschi/manors/AutoSim/out/20261011-002644-large-ilqr-steer-learn --sif $HOME/AutoSim/images/AutoSim-99d206f40cb1.sif --engine $HOME/AutoSim/engine/b37fb519b32e564d2d8a8ea1259cbf2e695ba1a28d93504f20e4c2970a4f6f00 --stack $HOME/AutoSim/stacks/09f6048d97a12a43c7f0539e9db22b0251c622d6cafda2946841254a27f32824 --workers 96 --work $W --timeline $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/3/timeline.jsonl --done $HOME/AutoSim/jobs/20261011-002644-large-ilqr-steer-learn/3/done.txt
|
results/jobs/20261011-002644-large-ilqr-steer-learn/job.json
ADDED
|
@@ -0,0 +1,133 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"id": "20261011-002644-large-ilqr-steer-learn",
|
| 3 |
+
"tier": "large",
|
| 4 |
+
"tier_version": 3,
|
| 5 |
+
"recipe": {
|
| 6 |
+
"name": "large-ilqr-steer-learn",
|
| 7 |
+
"source": {
|
| 8 |
+
"repo": "AutonomousKart",
|
| 9 |
+
"ref": "worktree:ilqr-steer-learn"
|
| 10 |
+
},
|
| 11 |
+
"params": {
|
| 12 |
+
"pathfinder_node": {
|
| 13 |
+
"planner": "ilqr",
|
| 14 |
+
"mpc.num_samples": 16,
|
| 15 |
+
"mpc.use_steer_map": true,
|
| 16 |
+
"mpc.steer_map_cmd_deg": [
|
| 17 |
+
-60.0,
|
| 18 |
+
-30.0,
|
| 19 |
+
-18.0,
|
| 20 |
+
-15.0,
|
| 21 |
+
-12.0,
|
| 22 |
+
-9.0,
|
| 23 |
+
-6.0,
|
| 24 |
+
-3.0,
|
| 25 |
+
0.0,
|
| 26 |
+
3.0,
|
| 27 |
+
6.0,
|
| 28 |
+
9.0,
|
| 29 |
+
12.0,
|
| 30 |
+
15.0,
|
| 31 |
+
18.0,
|
| 32 |
+
30.0,
|
| 33 |
+
60.0
|
| 34 |
+
],
|
| 35 |
+
"mpc.adaptive_gain.map": true,
|
| 36 |
+
"mpc.adaptive_gain.understeer": false
|
| 37 |
+
}
|
| 38 |
+
},
|
| 39 |
+
"sim": {},
|
| 40 |
+
"notes": "large-ilqr-fast with a learned steer map: the rollout starts from each kart design's scalar gain (small-angle slope of the steer-map fit: 0.635, 0.357, 0.537) and RLS on IMU yaw rate learns the 17 knots, used as learned; no separate K_us (the starting gain is measured at driving speed, so K_us on top double counts understeer; the map absorbs it as in the predefined map)",
|
| 41 |
+
"params_by_kart": {
|
| 42 |
+
"kart1": {
|
| 43 |
+
"pathfinder_node": {
|
| 44 |
+
"mpc.steer_map_wheel_deg": [
|
| 45 |
+
-38.112,
|
| 46 |
+
-19.056,
|
| 47 |
+
-11.4336,
|
| 48 |
+
-9.528,
|
| 49 |
+
-7.6224,
|
| 50 |
+
-5.7168,
|
| 51 |
+
-3.8112,
|
| 52 |
+
-1.9056,
|
| 53 |
+
0.0,
|
| 54 |
+
1.9056,
|
| 55 |
+
3.8112,
|
| 56 |
+
5.7168,
|
| 57 |
+
7.6224,
|
| 58 |
+
9.528,
|
| 59 |
+
11.4336,
|
| 60 |
+
19.056,
|
| 61 |
+
38.112
|
| 62 |
+
]
|
| 63 |
+
}
|
| 64 |
+
},
|
| 65 |
+
"kart2": {
|
| 66 |
+
"pathfinder_node": {
|
| 67 |
+
"mpc.steer_map_wheel_deg": [
|
| 68 |
+
-21.408,
|
| 69 |
+
-10.704,
|
| 70 |
+
-6.4224,
|
| 71 |
+
-5.352,
|
| 72 |
+
-4.2816,
|
| 73 |
+
-3.2112,
|
| 74 |
+
-2.1408,
|
| 75 |
+
-1.0704,
|
| 76 |
+
0.0,
|
| 77 |
+
1.0704,
|
| 78 |
+
2.1408,
|
| 79 |
+
3.2112,
|
| 80 |
+
4.2816,
|
| 81 |
+
5.352,
|
| 82 |
+
6.4224,
|
| 83 |
+
10.704,
|
| 84 |
+
21.408
|
| 85 |
+
]
|
| 86 |
+
}
|
| 87 |
+
},
|
| 88 |
+
"kart3": {
|
| 89 |
+
"pathfinder_node": {
|
| 90 |
+
"mpc.steer_map_wheel_deg": [
|
| 91 |
+
-32.19,
|
| 92 |
+
-16.095,
|
| 93 |
+
-9.657,
|
| 94 |
+
-8.0475,
|
| 95 |
+
-6.438,
|
| 96 |
+
-4.8285,
|
| 97 |
+
-3.219,
|
| 98 |
+
-1.6095,
|
| 99 |
+
0.0,
|
| 100 |
+
1.6095,
|
| 101 |
+
3.219,
|
| 102 |
+
4.8285,
|
| 103 |
+
6.438,
|
| 104 |
+
8.0475,
|
| 105 |
+
9.657,
|
| 106 |
+
16.095,
|
| 107 |
+
32.19
|
| 108 |
+
]
|
| 109 |
+
}
|
| 110 |
+
}
|
| 111 |
+
}
|
| 112 |
+
},
|
| 113 |
+
"user": "shay",
|
| 114 |
+
"notes": "large v3: gradient MPC (tuned iLQR) with a learned steer map from each kart's scalar gain, no separate K_us",
|
| 115 |
+
"where": "gautschi",
|
| 116 |
+
"status": "done",
|
| 117 |
+
"submitted_at": "2026-10-11T07:26:44.062+00:00",
|
| 118 |
+
"started_at": "2026-10-11T07:26:44.062+00:00",
|
| 119 |
+
"finished_at": "2026-10-11T10:43:35.296+00:00",
|
| 120 |
+
"total": 32076,
|
| 121 |
+
"done": 32076,
|
| 122 |
+
"errors": 0,
|
| 123 |
+
"build_log": null,
|
| 124 |
+
"workers": 96,
|
| 125 |
+
"slurm_id": "16948095",
|
| 126 |
+
"slurm_ids": [
|
| 127 |
+
"16948095",
|
| 128 |
+
"16948096",
|
| 129 |
+
"16948097",
|
| 130 |
+
"16948098"
|
| 131 |
+
],
|
| 132 |
+
"engine_version": "b37fb519b32e564d2d8a8ea1259cbf2e695ba1a28d93504f20e4c2970a4f6f00"
|
| 133 |
+
}
|
results/jobs/20261011-002644-large-ilqr-steer-learn/summary.json
ADDED
|
@@ -0,0 +1,156 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"cte_p50": {
|
| 3 |
+
"value": 0.2552608991174732,
|
| 4 |
+
"worst_kart": null,
|
| 5 |
+
"per_kart": {
|
| 6 |
+
"kart1": 0.25633914555450693,
|
| 7 |
+
"kart2": 0.2637971133562128,
|
| 8 |
+
"kart3": 0.24591111109514402
|
| 9 |
+
}
|
| 10 |
+
},
|
| 11 |
+
"cte_p90": {
|
| 12 |
+
"value": 0.6531442435271917,
|
| 13 |
+
"worst_kart": null,
|
| 14 |
+
"per_kart": {
|
| 15 |
+
"kart1": 0.6177555232560475,
|
| 16 |
+
"kart2": 0.7046212720671666,
|
| 17 |
+
"kart3": 0.6430703814654682
|
| 18 |
+
}
|
| 19 |
+
},
|
| 20 |
+
"cte_p99": {
|
| 21 |
+
"value": 1.9560502261935768,
|
| 22 |
+
"worst_kart": null,
|
| 23 |
+
"per_kart": {
|
| 24 |
+
"kart1": 1.6952816371973014,
|
| 25 |
+
"kart2": 2.2640839730209477,
|
| 26 |
+
"kart3": 1.835355438009065
|
| 27 |
+
}
|
| 28 |
+
},
|
| 29 |
+
"recovery_rate": {
|
| 30 |
+
"value": 0.8544575725026853,
|
| 31 |
+
"worst_kart": null,
|
| 32 |
+
"per_kart": {
|
| 33 |
+
"kart1": 0.8576794657762938,
|
| 34 |
+
"kart2": 0.8528756130182791,
|
| 35 |
+
"kart3": 0.8525514089870525
|
| 36 |
+
}
|
| 37 |
+
},
|
| 38 |
+
"recovery_s_median": {
|
| 39 |
+
"value": 1.8330000000000002,
|
| 40 |
+
"worst_kart": null,
|
| 41 |
+
"per_kart": {
|
| 42 |
+
"kart1": 1.700000000000001,
|
| 43 |
+
"kart2": 2.0,
|
| 44 |
+
"kart3": 1.7829999999999995
|
| 45 |
+
}
|
| 46 |
+
},
|
| 47 |
+
"safety": {
|
| 48 |
+
"value": 0.7865614544147589,
|
| 49 |
+
"worst_kart": null,
|
| 50 |
+
"per_kart": {
|
| 51 |
+
"kart1": 0.8033688004913537,
|
| 52 |
+
"kart2": 0.7643699467653093,
|
| 53 |
+
"kart3": 0.7910023696197255
|
| 54 |
+
}
|
| 55 |
+
},
|
| 56 |
+
"unsafe_lat": {
|
| 57 |
+
"value": 0.0008100744378086672,
|
| 58 |
+
"worst_kart": null,
|
| 59 |
+
"per_kart": {
|
| 60 |
+
"kart1": 0.0009748219416854327,
|
| 61 |
+
"kart2": 0.00016791706477997157,
|
| 62 |
+
"kart3": 0.0012876468298441749
|
| 63 |
+
}
|
| 64 |
+
},
|
| 65 |
+
"unsafe_rate": {
|
| 66 |
+
"value": 0.10755605785217116,
|
| 67 |
+
"worst_kart": null,
|
| 68 |
+
"per_kart": {
|
| 69 |
+
"kart1": 0.08795546667239557,
|
| 70 |
+
"kart2": 0.12872840156041418,
|
| 71 |
+
"kart3": 0.10718860624766931
|
| 72 |
+
}
|
| 73 |
+
},
|
| 74 |
+
"unsafe_travel": {
|
| 75 |
+
"value": 0.0,
|
| 76 |
+
"worst_kart": null,
|
| 77 |
+
"per_kart": {
|
| 78 |
+
"kart1": 0.0,
|
| 79 |
+
"kart2": 0.0,
|
| 80 |
+
"kart3": 0.0
|
| 81 |
+
}
|
| 82 |
+
},
|
| 83 |
+
"unsafe_spin": {
|
| 84 |
+
"value": 4.33257619551897e-05,
|
| 85 |
+
"worst_kart": null,
|
| 86 |
+
"per_kart": {
|
| 87 |
+
"kart1": 6.40591177002288e-05,
|
| 88 |
+
"kart2": 9.23310106895697e-06,
|
| 89 |
+
"kart3": 5.5670323256263886e-05
|
| 90 |
+
}
|
| 91 |
+
},
|
| 92 |
+
"unsafe_off": {
|
| 93 |
+
"value": 0.12161829590158763,
|
| 94 |
+
"worst_kart": null,
|
| 95 |
+
"per_kart": {
|
| 96 |
+
"kart1": 0.12119628851357575,
|
| 97 |
+
"kart2": 0.12605832473090897,
|
| 98 |
+
"kart3": 0.11753792858437581
|
| 99 |
+
}
|
| 100 |
+
},
|
| 101 |
+
"osc_10": {
|
| 102 |
+
"value": 30.974468731870164,
|
| 103 |
+
"worst_kart": null,
|
| 104 |
+
"per_kart": {
|
| 105 |
+
"kart1": 31.635404949154676,
|
| 106 |
+
"kart2": 28.866101006293306,
|
| 107 |
+
"kart3": 32.41218645676043
|
| 108 |
+
}
|
| 109 |
+
},
|
| 110 |
+
"osc_20": {
|
| 111 |
+
"value": 14.129465059035974,
|
| 112 |
+
"worst_kart": null,
|
| 113 |
+
"per_kart": {
|
| 114 |
+
"kart1": 14.408636060336132,
|
| 115 |
+
"kart2": 11.939973476954647,
|
| 116 |
+
"kart3": 16.06446251200385
|
| 117 |
+
}
|
| 118 |
+
},
|
| 119 |
+
"osc_30": {
|
| 120 |
+
"value": 6.509328309410818,
|
| 121 |
+
"worst_kart": null,
|
| 122 |
+
"per_kart": {
|
| 123 |
+
"kart1": 6.6665432118483485,
|
| 124 |
+
"kart2": 4.905023900496261,
|
| 125 |
+
"kart3": 7.978541095562408
|
| 126 |
+
}
|
| 127 |
+
},
|
| 128 |
+
"laps_pct": {
|
| 129 |
+
"value": 50.26063100137174,
|
| 130 |
+
"worst_kart": null,
|
| 131 |
+
"per_kart": {
|
| 132 |
+
"kart1": 50.946502057613166,
|
| 133 |
+
"kart2": 50.864197530864196,
|
| 134 |
+
"kart3": 48.97119341563786
|
| 135 |
+
}
|
| 136 |
+
},
|
| 137 |
+
"failures": {
|
| 138 |
+
"value": 4304,
|
| 139 |
+
"worst_kart": null,
|
| 140 |
+
"per_kart": {
|
| 141 |
+
"kart1": 1471,
|
| 142 |
+
"kart2": 1506,
|
| 143 |
+
"kart3": 1327
|
| 144 |
+
}
|
| 145 |
+
},
|
| 146 |
+
"n": {
|
| 147 |
+
"value": 32076,
|
| 148 |
+
"worst_kart": null,
|
| 149 |
+
"per_kart": {}
|
| 150 |
+
},
|
| 151 |
+
"errors": {
|
| 152 |
+
"value": 0,
|
| 153 |
+
"worst_kart": null,
|
| 154 |
+
"per_kart": {}
|
| 155 |
+
}
|
| 156 |
+
}
|
results/leaderboard/large-3__b37fb519b32e.json
ADDED
|
@@ -0,0 +1,48 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
[
|
| 2 |
+
{
|
| 3 |
+
"job_id": "20261011-002644-large-ilqr-steer-learn",
|
| 4 |
+
"recipe": "large-ilqr-steer-learn",
|
| 5 |
+
"notes": "large v3: gradient MPC (tuned iLQR) with a learned steer map from each kart's scalar gain, no separate K_us",
|
| 6 |
+
"user": "shay",
|
| 7 |
+
"ran_at": "2026-10-11T10:43:35.296+00:00",
|
| 8 |
+
"duration_s": 11811.234,
|
| 9 |
+
"cte_p50": 0.2552608991174732,
|
| 10 |
+
"cte_p90": 0.6531442435271917,
|
| 11 |
+
"cte_p99": 1.9560502261935768,
|
| 12 |
+
"recovery_rate": 0.8544575725026853,
|
| 13 |
+
"recovery_s_median": 1.8330000000000002,
|
| 14 |
+
"safety": 0.7865614544147589,
|
| 15 |
+
"unsafe_lat": 0.0008100744378086672,
|
| 16 |
+
"unsafe_rate": 0.10755605785217116,
|
| 17 |
+
"unsafe_travel": 0.0,
|
| 18 |
+
"unsafe_spin": 4.33257619551897e-05,
|
| 19 |
+
"unsafe_off": 0.12161829590158763,
|
| 20 |
+
"osc_10": 30.974468731870164,
|
| 21 |
+
"osc_20": 14.129465059035974,
|
| 22 |
+
"osc_30": 6.509328309410818,
|
| 23 |
+
"laps_pct": 50.26063100137174,
|
| 24 |
+
"failures": 4304,
|
| 25 |
+
"n": 32076,
|
| 26 |
+
"errors": 0,
|
| 27 |
+
"worst": {
|
| 28 |
+
"cte_p50": 0.2637971133562128,
|
| 29 |
+
"cte_p90": 0.7046212720671666,
|
| 30 |
+
"cte_p99": 2.2640839730209477,
|
| 31 |
+
"recovery_rate": 0.8525514089870525,
|
| 32 |
+
"recovery_s_median": 2.0,
|
| 33 |
+
"safety": 0.7643699467653093,
|
| 34 |
+
"unsafe_lat": 0.0012876468298441749,
|
| 35 |
+
"unsafe_rate": 0.12872840156041418,
|
| 36 |
+
"unsafe_travel": 0.0,
|
| 37 |
+
"unsafe_spin": 6.40591177002288e-05,
|
| 38 |
+
"unsafe_off": 0.12605832473090897,
|
| 39 |
+
"osc_10": 32.41218645676043,
|
| 40 |
+
"osc_20": 16.06446251200385,
|
| 41 |
+
"osc_30": 7.978541095562408,
|
| 42 |
+
"laps_pct": 48.97119341563786,
|
| 43 |
+
"failures": 1506,
|
| 44 |
+
"n": 32076,
|
| 45 |
+
"errors": 0
|
| 46 |
+
}
|
| 47 |
+
}
|
| 48 |
+
]
|