Spaces:
Running
Running
Commit ·
5ea5503
1
Parent(s): 1279719
Collapse customization field and reorganize
Browse filesFiles changed (5)
- AGENTS.md+11-12
- assets/app.js+32-46
- assets/style.css+20-2
- index.html+50-45
- smoke_test.py-4
5 unmodified lines67891091011121314151617171818192021202122232425263 unmodified lines3031323132333435363637383738394042414243445 unmodified lines
## Files
- `index.html`: the whole page: header, the four tab panels (Summary, which opens first: Elo figure and leaderboard tables; Trade-offs: Pareto front and complete results; Stability; Validity),- `index.html`: the whole page: header, the four tab panels (Leaderboard, which opens first: the Elo figure above the table; Performance Trade-offs: Pareto front and complete results; Stability; Validity), all user-facing text (each explanation sits next to the figure or table it describes; there is no About tab; the Paper and GitHub links sit in the intro sentence), the citation (always visible in the footer) and `<meta name="selectarena-version">` (not displayed; there is no version history, the commit messages are the changelog).- `assets/app.js`: plain JavaScript, no build step. Fetches `data/meta.json`, renders the selector chips (task type, downstream model, budget; combinations that are not published are disabled; shared by the Summary and Trade-offs tabs; the Summary's view: Elo figure, table or table per downstream model; task type, view and noise level of the lasagna plots), sets the iframes' `src` and the figures' shared by the Leaderboard and Performance Trade-offs tabs; task type, view and noise level of the lasagna plots; each tab's chips sit in a collapsed `<details class="config">` whose "Customize" button shows the current choices), sets the iframes' `src` and the figures' `<img src>` to the generated files and resizes the iframes when a page posts `{saFrameHeight}`. Keeps the tab and the selections in the URL hash (old tab names `leaderboard`, `robustness`, `datasets`, `data` and `about` still work). Keeps the tab and the selections in the URL hash (tab keys `leaderboard`, `tradeoffs`, `stability`, `validity`; old names such as `summary`, `performance`, `data` and `about` still work).- `assets/style.css`: color tokens on `:root` (light) and in `prefers-color-scheme: dark`.- `smoke_test.py`: standard-library check of `data/` and of the version tag (see below).
3 unmodified lines
- `meta.json`: counts, `models` (key -> name), `budgets`, `total_budget`, `task_types`, `has_stability`, `has_validity`, `validity_noise`, `validity_tables`, `generated_at`, `subsets` (each with `tasks`, `model`, `budget`, `path`, `n_methods`, `n_datasets`, `n_comparisons`, `pareto`, and on the all-models subsets `per_model`), `tasks`, `model`, `budget`, `path`, `n_methods`, `n_datasets`, `n_comparisons`, `pareto`), `lasagna` (`variants`, `variant_labels`, and when present `stability` = `{path, task_types}` and `validity` = a list of `{noise, path, task_types}`) and `has_results_explorer`.- `subsets/tasks_<t>/models_<m>/budgets_<b>/`: `website_leaderboard.csv`, `leaderboard_table.html`, `elo_explorer.html`, and `pareto.svg` / `pareto.csv` when the subset's `pareto` is true; in the `models_all` folders also `per_model_table.html` / `per_model.csv` (Elo per downstream model) when `per_model` is true. `elo_explorer.html`, and `pareto.svg` / `pareto.csv` when the subset's `pareto` is true.- `lasagna/stability/tasks_<t>/` and `lasagna/validity/noise_<level>/tasks_<t>/`: one `<variant>.svg` per entry of `lasagna.variants` and `per_epv.csv` (the plotted values).- `results.csv` and `results_explorer.html`: the results per dataset, method, downstream model and budget (Trade-offs tab, below the Pareto front; not filtered by the chips). budget (Performance Trade-offs tab, below the Pareto front; not filtered by the chips).- `per_dataset.csv` (mean rank per dataset; data only, not shown), and optionally `stability.csv`, `stability_table.html`, `validity.csv` and one `validity_noise_<level>_table.html` per noise level (listed in `meta.json` as `validity_tables`).1 unmodified line23456567813 unmodified lines222324262526272928293032333435363731393233343582 unmodified lines11811912012112212312412512612712812913013113213313413513613713813938 unmodified lines17817918017218118218318414 unmodified lines1992002011931942022032042052062072082092012102112122131 unmodified line2152162172092182192202217 unmodified lines2292302312232242252262272282292302312322332342352362322332342382392402412422432352362372382392472482492502512522532542552562402412422432442452461 unmodified line//// data/meta.json lists every published subset; each subset folder// data/subsets/tasks_<t>/models_<m>/budgets_<b>/ holds elo_explorer.html and leaderboard_table.html,// which are embedded as iframes, and pareto.svg / pareto.csv; the models_all folders also hold// per_model_table.html when meta says "per_model" (Leaderboard tab, per downstream model view). The folder names mirror// which are embedded as iframes, and pareto.svg / pareto.csv. The folder names mirror// selectarena.website.subsets.Subset.rel_path. The lasagna plots are in data/lasagna/ (meta.lasagna):// stability/tasks_<t>/<variant>.svg and validity/noise_<level>/tasks_<t>/<variant>.svg.// Every embedded page posts {saFrameHeight: <px>} to this window; the listener below resizes its iframe.13 unmodified lines overlay_top_3: 'Top-3 outlined', binary_thr_003: 'Within 0.03 of the best' }; var TABS = ['summary', 'tradeoffs', 'stability', 'validity']; var TABS = ['leaderboard', 'tradeoffs', 'stability', 'validity']; // Old tab names (links to earlier versions of the site). var TAB_ALIASES = { leaderboard: 'summary', about: 'summary', performance: 'tradeoffs', data: 'tradeoffs', datasets: 'tradeoffs', summary: 'leaderboard', about: 'leaderboard', performance: 'tradeoffs', data: 'tradeoffs', datasets: 'tradeoffs', robustness: 'stability' }; // Views of the Summary tab: the Elo figure, the leaderboard table, the Elo per downstream model. var VIEWS = [ { value: 'figure', label: 'Elo figure' }, { value: 'overall', label: 'Table' }, { value: 'models', label: 'Table per model' } ]; var DEFAULTS = { tab: 'summary', tasks: ALL, model: ALL, budget: ALL, view: 'figure', tab: 'leaderboard', tasks: ALL, model: ALL, budget: ALL, stasks: ALL, svariant: 'plain', vtasks: ALL, vvariant: 'plain', noise: '' }; var state = Object.assign({}, DEFAULTS);82 unmodified lines button.addEventListener('click', function () { onPick(option.value); writeHash(); }); container.appendChild(button); }); updateConfigState(container); }
// The controls of each tab sit in a collapsed <details> ("Customize"); its button shows the // current choice of every control, e.g. "Tasks: All · Model: All · Budget: All". function updateConfigState(container) { var details = container.closest('details.config'); if (!details) return; var parts = []; details.querySelectorAll('.control').forEach(function (control) { if (control.hidden) return; var label = control.querySelector('.control-label'); var chip = control.querySelector('.chip[aria-pressed="true"]'); if (label && chip) parts.push(label.textContent + ': ' + chip.textContent); }); details.querySelector('.config-state').textContent = parts.join(' · '); }
// ---- tabs ----38 unmodified lines }
// The task type, model and budget chips of the Performance and Leaderboard tabs share the // selection; `prefix` is '' (Performance) or 'lb-' (Leaderboard). // selection; `prefix` is '' (Performance Trade-offs) or 'lb-' (Leaderboard). function renderSelectionChips(prefix) { var options = axisOptions(); ['tasks', 'model', 'budget'].forEach(function (axis) {14 unmodified lines ].join(' · '); } // One short line under the chips (which already show the selection). function writeSummary(element, s, info, perModel) { element.title = perModel ? scopeText(s).replace('all downstream models', 'per downstream model') : scopeText(s); function writeSummary(element, s, info) { element.title = scopeText(s); element.textContent = info ? info.n_methods + ' methods · ' + info.n_datasets + ' datasets · ' + info.n_comparisons.toLocaleString('en-US') + ' results compared' : ''; } function renderSelection() { renderSummary(); renderLeaderboard(); renderTradeoffs(); }
1 unmodified line function renderTradeoffs() { renderSelectionChips(''); var info = published[key(state)]; writeSummary($('summary'), state, info, false); writeSummary($('summary'), state, info); $('subset-missing').hidden = !!info; $('subset-content').hidden = !info; if (!info) return;7 unmodified lines } }
// ---- summary (Elo figure, leaderboard table or Elo per downstream model) ---- function renderSummary() { var allModels = { tasks: state.tasks, model: ALL, budget: state.budget }; var perModelInfo = published[key(allModels)]; var hasPerModel = !!(perModelInfo && perModelInfo.per_model); if (state.view === 'models' && !hasPerModel) state.view = 'overall'; var perModel = state.view === 'models'; renderChips('lb-chips-view', VIEWS.map(function (v) { return { value: v.value, label: v.label, disabled: v.value === 'models' && !hasPerModel, disabledTitle: 'Needs results of at least two downstream models' }; }), state.view, function (value) { state.view = value; renderSummary(); }); // ---- leaderboard (Elo figure above the table) ---- function renderLeaderboard() { renderSelectionChips('lb-'); // The per-model view has a column per model, so the model chips do not apply. $('lb-control-model').hidden = perModel;
var shown = perModel ? allModels : state; var info = published[key(shown)]; writeSummary($('lb-summary'), shown, info, perModel); var info = published[key(state)]; writeSummary($('lb-summary'), state, info); $('lb-missing').hidden = !!info; $('lb-content').hidden = !info; if (!info) return; var figure = state.view === 'figure'; $('lb-figure').hidden = !figure; $('lb-table').hidden = figure; if (figure) { setFrame($('frame-figure'), subsetDir(shown) + 'elo_explorer.html'); return; } $('lb-caption-overall').hidden = perModel; $('lb-caption-models').hidden = !perModel; var src = subsetDir(shown) + (perModel ? 'per_model_table.html' : 'leaderboard_table.html'); var dir = subsetDir(state); setFrame($('frame-figure'), dir + 'elo_explorer.html'); var table = $('frame-table'); var src = dir + 'leaderboard_table.html'; if (table.getAttribute('src') !== src) table.style.height = (info.n_methods * 37 + 90) + 'px'; setFrame(table, src); }136 unmodified lines137138139140140141142142143144145146147148149150151152153154155156157158159160161162163164136 unmodified lines
/* Keep the figures on screen without scrolling: on short screens they shrink with the window height (the Elo figure is about 2.6 times as wide as high, plus its toolbar). */#frame-figure { max-width: max(560px, calc((100vh - 420px) * 2.6)); }#frame-figure { max-width: max(560px, calc((100vh - 330px) * 2.6)); }@media (min-width: 641px) and (max-height: 860px) { .plot img { max-height: max(280px, calc(100vh - 340px)); width: auto; } .plot img { max-height: max(280px, calc(100vh - 290px)); width: auto; }}
/* Heading at the top of a tab (Elo, Stability, Validity). */.tab-title { margin: 4px 0 2px; }
/* Collapsed controls: a small "Customize" button showing the current selection; the panel with the chips opens below it. */.config { margin-bottom: 6px; }.config-button { display: inline-flex; align-items: baseline; gap: 8px; max-width: 100%; list-style: none; cursor: pointer; user-select: none; padding: 3px 12px; border: 1px solid var(--line); border-radius: 999px; background: var(--surface); font-size: 0.8rem; color: var(--fg);}.config-button::-webkit-details-marker { display: none; }.config-button::before { content: "\25B8"; color: var(--muted); }.config[open] > .config-button::before { content: "\25BE"; }.config-button:hover { border-color: var(--accent); }.config-button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }.config-title { font-weight: 600; }.config-state { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }.config[open] > .controls { margin-top: 6px; }3 unmodified lines45677891016 unmodified lines272829303130313233343536373637383940414243444546474849505152434445464748495051525354555617 unmodified lines74757676777878798081822 unmodified lines85868787888990917 unmodified lines991001011011021031041051021031048 unmodified lines11311411511611712012112212312412512612711811912012112212312412512612712812928 unmodified lines15815916016116216216316416516616716316416516616716816917017117219 unmodified lines1921931941951961931941951961971981992001971981992002012022032042052062072083 unmodified lines <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <!-- Bumped with every data refresh (shown in the header). --> <meta name="selectarena-version" content="0.5.0"> <meta name="selectarena-version" content="0.5.2"> <title>SelectArena Leaderboard</title> <meta name="description" content="Leaderboard of feature selection methods on real-world tabular data."> <link rel="icon" type="image/svg+xml" href="assets/logo.svg">16 unmodified lines </p>
<div class="tabs" role="tablist" aria-label="Leaderboard sections"> <button role="tab" id="tab-summary" aria-controls="panel-summary" aria-selected="true" data-tab="summary">Summary</button> <button role="tab" id="tab-tradeoffs" aria-controls="panel-tradeoffs" aria-selected="false" data-tab="tradeoffs">Trade-offs</button> <button role="tab" id="tab-leaderboard" aria-controls="panel-leaderboard" aria-selected="true" data-tab="leaderboard">Leaderboard</button> <button role="tab" id="tab-tradeoffs" aria-controls="panel-tradeoffs" aria-selected="false" data-tab="tradeoffs">Performance Trade-offs</button> <button role="tab" id="tab-stability" aria-controls="panel-stability" aria-selected="false" data-tab="stability">Stability</button> <button role="tab" id="tab-validity" aria-controls="panel-validity" aria-selected="false" data-tab="validity">Validity</button> </div>
<!-- Summary: Elo figure and leaderboard tables, which combine performance, stability and validity --> <section role="tabpanel" id="panel-summary" aria-labelledby="tab-summary"> <!-- Leaderboard: Elo figure above the table; both combine performance, stability and validity --> <section role="tabpanel" id="panel-leaderboard" aria-labelledby="tab-leaderboard"> <h2 class="tab-title">Leaderboard</h2> <div id="lb-no-results" class="notice" hidden> <strong>No results published yet.</strong> </div> <div id="lb-root" hidden> <div class="controls"> <div class="control"><span class="control-label" id="lb-label-view">View</span> <div class="chips" id="lb-chips-view" role="group" aria-labelledby="lb-label-view"></div></div> <div class="control"><span class="control-label" id="lb-label-tasks">Tasks</span> <div class="chips" id="lb-chips-tasks" role="group" aria-labelledby="lb-label-tasks"></div></div> <div class="control" id="lb-control-model"><span class="control-label" id="lb-label-model">Model</span> <div class="chips" id="lb-chips-model" role="group" aria-labelledby="lb-label-model"></div></div> <div class="control"><span class="control-label" id="lb-label-budget">Budget</span> <div class="chips" id="lb-chips-budget" role="group" aria-labelledby="lb-label-budget"></div></div> </div> <details class="config"> <summary class="config-button"><span class="config-title">Customize</span><span class="config-state"></span></summary> <div class="controls"> <div class="control"><span class="control-label" id="lb-label-tasks">Tasks</span> <div class="chips" id="lb-chips-tasks" role="group" aria-labelledby="lb-label-tasks"></div></div> <div class="control"><span class="control-label" id="lb-label-model">Model</span> <div class="chips" id="lb-chips-model" role="group" aria-labelledby="lb-label-model"></div></div> <div class="control"><span class="control-label" id="lb-label-budget">Budget</span> <div class="chips" id="lb-chips-budget" role="group" aria-labelledby="lb-label-budget"></div></div> </div> </details> <p class="summary" id="lb-summary" aria-live="polite"></p> <div id="lb-missing" class="notice" hidden> No leaderboard for this selection: fewer than two methods have results.17 unmodified lines </div> <div id="lb-table"> <iframe class="frame sa-frame" id="frame-table" title="Leaderboard table" style="height:640px"></iframe> <div class="caption" id="lb-caption-overall"> <div class="caption"> <p>Methods are compared within a <em>comparison group</em>: one dataset split, one downstream model configuration and one feature budget. The selection is shared with the Trade-offs tab.</p> model configuration and one feature budget. The selection is shared with the Performance Trade-offs tab.</p> <ul> <li><strong>Type</strong>: the paper's functional taxonomy (Appendix A). <em>Search</em> methods evaluate many feature subsets with a model-dependent utility: forward search (SFS),2 unmodified lines ((R)ReliefF, LaplacianScore), information theory (MI, mRMR, GainRatio), trees (CART, RFImportance) and regularization (Lasso, ElasticNet). Random is the baseline.</li> <li><strong>#</strong> and <strong>Elo</strong>: rank by Elo, with gold, silver and bronze for the three best; +/− give the 95% interval (the Elo rating is explained under the <em>Elo figure</em> view).</li> 95% interval (the Elo rating is explained under the figure above).</li> <li><strong>Avg. rank</strong>: mean rank of the method's downstream error within the groups (1 is best).</li> <li><strong>Improvability</strong>: mean relative gap <code>(error − best error) / error</code> to the best method of the group (0 is best).</li>7 unmodified lines share of runs in which the method ran out of time and random features filled the budget.</li> </ul> </div> <div class="caption" id="lb-caption-models" hidden> <p><strong>Elo per downstream model.</strong> Each column ranks the methods using only the results of one downstream model (same task type and budget); <em>All models</em> is the overall Elo. Medals mark the three best methods of each column, so you can see which selections suit which model.</p> </div> </div> </div> </div>8 unmodified lines <a href="https://github.com/schaeferbasti/SelectArena" target="_blank" rel="noopener">SelectArena repository</a>. </div> <div id="leaderboard-content" hidden> <details class="config"> <summary class="config-button"><span class="config-title">Customize</span><span class="config-state"></span></summary> <div class="controls"> <div class="control"><span class="control-label" id="label-tasks">Tasks</span> <div class="chips" id="chips-tasks" role="group" aria-labelledby="label-tasks"></div></div> <div class="control"><span class="control-label" id="label-model">Model</span> <div class="chips" id="chips-model" role="group" aria-labelledby="label-model"></div></div> <div class="control"><span class="control-label" id="label-budget">Budget</span> <div class="chips" id="chips-budget" role="group" aria-labelledby="label-budget"></div></div> </div> <div class="controls"> <div class="control"><span class="control-label" id="label-tasks">Tasks</span> <div class="chips" id="chips-tasks" role="group" aria-labelledby="label-tasks"></div></div> <div class="control"><span class="control-label" id="label-model">Model</span> <div class="chips" id="chips-model" role="group" aria-labelledby="label-model"></div></div> <div class="control"><span class="control-label" id="label-budget">Budget</span> <div class="chips" id="chips-budget" role="group" aria-labelledby="label-budget"></div></div> </div> </details> <p class="summary" id="summary" aria-live="polite"></p> <div id="subset-missing" class="notice" hidden> No leaderboard for this selection: fewer than two methods have results.28 unmodified lines <h2 class="tab-title">Stability</h2> <div id="stability-missing" class="notice" hidden>No stability results published yet.</div> <div id="stability-content"> <details class="config"> <summary class="config-button"><span class="config-title">Customize</span><span class="config-state"></span></summary> <div class="controls"> <div class="control"><span class="control-label" id="label-stab-tasks">Tasks</span> <div class="chips" id="chips-stab-tasks" role="group" aria-labelledby="label-stab-tasks"></div></div> <div class="control"><span class="control-label" id="label-stab-variant">View</span> <div class="chips" id="chips-stab-variant" role="group" aria-labelledby="label-stab-variant"></div></div> </div> <div class="controls"> <div class="control"><span class="control-label" id="label-stab-tasks">Tasks</span> <div class="chips" id="chips-stab-tasks" role="group" aria-labelledby="label-stab-tasks"></div></div> <div class="control"><span class="control-label" id="label-stab-variant">View</span> <div class="chips" id="chips-stab-variant" role="group" aria-labelledby="label-stab-variant"></div></div> </div> </details> <figure class="plot"> <img id="img-stability" alt="Lasagna plot of stability per method and events per variable"> <figcaption class="caption">19 unmodified lines <h2 class="tab-title">Validity</h2> <div id="validity-missing" class="notice" hidden>No validity results published yet.</div> <div id="validity-content"> <details class="config"> <summary class="config-button"><span class="config-title">Customize</span><span class="config-state"></span></summary> <div class="controls"> <div class="control"><span class="control-label" id="label-val-noise">Noise</span> <div class="chips" id="chips-val-noise" role="group" aria-labelledby="label-val-noise"></div></div> <div class="control"><span class="control-label" id="label-val-tasks">Tasks</span> <div class="chips" id="chips-val-tasks" role="group" aria-labelledby="label-val-tasks"></div></div> <div class="control"><span class="control-label" id="label-val-variant">View</span> <div class="chips" id="chips-val-variant" role="group" aria-labelledby="label-val-variant"></div></div> </div> <div class="controls"> <div class="control"><span class="control-label" id="label-val-noise">Noise</span> <div class="chips" id="chips-val-noise" role="group" aria-labelledby="label-val-noise"></div></div> <div class="control"><span class="control-label" id="label-val-tasks">Tasks</span> <div class="chips" id="chips-val-tasks" role="group" aria-labelledby="label-val-tasks"></div></div> <div class="control"><span class="control-label" id="label-val-variant">View</span> <div class="chips" id="chips-val-variant" role="group" aria-labelledby="label-val-variant"></div></div> </div> </details> <figure class="plot"> <img id="img-validity" alt="Lasagna plot of validity per method and events per variable"> <figcaption class="caption">75 unmodified lines7677787980818279808175 unmodified lines for name in ("pareto.svg", "pareto.csv"): if not (folder / name).is_file(): errors.append(f"meta.json lists a Pareto front but {info['path']}/{name} is missing") if info.get("per_model"): for name in ("per_model_table.html", "per_model.csv"): if not (folder / name).is_file(): errors.append(f"meta.json lists a per-model table but {info['path']}/{name} is missing") if not any(s["tasks"] == s["model"] == s["budget"] == "all" for s in meta["subsets"]): errors.append("the default subset (all, all, all) is not published")
AGENTS.md+11-12
assets/app.js+32-46
assets/style.css+20-2
index.html+50-45
smoke_test.py-4