Spaces:
Running
Running
Download index.html from maxmccutcheon59/robolint: direct link, hf CLI and curl.
- Browser
- Download file 12.6 kB
-
https://huggingface.co/spaces/maxmccutcheon59/robolint/resolve/main/index.html
- Command line
-
hf download hf://spaces/maxmccutcheon59/robolint/index.html
-
curl -L -o index.html https://huggingface.co/spaces/maxmccutcheon59/robolint/resolve/main/index.html
12.6 kB
| <html lang="en"> | |
| <head> | |
| <meta charset="utf-8"> | |
| <meta name="viewport" content="width=device-width,initial-scale=1"> | |
| <title>robolint: robot dataset quality checker</title> | |
| <style> | |
| :root{--bg:#fafaf9;--card:#fff;--fg:#1c1917;--muted:#6b6862;--line:#e7e5e4;--accent:#2a78d6;--err:#b91c1c;--warn:#b45309;--info:#0e7490;--ok:#15803d;--code:#f2f1ee} | |
| @media (prefers-color-scheme:dark){:root{--bg:#0c0a09;--card:#1c1917;--fg:#f5f5f4;--muted:#a8a29e;--line:#2c2a28;--accent:#3987e5;--err:#f87171;--warn:#fbbf24;--info:#67e8f9;--ok:#4ade80;--code:#292524}} | |
| *{box-sizing:border-box} | |
| body{margin:0;background:var(--bg);color:var(--fg);font:15px/1.55 system-ui,-apple-system,"Segoe UI",sans-serif} | |
| main{max-width:980px;margin:0 auto;padding:28px 16px 48px} | |
| h1{font-size:26px;margin:0 0 4px}h2{font-size:18px;margin:32px 0 10px}h3{font-size:16px;margin:24px 0 8px} | |
| a{color:var(--accent)} | |
| .muted{color:var(--muted)} | |
| .card{background:var(--card);border:1px solid var(--line);border-radius:12px;padding:16px} | |
| .row{display:flex;gap:10px;flex-wrap:wrap;align-items:center} | |
| select,input[type=text]{font:inherit;color:var(--fg);background:var(--card);border:1px solid var(--line);border-radius:8px;padding:9px 10px;min-width:0;flex:1 1 260px} | |
| button{font:inherit;font-weight:600;color:#fff;background:var(--accent);border:0;border-radius:8px;padding:9px 16px;cursor:pointer} | |
| button:disabled{opacity:.6;cursor:default} | |
| label.chk{display:flex;gap:6px;align-items:center;color:var(--muted)} | |
| .stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(140px,1fr));gap:10px;margin:14px 0} | |
| .stat .big{font-size:26px;font-weight:650} | |
| table{width:100%;border-collapse:collapse;font-size:14px} | |
| th,td{text-align:left;padding:7px 8px;border-bottom:1px solid var(--line);vertical-align:top} | |
| th{font-size:12px;text-transform:uppercase;letter-spacing:.04em;color:var(--muted)} | |
| code{background:var(--code);border-radius:4px;padding:1px 5px;font-size:13px} | |
| .error{color:var(--err)}.warning{color:var(--warn)}.info{color:var(--info)}.ok{color:var(--ok)} | |
| .wrap{overflow-x:auto} | |
| .badge{display:inline-block;font-size:12px;font-weight:600;border:1px solid var(--line);border-radius:999px;padding:1px 8px;color:var(--muted)} | |
| #progress{margin-top:10px;min-height:1.5em} | |
| @media (max-width:640px){table.stack,table.stack tbody,table.stack tr,table.stack td{display:block;width:100%}table.stack tr:first-child{display:none}table.stack tr{padding:6px 0;border-bottom:1px solid var(--line)}table.stack td{border:0;padding:2px 4px}} | |
| </style> | |
| </head> | |
| <body> | |
| <main> | |
| <h1>robolint</h1> | |
| <p class="muted">Quality checks for robot learning datasets in <a href="https://github.com/huggingface/lerobot">LeRobot</a> format: dropped frames, dead episodes, teleop glitches, failed grasps, merged recordings, broken metadata. | |
| <a href="https://github.com/maxmccutcheon59/robolint">GitHub</a> · <a href="https://github.com/maxmccutcheon59/robolint/blob/main/AUDIT.md">Audit write-up</a></p> | |
| <p class="muted">About the failed-grasp checks (<code>FAILED_GRASP</code>, <code>REGRASP</code>): we haven't yet measured how many real failed demonstrations they miss, and they only check grippers named "gripper" (a dimension whose name contains "gripper" in both <code>action</code> and <code>observation.state</code>).</p> | |
| <div class="card" style="margin-top:18px"> | |
| <strong>Training on your own robot data?</strong> | |
| <span class="muted">Send me a dataset (public or private) and I'll check it with robolint and walk you through what's broken: free for early teams.</span> | |
| <div style="margin-top:8px"><a href="mailto:MaxMcCutcheon1@outlook.com?subject=robolint%20audit%20request">Request an audit</a> · Max McCutcheon</div> | |
| </div> | |
| <h2>Audit results: 18 public datasets</h2> | |
| <p class="muted">Results of the November 2026 audit, run with the robolint command-line tool. Pick a dataset to see what was found.</p> | |
| <div class="card"> | |
| <div class="row"> | |
| <select id="pick" aria-label="Dataset"></select> | |
| </div> | |
| <div id="audit"></div> | |
| </div> | |
| <h2>Check another dataset <span class="badge">experimental</span></h2> | |
| <p class="muted">Runs robolint entirely in your browser with <a href="https://pyodide.org">Pyodide</a>: nothing is uploaded anywhere. The first run downloads the Python runtime (tens of MB). Camera checks are not available here. Large datasets can be slow; use quick mode or the <a href="https://github.com/maxmccutcheon59/robolint#usage">command-line tool</a>.</p> | |
| <div class="card"> | |
| <div class="row"> | |
| <input id="repo" type="text" placeholder="lerobot/svla_so100_sorting or owner/name/subfolder" aria-label="Dataset id" autocomplete="off" spellcheck="false"> | |
| <label class="chk"><input id="quick" type="checkbox" checked> Quick mode (first 300 episodes)</label> | |
| <button id="go">Check dataset</button> | |
| </div> | |
| <div id="progress" class="muted" role="status"></div> | |
| <div id="live"></div> | |
| </div> | |
| </main> | |
| <script type="module"> | |
| const PYODIDE = "https://cdn.jsdelivr.net/pyodide/v314.0.7/full/"; | |
| const QUICK_EPISODES = 300; | |
| let HELP = {}; | |
| function el(tag, attrs = {}, ...kids) { | |
| const n = document.createElement(tag); | |
| for (const [k, v] of Object.entries(attrs)) { | |
| if (k === "class") n.className = v; else n.setAttribute(k, v); | |
| } | |
| for (const k of kids) n.append(k instanceof Node ? k : document.createTextNode(String(k))); | |
| return n; | |
| } | |
| const plural = (n, w) => `${n} ${w}${n === 1 ? "" : "s"}`; | |
| const pct = (n, t) => (t ? Math.round((100 * n) / t) : 0) + "%"; | |
| function render(target, r) { | |
| target.replaceChildren(); | |
| const ds = r.dataset, eps = r.episodes, n = ds.episodes; | |
| const gradeCls = r.score >= 80 ? "ok" : r.score >= 60 ? "warning" : "error"; | |
| target.append( | |
| el("h3", {}, r.source), | |
| el("div", { class: "muted" }, | |
| `LeRobot ${ds.codebase_version} · robot ${ds.robot_type || "unknown"} · ${ds.fps ?? "?"} fps · ${ds.frames.toLocaleString()} frames`), | |
| el("div", { class: "stats" }, | |
| el("div", { class: "card stat" }, el("div", { class: "muted" }, "Score"), | |
| el("div", { class: "big " + gradeCls }, r.score.toFixed(1)), el("div", {}, "grade " + r.grade)), | |
| el("div", { class: "card stat" }, el("div", { class: "muted" }, "Episodes"), | |
| el("div", { class: "big" }, n.toLocaleString())), | |
| el("div", { class: "card stat" }, el("div", { class: "muted" }, "Clean"), | |
| el("div", { class: "big ok" }, pct(eps.clean, n)), el("div", {}, plural(eps.clean, "episode"))), | |
| el("div", { class: "card stat" }, el("div", { class: "muted" }, "With errors"), | |
| el("div", { class: "big error" }, pct(eps.with_errors, n)), el("div", {}, plural(eps.with_errors, "episode"))), | |
| ), | |
| ); | |
| const partial = r.findings.find(f => f.code === "PARTIAL_CHECK"); | |
| if (partial) target.append(el("p", { class: "muted" }, partial.message)); | |
| if (!r.issues.length) { target.append(el("p", { class: "ok" }, "No issues found.")); return; } | |
| const t = el("table", { class: "stack" }, | |
| el("tr", {}, el("th", {}, "Severity"), el("th", {}, "Issue"), el("th", {}, "Affected"), el("th", {}, "What it means"))); | |
| for (const i of r.issues) { | |
| const dsLevel = r.findings.filter(f => f.code === i.code).every(f => f.episode === null); | |
| t.append(el("tr", {}, | |
| el("td", { class: i.severity }, i.severity), el("td", {}, el("code", {}, i.code)), | |
| el("td", {}, dsLevel ? "dataset" : plural(i.affected, "episode")), el("td", {}, HELP[i.code] || ""))); | |
| } | |
| target.append(el("div", { class: "wrap" }, t)); | |
| const dsFindings = r.findings.filter(f => f.episode === null && f.code !== "PARTIAL_CHECK"); | |
| if (dsFindings.length) { | |
| target.append(el("h3", {}, "Dataset findings")); | |
| const ul = el("ul"); | |
| for (const f of dsFindings) ul.append(el("li", {}, el("span", { class: f.severity }, f.severity + ": "), f.message)); | |
| target.append(ul); | |
| } | |
| const byEp = new Map(); | |
| for (const f of r.findings) if (f.episode !== null) (byEp.get(f.episode) || byEp.set(f.episode, []).get(f.episode)).push(f); | |
| if (byEp.size) { | |
| const rank = { error: 3, warning: 2, info: 1 }; | |
| const rows = [...byEp.entries()].sort((a, b) => | |
| Math.max(...b[1].map(f => rank[f.severity])) - Math.max(...a[1].map(f => rank[f.severity])) || a[0] - b[0]); | |
| target.append(el("h3", {}, "Flagged episodes")); | |
| const et = el("table", { class: "stack" }, el("tr", {}, el("th", {}, "Episode"), el("th", {}, "Findings"))); | |
| for (const [ep, fs] of rows.slice(0, 300)) { | |
| const cell = el("td"); | |
| fs.sort((a, b) => rank[b.severity] - rank[a.severity]).forEach((f, k) => { | |
| if (k) cell.append(el("br")); | |
| cell.append(el("span", { class: f.severity }, f.severity + " "), f.message); | |
| }); | |
| et.append(el("tr", {}, el("td", {}, String(ep)), cell)); | |
| } | |
| target.append(el("div", { class: "wrap" }, et)); | |
| if (rows.length > 300) target.append(el("p", { class: "muted" }, `${rows.length - 300} more flagged episodes not shown.`)); | |
| } | |
| } | |
| // ---- Precomputed audit results | |
| const data = await (await fetch("results.json")).json(); | |
| HELP = data.help; | |
| const pick = document.getElementById("pick"); | |
| for (const r of data.results) pick.append(el("option", { value: r.source }, `${r.source} (${r.score.toFixed(1)}, ${r.grade})`)); | |
| const show = () => render(document.getElementById("audit"), data.results.find(r => r.source === pick.value)); | |
| pick.addEventListener("change", show); | |
| const want = new URLSearchParams(location.search).get("dataset"); | |
| const DEFAULT = "lerobot/svla_so100_stacking"; | |
| if (want && data.results.some(r => r.source === want)) pick.value = want; | |
| else if (data.results.some(r => r.source === DEFAULT)) pick.value = DEFAULT; | |
| show(); | |
| // ---- Live check in the browser (experimental) | |
| const repo = document.getElementById("repo"), go = document.getElementById("go"); | |
| const progress = document.getElementById("progress"), live = document.getElementById("live"); | |
| let pyodidePromise = null; | |
| async function getPyodide() { | |
| if (!pyodidePromise) pyodidePromise = (async () => { | |
| progress.textContent = "Loading Python runtime…"; | |
| const { loadPyodide } = await import(PYODIDE + "pyodide.mjs"); | |
| const py = await loadPyodide({ indexURL: PYODIDE }); | |
| progress.textContent = "Loading numpy and pyarrow…"; | |
| await py.loadPackage(["numpy", "pyarrow"]); | |
| const files = await (await fetch("robolint_files.json")).json(); | |
| for (const f of [...files, "live.py"]) { | |
| const src = await (await fetch(f)).text(); | |
| const dest = "/home/pyodide/" + f; | |
| py.FS.mkdirTree(dest.slice(0, dest.lastIndexOf("/"))); | |
| py.FS.writeFile(dest, src); | |
| } | |
| return py; | |
| })().catch(e => { pyodidePromise = null; throw e; }); | |
| return pyodidePromise; | |
| } | |
| async function runLive() { | |
| const id = repo.value.trim(); | |
| if (!/^[A-Za-z0-9][\w.-]*\/[\w.-]+(\/[\w.-]+)*$/.test(id)) { progress.textContent = "Enter a dataset id like lerobot/pusht (add /folder for datasets kept in subfolders)."; return; } | |
| go.disabled = true; live.replaceChildren(); | |
| try { | |
| const py = await getPyodide(); | |
| const mod = py.pyimport("live"); | |
| const out = await mod.run(id, document.getElementById("quick").checked, QUICK_EPISODES, | |
| msg => { progress.textContent = msg; }); | |
| const parsed = JSON.parse(out); | |
| HELP = parsed.help; | |
| render(live, parsed.result); | |
| if (parsed.audit_html) { | |
| const url = URL.createObjectURL(new Blob([parsed.audit_html], { type: "text/html" })); | |
| const bar = document.createElement("div"); | |
| bar.className = "card"; bar.style.marginTop = "12px"; | |
| const a = document.createElement("a"); | |
| a.href = url; a.target = "_blank"; a.rel = "noopener"; | |
| a.download = id.replaceAll("/", "_") + "-audit.html"; | |
| a.textContent = "Download the one-page audit report"; | |
| const note = document.createElement("span"); | |
| note.className = "muted"; | |
| note.textContent = " · a summary for your team: grade, what to remove, what to fix. Want this for your private data? "; | |
| const mail = document.createElement("a"); | |
| mail.href = "mailto:MaxMcCutcheon1@outlook.com?subject=" + encodeURIComponent("robolint audit request: " + id); | |
| mail.textContent = "Request an audit"; | |
| bar.append(a, note, mail); | |
| live.prepend(bar); | |
| } | |
| progress.textContent = "Done."; | |
| } catch (e) { | |
| progress.textContent = "Could not check this dataset: " + (e && e.message ? e.message.split("\n").filter(Boolean).pop() : e); | |
| } finally { | |
| go.disabled = false; | |
| } | |
| } | |
| go.addEventListener("click", runLive); | |
| repo.addEventListener("keydown", e => { if (e.key === "Enter") runLive(); }); | |
| </script> | |
| </body> | |
| </html> | |