Skip to content

div_ops: Compile with METRIC_3D - #577

Merged
dschwoerer merged 67 commits into
masterfrom
compile-3dmetric
Aug 13, 2026
Merged

div_ops: Compile with METRIC_3D#577
dschwoerer merged 67 commits into
masterfrom
compile-3dmetric

Conversation

@bendudson

@bendudson bendudson commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator

Modify Div_par_fvv and Div_par_fvv_heating so that they compile with 3D metrics.

Maybe helps address issue #573

Ready to merge. The patch coverage is below the threshold, but code coverage increases with this PR because a lot of uncovered code is removed (or rather, moved to BOUT-dev).

Modify Div_par_fvv and Div_par_fvv_heating so that they compile
with 3D metrics.
@codecov

codecov Bot commented Jun 10, 2026

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 38.01653% with 150 lines in your changes missing coverage. Please review.
✅ Project coverage is 57.73%. Comparing base (412b099) to head (aca5f45).
⚠️ Report is 5 commits behind head on master.

Files with missing lines Patch % Lines
src/div_ops.cxx 30.84% 139 Missing ⚠️
src/recycling.cxx 55.55% 4 Missing ⚠️
src/electromagnetic.cxx 0.00% 2 Missing ⚠️
src/sheath_boundary_insulating.cxx 0.00% 2 Missing ⚠️
include/scale_timederivs.hxx 0.00% 1 Missing ⚠️
src/braginskii_ion_viscosity.cxx 80.00% 1 Missing ⚠️
src/vorticity.cxx 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #577      +/-   ##
==========================================
+ Coverage   57.53%   57.73%   +0.19%     
==========================================
  Files          98       97       -1     
  Lines       10223    10013     -210     
  Branches     1466     1443      -23     
==========================================
- Hits         5882     5781     -101     
+ Misses       3753     3652     -101     
+ Partials      588      580       -8     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Dataset.hermes.extract_[12]_tokamak_geometry() calls now result in an
error:
```
Traceback (most recent call last):
  File "/home/runner/work/hermes-3/hermes-3/build/tests/integrated/2D-recycling/runtest", line 144, in <module>
    ds = ds.hermes.extract_2d_tokamak_geometry()
  File "/home/runner/.local/lib/python3.10/site-packages/xhermes/accessors.py", line 172, in extract_2d_tokamak_geometry
    raise Exception(
Exception: extract_2d_tokamak_geometry was called twice! Note: this is now done automatically upon loading
```

@bshanahan bshanahan left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks OK to me -- don't think the test failures are related to this PR.

@dschwoerer

Copy link
Copy Markdown
Collaborator

The testing coverage is not really helpful, as so far 3D metrics only enables compiling. There will be more tests coming.

@ZedThree ZedThree left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@dschwoerer dschwoerer mentioned this pull request Aug 7, 2026

@ZedThree ZedThree left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Just tons of small but obvious fixes for 3D metrics

Comment thread src/neutral_mixed.cxx
.withDefault<bool>(true);

conduction_method =
options["conduction_method"].withDefault<std::string>(conduction_method);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is possibly now out of sync with BOUT++ and needs to be an enum, but maybe this PR can go in first and then that's a simple update?

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Indeed, I would need to update BOUT++ to the final version that got merged, and then update here.
I will make a PR into this one, then you can decide on the order of merging.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With boutproject/BOUT-dev#3425 merged, it probably makes sense to first merge this, and then later update to BOUT++ and update this too.

Comment thread hermes-3.cxx
@dschwoerer
dschwoerer merged commit 2a79cf5 into master Aug 13, 2026
6 of 7 checks passed
@dschwoerer
dschwoerer deleted the compile-3dmetric branch August 13, 2026 13:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants