Sensitivity: Minor plotting fixes#819
Conversation
There was a problem hiding this comment.
🤖 Isaac Lab-Arena Review Bot
Summary
Replaces the posterior-mean line in the continuous marginal panels with a uniform-prior reference at 1/span plus a shaded 5-95% credible band. The reasoning holds: for a factor swept symmetrically around its nominal value the mean collapses onto the prior mean and hides the signal, whereas reading the posterior against the uniform prior shows concentration directly. I confirmed the prior is BoxUniform over the normalized range (analyzer.py:_normalized_prior), so 1/span is the correct reference density in original units. Rendering-only and well-scoped — just two minor visualization notes below.
Findings
🔵 Improvement: plotting.py:100 — the 5-95% band reuses the KDE fill color, so it mostly blends into the fill (see inline).
🔵 Improvement: plotting.py:96 — KDE boundary leakage interacts with the new 1/span reference at the edges (see inline).
Test Coverage
Rendering-only matplotlib change with no new inference/data logic, and the suite doesn't assert on figure contents — so no new test is warranted here, consistent with the rest of the module.
Verdict
Ship it
- In the continuous marginal panels, drop the posterior mean line. Overlay the uniform prior as a flat reference and shade the central 5-95% of the posterior instead. - A mean sits at the prior mean for a factor swept symmetrically around its nominal value, so it hides whether conditioning on the outcome concentrated the factor. Reading the posterior against the prior shows that directly. Signed-off-by: Clemens Volk <cvolk@nvidia.com>
…anels - The components of a vector variation (name[0], name[1], ...) are on one scale, so give their continuous marginal panels a common y-axis to compare densities directly. Group by the base variation name (the inferred per-component ranges differ slightly, so they can't be the key). - A standalone scalar factor keeps its own scale. Signed-off-by: Clemens Volk <cvolk@nvidia.com>
74a300d to
5c85650
Compare
There was a problem hiding this comment.
🤖 Isaac Lab-Arena Review Bot
Summary
A focused, well-reasoned change to the sensitivity marginal renderer: it drops the posterior-mean line (uninformative for a symmetric sweep) in favour of overlaying the uniform prior as a flat reference plus a shaded 5–95% credible band, and gives the components of a vector variation a shared y-axis so their densities compare directly. The rationale is sound and the implementation is contained to one pure-plotting file. I verified the prior density (1/span), the percentile band, the KDE no-spread guard, and the shared-axis grouping — including the constant-component edge case, which degrades gracefully.
Findings
🔵 Improvement: isaaclab_arena/analysis/sensitivity/plotting.py:117 — minor baseline inconsistency between the two branches (see inline).
Test Coverage
No tests added, which is reasonable here — this is a visual-rendering change with no extractable numeric contract, and the existing sensitivity tests still exercise the call path. Nothing actionable.
Verdict
Ship it
There was a problem hiding this comment.
🤖 Isaac Lab-Arena Review Bot
Summary
A focused, rendering-only change to the sensitivity posterior-marginal plots: the continuous panels now overlay the uniform prior as a flat reference plus a 5–95% credible band instead of a posterior-mean line, and components of a vector variation share a y-axis. The motivation is sound — a mean is uninformative for a factor swept symmetrically about its nominal value, and reading the posterior against the prior shows concentration directly. No change to inference or the data model. Looks good to ship; one small robustness question below.
Findings
🔵 Improvement: isaaclab_arena/analysis/sensitivity/plotting.py:64 — grouping by stripping [\d+]$ from the name recovers the vector-component relationship from a string convention. It's the only carrier available today (FactorSpec has no structured base-name), so this is reasonable — but a standalone scalar factor whose name legitimately ends in [0] would be folded into a shared-scale group. If factor names are guaranteed to only use the name[i] suffix for true vector components, this is fine as-is; worth a one-line note to that effect.
Test Coverage
Pure rendering change with no behavioral surface to assert on, and the repo only exercises plot_marginals through the manual tests/sensitivity_synthetic.py pipeline script (not a pytest), so no automated test is expected here. The PR notes it was verified by regenerating the report, which is the right check for this kind of change.
Verdict
Ship it
Co-authored-by: greptile-apps[bot] <165735046+greptile-apps[bot]@users.noreply.github.com>
There was a problem hiding this comment.
🤖 Isaac Lab-Arena Review Bot
Summary
A small, well-documented plotting change in analysis/sensitivity/plotting.py: the continuous marginals now overlay the uniform prior plus a 5–95% credible band instead of a posterior-mean line, and components of a vector variation share a y-axis for direct comparison. The grouping logic and the shared-y-axis pass are correct, and the change is scoped to a niche analysis renderer with no boundary or default-behavior concerns. One minor maintainability note below.
Findings
🔵 Improvement: isaaclab_arena/analysis/sensitivity/plotting.py:64 — the component grouping reverses the key[i] suffix produced in episode_results_reader.py. That reader carries a TODO(cvolk) to emit semantic component names instead of the positional [i] suffix — when that lands, this regex would silently stop matching and each component would fall back to its own scale with no error. Worth a NOTE here (or in that TODO) flagging that the grouping depends on the [i] format, so the two stay in sync.
Test Coverage
This is a pure-rendering visual change (KDE overlays, axis limits) with no behavioral contract that lends itself to a meaningful assertion, so the lack of a new test is reasonable here.
Verdict
Ship it
Summary
Minor improvements in the sensitivity posterior-marginal plots
Detailed description