Skip to content

Various fixes in IO #1078

Open
jorgensd wants to merge 5 commits intofestim-dev:fenicsxfrom
RemDelaporteMathurin:dokken/io-checkpoint-main
Open

Various fixes in IO #1078
jorgensd wants to merge 5 commits intofestim-dev:fenicsxfrom
RemDelaporteMathurin:dokken/io-checkpoint-main

Conversation

@jorgensd
Copy link
Collaborator

@jorgensd jorgensd commented Feb 26, 2026

Read data on grid from checkpoint, then interpolate to mesh used in simulation.

  • Could be modified if we change how the checkpointing is done.

  • Fix surfaceflux post-processing, it uses the wrong grid compared to the integration measure.

  • Add importorskip for ipyparallel if not installed

@codecov
Copy link

codecov bot commented Feb 26, 2026

Codecov Report

❌ Patch coverage is 94.73684% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 94.74%. Comparing base (b09927e) to head (01d3edc).

Files with missing lines Patch % Lines
src/festim/initial_condition.py 90.00% 1 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff             @@
##           fenicsx    #1078      +/-   ##
===========================================
- Coverage    94.77%   94.74%   -0.03%     
===========================================
  Files           44       44              
  Lines         3175     3179       +4     
===========================================
+ Hits          3009     3012       +3     
- Misses         166      167       +1     

☔ View full report in Codecov by Sentry.
📢 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.

Copy link
Collaborator

@RemDelaporteMathurin RemDelaporteMathurin left a comment

Choose a reason for hiding this comment

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

Thank you so much for this @jorgensd

I see now that we might have been a bit careless here. How would you do the checkpointing differently to avoid this interpolation?

Maybe we should read the mesh of the simulation from the checkpoint file too

Comment on lines +50 to +51
# obtain mesh normal from integration domain
mesh = ds.ufl_domain()
Copy link
Collaborator

Choose a reason for hiding this comment

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

ez

@RemDelaporteMathurin RemDelaporteMathurin added bug Something isn't working fenicsx Issue that is related to the fenicsx support labels Feb 26, 2026
@jorgensd
Copy link
Collaborator Author

Thank you so much for this @jorgensd

I see now that we might have been a bit careless here. How would you do the checkpointing differently to avoid this interpolation?

Maybe we should read the mesh of the simulation from the checkpoint file too

You can either use read/write on input mesh as described in https://scientificcomputing.github.io/io4dolfinx/docs/original_checkpoint.html (io4dolfinx/adios4dolfinx has same syntax there). I would recommend switching to io4dolfinx soon.

one could also read in the mesh and function from the checkpoint for the new simulation.

the possibilities/combinations are endless, but I think since most simulations use P1 elements, you could use vtkhdf backend of io4dolfinx to read/write point data, and everything should become a bit more clear (ie read in mesh, read in point data)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working fenicsx Issue that is related to the fenicsx support

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants