Repository navigation
doc: surface numerical ranking for 3D NS optimization (#86) - #92
Merged
Merged
Conversation
Contributor
📊 View the full benchmark resultsNo benchmarks ran for this PR, so there is no status report. |
andrinr
marked this pull request as ready for review
June 30, 2026 14:14
Contributor
|
Thanks @andrinr. While we're at it, is there a good way to re-name the "Recovery Constant Ic Bfgs Proj" section? Doesn't seem very informative at face value. |
Addresses #86 (WIP — needs a benchmark run to verify the rendered page). The 3D Navier-Stokes optimization section showed only the field-evolution GIF, with no numerical results, because _rank_optimization() recognised only final_error / final_drag / final_compliance. The 3D IC-recovery experiment records its objective as `final_ic_error` (see navier_stokes_3d_grid/optimization.py:304), so the ranker found no recognised key, returned None, and the "Solver ranking" table was skipped — while the 2D drag problem (final_drag) renders its table fine. Add final_ic_error to _OPT_FINAL_KEYS (lowest priority, so 2D still picks final_drag first) and give it a clean column label via a new _OPT_METRIC_LABELS map. Note on the convergence curves the issue also mentions: _plot_convergence_curves() already renders one panel per sweep value whenever any solver recorded per-iteration `errors`, so convergence_curves.png should be produced on the next results regeneration (the committed qmd is a stale 2026-06-15 snapshot). No plotting change needed there. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
The results pages titled optimization sections by title-casing the raw experiment key, e.g. "Recovery Constant Ic Bfgs Proj" — uninformative (flagged in review). Map the optimization keys that title-case badly to proper names in EXPERIMENT_LABELS: recovery_constant_ic_bfgs_proj -> Initial-Condition Recovery (L-BFGS) conductivity_recovery_bfgs -> Conductivity Recovery (L-BFGS) drag_opt -> Drag Optimisation Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
andrinr
force-pushed
the
doc/ns3d-optimization-ranking
branch
from
July 9, 2026 08:57
7d3021e to
fef6564
Compare
Collaborator
Author
|
@dionhaefner done |
dionhaefner
enabled auto-merge (squash)
July 9, 2026 10:35
dionhaefner
approved these changes
Jul 9, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Draft / WIP — addresses #86. The logic is verified offline, but the rendered page can only be confirmed by regenerating against
mosaic-results(not in this repo; produced in CI), so I'm opening this as a draft for a maintainer with the results data to validate.Problem
The 3D Navier–Stokes Optimization section shows only the
recovery_evolution.gif— no numerical results — making the runs "hard to judge" (per the issue).Root cause
_rank_optimization()(docs/generate_results.py) recognised onlyfinal_error/final_drag/final_compliance. The 3D IC-recovery experiment records its objective asfinal_ic_error(navier_stokes_3d_grid/optimization.py:304). With no recognised key, the ranker returnedNoneand the "Solver ranking" table was silently skipped — whereas the 2D drag problem (final_drag) renders its table fine.Change
final_ic_errorto_OPT_FINAL_KEYSat lowest priority, so 2D still selectsfinal_dragfirst._OPT_METRIC_LABELSfor a clean column header (Final IC recovery error).Verified offline: against the 3D recovery metrics dict the ranker now selects
final_ic_error; given both keys, 2D still picksfinal_drag.On the convergence curves
The issue also asks for convergence curves.
_plot_convergence_curves()already renders one panel per sweep value whenever any solver recorded per-iterationerrors, soconvergence_curves.pngshould appear on the next results regeneration — the committedresults_ns_3d_grid.qmdis a stale 2026-06-15 snapshot. No plotting change made; please confirm the figure is emitted when you regenerate.To verify
python docs/generate_results.pyand checkresults_ns_3d_grid.qmdnow has a Solver ranking table under the recovery experiment and embedsconvergence_curves.png.🤖 Generated with Claude Code